edit.html.twig 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. {% extends 'admin/base.html.twig' %}
  2. {% form_theme form 'admin/form/custom_theme.html.twig' %}
  3. {% block content %}
  4. {% set languages = global_service.languages %}
  5. <div class="content">
  6. <div class="container-fluid">
  7. <div class="row">
  8. <div class="col-md-12">
  9. <div class="card">
  10. <div class="card-header">
  11. <h4 class="card-title">{{ title }}</h4>
  12. </div>
  13. <div class="card-body">
  14. {{ form_start(form) }}
  15. <div class="row">
  16. <div class="col-md-4">
  17. {{ form_row(form.is_active) }}
  18. </div>
  19. <div class="col-md-8"></div>
  20. </div>
  21. <div class="row">
  22. <div class="col-md-4">
  23. {{ form_row(form.city) }}
  24. </div>
  25. <div class="col-md-4">
  26. {{ form_row(form.type) }}
  27. </div>
  28. <div class="col-md-4">
  29. {{ form_row(form.detailed_type) }}
  30. </div>
  31. </div>
  32. <div class="row">
  33. <div class="col-md-4">
  34. {{ form_row(form.lat) }}
  35. </div>
  36. <div class="col-md-4">
  37. {{ form_row(form.lon) }}
  38. </div>
  39. <div class="col-md-4">
  40. {{ form_row(form.url) }}
  41. </div>
  42. </div>
  43. <div class="row">
  44. <div class="col-md-4">
  45. {{ form_row(form.email) }}
  46. </div>
  47. <div class="col-md-4">
  48. {{ form_row(form.website) }}
  49. </div>
  50. <div class="col-md-4">
  51. {{ form_row(form.phones) }}
  52. </div>
  53. </div>
  54. <div class="row">
  55. <div class="col-md-12">
  56. {{ form_row(form.logo) }}
  57. </div>
  58. </div>
  59. <div class="row">
  60. <div class="col-md-12">
  61. {{ form_row(form.comment) }}
  62. </div>
  63. </div>
  64. {% for language in languages %}
  65. <div class="card">
  66. <div class="card-header">
  67. <h5 class="form-lang-header">
  68. <a href="#collapse-{{ language.code }}" data-toggle="collapse">
  69. <span class="language left lang-{{ language.code }}"></span>
  70. {{ language.title }}
  71. </a>
  72. </h5>
  73. </div>
  74. <div id="collapse-{{ language.code }}" class="collapse {% if language.code == 'ru' or language.code == 'en' %}show{% else %}hide{% endif %}">
  75. <div class="card-body">
  76. <div class="row">
  77. <div class="col-md-12">
  78. {{ form_row(form["lang_#{language.id}_title"]) }}
  79. </div>
  80. </div>
  81. <div class="row">
  82. <div class="col-md-12">
  83. {{ form_row(form["lang_#{language.id}_address"]) }}
  84. </div>
  85. </div>
  86. <div class="row">
  87. <div class="col-md-12">
  88. {{ form_row(form["lang_#{language.id}_short_desc"]) }}
  89. </div>
  90. </div>
  91. <div class="row">
  92. <div class="col-md-12">
  93. {{ form_row(form["lang_#{language.id}_desc"]) }}
  94. </div>
  95. </div>
  96. </div>
  97. </div>
  98. </div>
  99. {% endfor %}
  100. <div class="row">
  101. <div class="col-md-12">
  102. {{ form_row(form.services) }}
  103. </div>
  104. </div>
  105. <p class="text-center">
  106. <button type="submit" class="btn btn-primary btn-fill">Сохранить</button>
  107. </p>
  108. {{ form_end(form) }}
  109. </div>
  110. </div>
  111. </div>
  112. </div>
  113. </div>
  114. </div>
  115. {% endblock %}