templates/app/mf-form.html.twig line 1

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% use 'dropZone.html.twig' %}
  3. {% block javascripts %}
  4.     {{ encore_entry_script_tags('person') }}
  5.     {{ encore_entry_script_tags('form') }}
  6. {% endblock %}
  7. {% block body %}
  8. <div class="container">
  9.     <h1>Schadenanzeige für Kantonale Dienstfahrzeuge</h1>
  10.     {{ form_start(form) }}
  11.     <div class="row">
  12.         <div class="col-sm-12 col-lg-3">
  13.             {{ form_row(form.department) }}
  14.         </div>
  15.     </div>
  16.     <div class="border mb-2 px-1">
  17.         <div class="row">
  18.             <div class="col-sm-12 col-lg-3">
  19.                 {{ form_row(form.mfType) }}
  20.             </div>
  21.             <div class="col-sm-12 col-lg-3">
  22.                 {{ form_row(form.mfModel) }}
  23.             </div>
  24.             <div class="col-sm-12 col-lg-3">
  25.                 {{ form_row(form.mfPlate) }}
  26.             </div>
  27.         </div>
  28.     </div>
  29.     <div class="border mb-2 px-1">
  30.         <div class="row">
  31.             <div class="col-sm-12 col-lg-3">
  32.                 {{ form_row(form.claimDate) }}
  33.             </div>
  34.             <div class="col-sm-12 col-lg-5">
  35.                 {{ form_row(form.claimAddress) }}
  36.             </div>
  37.         </div>
  38.     </div>
  39.     <div class="border mb-2 px-1">
  40.         <div class="row">
  41.             <div class="col-sm-12 col-lg-8">
  42.                 {{ form_row(form.claimDescription) }}
  43.             </div>
  44.             <div class="col-sm-12 col-lg-4">
  45.                 {{ form_row(form.policeReport) }}
  46.             </div>
  47.             <div class="col-sm-12 col-lg-4">
  48.                 {{ form_row(form.responsible) }}
  49.             </div>
  50.         </div>
  51.     </div>
  52.     <div class="border mb-2 px-1">
  53.         <label>Angaben zum Schaden</label>
  54.         <div class="row">
  55.             <div class="col-sm-12 col-lg-3">
  56.                 {{ form_row(form.claimDamageCause) }}
  57.             </div>
  58.             <div class="col-sm-12 col-lg-3">
  59.                 {{ form_row(form.claimDamage) }}
  60.             </div>
  61.             <div class="col-sm-12 col-lg-3">
  62.                 {{ form_row(form.damageCosts) }}
  63.             </div>
  64.         </div>
  65.     </div>
  66.     <div class="border mb-2 px-1">
  67.         <label>Fremde Sachen</label>
  68.         <div class="row">
  69.             <div class="col-sm-12 col-lg-3">
  70.                 {{ form_row(form.foreignDeductible) }}
  71.             </div>
  72.             <div class="col-sm-12 col-lg-3">
  73.                 {{ form_row(form.foreignDamageCosts) }}
  74.             </div>
  75.         </div>
  76.     </div>
  77.     <div class="border mb-2 px-1">
  78.         <div class="row">
  79.             <div class="col-sm-12 col-lg-5">
  80.                 <div class="row">
  81.                     <div class="col-md-12">
  82.                         {{ form_row(form.driver) }}
  83.                     </div>
  84.                 </div>
  85.                 <div class="row">
  86.                     <div class="col-md-12">
  87.                         {{ form_row(form.driverBirthdate) }}
  88.                     </div>
  89.                 </div>
  90.             </div>
  91.             <div class="col-sm-12 col-lg-5">
  92.                 <div class="row">
  93.                     <div class="col-md-12">
  94.                         {{ form_row(form.mfLicense) }}
  95.                     </div>
  96.                 </div>
  97.             </div>
  98.         </div>
  99.     </div>
  100.     <div class="border mb-2 px-1">
  101.         <div class="row">
  102.             <label>Beteiligte Person</label>
  103.             <div class="col-sm-12 col-lg-5">
  104.                 <div class="row">
  105.                     <div class="col-md-12">
  106.                         {{ form_row(form.involvedPerson.involvedPersonSex)}}
  107.                         {{ form_row(form.involvedPerson.involvedPersonLastname) }}
  108.                         {{ form_row(form.involvedPerson.involvedPersonFirstname) }}
  109.                         {{ form_row(form.involvedPerson.involvedPersonAddress) }}
  110.                         {{ form_row(form.involvedPerson.involvedPersonPostcode) }}
  111.                         {{ form_row(form.involvedPerson.involvedPersonCity) }}
  112.                     </div>
  113.                 </div>
  114.             </div>
  115.             <div class="col-sm-12 col-lg-5">
  116.                 <div class="row">
  117.                     <div class="col-md-12">
  118.                         {{ form_row(form.involvedPerson.involvedCarAssurance) }}
  119.                         {{ form_row(form.involvedPerson.involvedPersonPhone) }}
  120.                         {{ form_row(form.involvedPerson.involvedCarTyp) }}
  121.                         {{ form_row(form.involvedPerson.involvedCarNr) }}
  122.                     </div>
  123.                 </div>
  124.             </div>
  125.         </div>
  126.     </div>
  127.     <div class="border mb-2 px-1">
  128.         <div class="row">
  129.             <div class="col-md-12">
  130.                 <label>Beteiligte / Zeugen</label>
  131.                 <table class="col-md-12">
  132.                     <thead>
  133.                     <tr>
  134.                         <th class="align-top">Name</th>
  135.                         <th class="align-top">Telefon</th>
  136.                         <th class="align-top">Email</th>
  137.                         <th class="align-top ml-2"></th>
  138.                     </tr>
  139.                     </thead>
  140.                     <tbody id="persons" data-widget-counter="{{ form.persons|length }}"
  141.                            data-prototype='<tr id="items__item__"><td>{{ form_widget(form.persons.vars.prototype.name) }}</td><td>{{ form_widget(form.persons.vars.prototype.phone) }}</td><td>{{ form_widget(form.persons.vars.prototype.email) }}</td><td><button type="button" class="btn btn-danger btn-sm remove-item" data-action="delete" data-row="items__item__"><i class="fas fa-trash"></i></button></td></tr>'
  142.                     >
  143.                     {% for person in form.persons %}
  144.                         <tr>
  145.                             <td>{{ form_widget(person.name) }}</td>
  146.                             <td>{{ form_widget(person.phone) }}</td>
  147.                             <td>{{ form_widget(person.email) }}</td>
  148.                             <td>
  149.                                 <button type="button" class="btn btn-danger btn-sm remove-person" data-action="delete">
  150.                                     <i class="fas fa-trash"></i>
  151.                                 </button>
  152.                             </td>
  153.                         </tr>
  154.                     {% endfor %}
  155.                     </tbody>
  156.                 </table>
  157.                 <button class="btn btn-sm btn-secondary my-md-1" id="add-person" data-list-selector="#persons">Weitere Person hinzufügen</button>
  158.             </div>
  159.         </div>
  160.     </div>
  161.     <div class="border mb-2 px-1">
  162.         <div class="row">
  163.             <div class="col-md-12">
  164.                 {{ form_row(form.remark) }}
  165.             </div>
  166.         </div>
  167.     </div>
  168.     <div class="border mb-2 px-1">
  169.         <div class="row">
  170.             <div class="col-sm-12 col-lg-5">
  171.                 <label class="form-label required">Gemeldet durch</label>
  172.                 <div class="row">
  173.                     <div class="col-md-12">
  174.                         {{ form_row(form.name) }}
  175.                         {{ form_row(form.email) }}
  176.                     </div>
  177.                 </div>
  178.             </div>
  179.             <div class="col-sm-12 col-lg-5">
  180.                 <label class="form-label">Kopie an:</label>
  181.                 <div class="row">
  182.                     <div class="col-md-12">
  183.                         {{ form_row(form.ccEmail) }}
  184.                     </div>
  185.                 </div>
  186.             </div>
  187.         </div>
  188.     </div>
  189.     <div class="border mb-2 px-1">
  190.         {% block dropZone %}
  191.             {{ parent() }}
  192.         {% endblock %}
  193.     </div>
  194.     <div class="row justify-content-between">
  195.         <div class="col-md-4">
  196.             {{ form_widget(form.submit) }}
  197.         </div>
  198.         <div class="col-md-4">
  199.             <a href="{{ url('home') }}" class="btn btn-danger float-end">Zurück</a>
  200.         </div>
  201.     </div>
  202.     {{ form_end(form) }}
  203. </div>
  204. {% endblock %}