src/App/Resources/views/dashboard/settings/accounts/update.html.twig line 1

Open in your IDE?
  1. {% embed '@ui2022/schoolnow/modal--sidepanel__content.html.twig' with {} %}
  2.     {% form_theme form '@ui2022/schoolnow/forms/themes/default.html.twig' %}
  3.     {% from "@ui2022/macros.html.twig" import renderMetadata %}
  4.     {% block header %}
  5.         {% include '@App/dashboard/settings/accounts/includes/_header.html.twig' with {
  6.             active: 'account',
  7.         } %}
  8.     {% endblock %}
  9.     {% block body %}
  10.         <div class="contacts">
  11.             <div class="row justify-content-end">
  12.                 <span class="font-13 text-medium mb-3 col-auto">Last modified: {{ account.touchedAt ? account.touchedAt|ui_relativeDate : '-' }}</span>
  13.             </div>
  14.             {% if account.internalUid %}
  15.                 <div class="row justify-content-end">
  16.                     <span class="font-13 text-medium mb-3 col-auto">Internal UID: {{ account.internalUid }}</span>
  17.                 </div>
  18.             {% endif %}
  19.             <div class="sidepanel__content--body">
  20.                 <div class="contacts__tabs">
  21.                     {% include '@App/dashboard/settings/accounts/includes/_tabs.html.twig' with {
  22.                         active: 'account',
  23.                     } %}
  24.                     <div class="tab-content">
  25.                         {% if not account.oneroster %}
  26.                             {{ form_start(form, {
  27.                                 action: path('app.app.dashboard.settings.accounts.update', {
  28.                                     account: account.id,
  29.                                 }),
  30.                                 attr: {
  31.                                     target: '_modal',
  32.                                 },
  33.                             }) }}
  34.                             <div class="formcontainer formfield-colored" style="max-width: 720px;">
  35.                                 <div class="row mt-5">
  36.                                     <div class="col">
  37.                                         {{ form_row(form.email) }}
  38.                                     </div>
  39.                                 </div>
  40.                                 <div class="row mt-4">
  41.                                     <div class="col-6">
  42.                                         {{ form_row(form.systemProfile.firstName) }}
  43.                                     </div>
  44.                                     <div class="col-6">
  45.                                         {{ form_row(form.systemProfile.lastName) }}
  46.                                     </div>
  47.                                 </div>
  48.                                 <div class="row mt-4">
  49.                                     <div class="col">
  50.                                         {{ form_row(form.password) }}
  51.                                     </div>
  52.                                 </div>
  53.                                 <div class="row mt-3">
  54.                                     <div class="col">
  55.                                         {{ form_row(form.notify) }}
  56.                                     </div>
  57.                                 </div>
  58.                             </div>
  59.                             <div class="d-flex align-items-center mt-5 mb-3">
  60.                                 {% include '@ui2022/button--form.html.twig' with {
  61.                                     type: 'submit',
  62.                                     text: 'Save',
  63.                                     styles: 'md primary',
  64.                                     attr: {
  65.                                         class: 'px-4 mr-3',
  66.                                     },
  67.                                 } %}
  68.                                 {% include '@ui2022/button--button.html.twig' with {
  69.                                     text: 'Cancel',
  70.                                     styles: 'md lightgray',
  71.                                     attr: {
  72.                                         class: 'px-4',
  73.                                         'data-dismiss': 'sidepanel',
  74.                                     },
  75.                                 } %}
  76.                             </div>
  77.                             {{ form_end(form) }}
  78.                         {% else %}
  79.                             <div class="row justify-content-between mt-5">
  80.                                 <h3 class="col-auto">Account metadata</h3>
  81.                             </div>
  82.                             <div class="row pt-3">
  83.                                 <div class="col">
  84.                                     {% if account.metadata %}
  85.                                         {{ renderMetadata(account.metadata) }}
  86.                                     {% else %}
  87.                                         <p>Account has no metadata.</p>
  88.                                     {% endif %}
  89.                                 </div>
  90.                             </div>
  91.                         {% endif %}
  92.                     </div>
  93.                 </div>
  94.             </div>
  95.         </div>
  96.     {% endblock %}
  97. {% endembed %}