{% extends '@OroUI/actions/update.html.twig' %} {% oro_title_set({params : {"%entity.title%": entity.name, "%entityName%": 'oro.calendar.systemcalendar.entity_label'|trans } }) %} {% set entityId = entity.id %} {% block navButtons %} {% import '@OroUI/macros.html.twig' as UI %} {% set html = UI.saveAndCloseButton({ 'route': 'oro_system_calendar_view', 'params': {'id': '$id'} }) %} {% if is_granted('oro_calendar_create') %} {% set html = html ~ UI.saveAndNewButton({ 'route': 'oro_system_calendar_create' }) %} {% endif %} {% if is_granted('oro_public_calendar_management') or is_granted('oro_system_calendar_management') %} {% set html = html ~ UI.saveAndStayButton({ 'route': 'oro_system_calendar_update', 'params': {'id': '$id'} }) %} {% endif %} {{ UI.dropdownSaveButton({'html': html}) }} {{ UI.cancelButton(path('oro_system_calendar_index')) }} {% endblock %} {% block pageHeader %} {% if entityId %} {% set breadcrumbs = { 'entity': entity, 'indexPath': path('oro_system_calendar_index'), 'indexLabel': 'oro.calendar.systemcalendar.entity_plural_label'|trans, 'entityTitle': entity.name } %} {{ parent() }} {% else %} {% set title = 'oro.ui.create_entity'|trans({'%entityName%': 'oro.calendar.systemcalendar.entity_label'|trans}) %} {% include '@OroUI/page_title_block.html.twig' with { title: title } %} {% endif %} {% endblock pageHeader %} {% block content_data %} {% set id = 'systemcalendar-form' %} {% set dataBlocks = [{ 'title': 'General Information'|trans, 'class': 'active', 'subblocks': [ { 'title': '', 'data': [ form_row(form.name), form_row(form.backgroundColor), form_row(form.public) ] } ] }] %} {% set dataBlocks = dataBlocks|merge(oro_form_additional_data(form, 'Additional'|trans)) %} {% set data = { 'formErrors': form_errors(form)? form_errors(form) : null, 'dataBlocks': dataBlocks } %} {{ parent() }} {% endblock content_data %}