{% extends '@OroUI/actions/update.html.twig' %} {% import '@OroDataGrid/macros.html.twig' as dataGrid %} {% set entityId = entity.id %} {% oro_title_set({params : { "%entityLabel%": entity.label } }) %} {% set formAction = entityId ? path('oro_payment_term_update', { 'id': entityId }) : path('oro_payment_term_create') %} {% block navButtons %} {% import '@OroUI/macros.html.twig' as UI %} {% placeholder update_navButtons with {entity: entity} %} {{ UI.cancelButton(path('oro_payment_term_index')) }} {% set html = '' %} {% if is_granted('oro_payment_term_view') %} {% set html = html ~ UI.saveAndCloseButton({ 'route' : 'oro_payment_term_view', 'params' : {'id': '$id'} }) %} {% endif %} {% if is_granted('oro_payment_term_update') %} {% set html = html ~ UI.saveAndStayButton({ 'route' : 'oro_payment_term_update', 'params': {'id': '$id'} }) %} {% endif %} {{ UI.dropdownSaveButton({'html': html}) }} {% endblock navButtons %} {% block pageHeader %} {% if entityId %} {% set breadcrumbs = { 'entity': entity, 'indexPath': path('oro_payment_term_index'), 'indexLabel': 'oro.paymentterm.entity_plural_label'|trans, 'entityTitle': entity.label } %} {{ parent() }} {% else %} {% set title = 'oro.ui.create_entity'|trans({'%entityName%': 'oro.paymentterm.entity_label'|trans}) %} {% include '@OroUI/page_title_block.html.twig' with { title: title } %} {% endif %} {% endblock pageHeader %} {% block content_data %} {% set id = 'payment-term-edit' %} {% set dataBlocks = [{ 'title': 'oro.paymentterm.sections.general_information'|trans, 'class': 'active', 'subblocks': [{ 'title': '', 'data': [ form_row(form.label), ] }] }] %} {% 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 %}