{% extends '@OroUI/actions/view.html.twig' %} {% import '@OroUI/macros.html.twig' as UI %} {% import '@OroEntityConfig/macros.html.twig' as entityConfig %} {% oro_title_set({params : {"%entity.title%": entity.name }}) %} {% block navButtons %} {% import '@OroUI/macros.html.twig' as UI %} {% if canAddEvent %}
{{ UI.addButton({ 'path' : path('oro_system_calendar_event_create', {'id': entity.id }), 'entity_label': 'oro.calendar.calendarevent.entity_label'|trans }) }}
{% endif %} {% if editable %} {{ UI.editButton({ 'path' : path('oro_system_calendar_update', { id: entity.id }), 'entity_label': 'oro.calendar.systemcalendar.entity_label'|trans }) }} {% endif %} {% if removable %} {{ UI.deleteButton({ 'dataUrl': path('oro_api_delete_systemcalendar', {'id': entity.id}), 'dataRedirect': path('oro_system_calendar_index'), 'aCss': 'no-hash remove-button', 'dataId': entity.id, 'entity_label': 'oro.calendar.systemcalendar.entity_label'|trans }) }} {% endif %} {% endblock navButtons %} {% block pageHeader %} {% set breadcrumbs = { 'entity': entity, 'indexPath': path('oro_system_calendar_index'), 'indexLabel': 'oro.calendar.systemcalendar.entity_plural_label'|trans, 'entityTitle': entity.name, } %} {{ parent() }} {% endblock pageHeader %} {% block content_data %} {% import '@OroUI/macros.html.twig' as UI %} {% set systemCalendarInformation %}
{{ UI.renderProperty('oro.calendar.systemcalendar.name.label'|trans, entity.name) }} {{ UI.renderColorProperty( 'oro.calendar.systemcalendar.background_color.label'|trans, entity.backgroundColor, 'oro.calendar.systemcalendar.no_color'|trans) }} {% if showScope %} {{ UI.renderProperty('oro.calendar.systemcalendar.public.label'|trans, entity.public ? 'oro.calendar.systemcalendar.scope.system'|trans : 'oro.calendar.systemcalendar.scope.organization'|trans) }} {% endif %}
{{ entityConfig.renderDynamicFields(entity) }}
{% endset %} {% set dataBlocks = [{ 'title': 'General Information'|trans, 'class': 'active', 'subblocks': [ {'data' : [systemCalendarInformation]} ] }] %} {% set systemCalendarEventsWidget %} {{ oro_widget_render({ 'widgetType': 'block', 'url': path('oro_system_calendar_widget_events', {id: entity.id}) }) }} {% endset %} {% set dataBlocks = dataBlocks|merge([{ 'title': 'oro.calendar.calendarevent.entity_plural_label'|trans, 'subblocks': [ {'data' : [systemCalendarEventsWidget]} ] }]) %} {% set id = 'systemCalendarView' %} {% set data = { 'dataBlocks': dataBlocks } %} {{ parent() }} {% endblock content_data %}