{% extends "scheduler.html.twig" %} {% block body_id 'scheddetail' %} {% block title %} {{ 'detail.title'|trans }} {% endblock title %} {% block content %} {% trans_default_domain 'MyCommandScheduler' %} {% set styleConfiguration = {'class': 'form-control'} %}
{% for val in ['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'] %}
{% endfor %}
{{ form_start( scheduledCommandForm, {'action': path('scheduler_detail_save',{'cmd':cmd})} ) }}
{{ form_row(scheduledCommandForm._token) }} {{ form_errors(scheduledCommandForm) }} {# Form's fields #} {{ form_row( scheduledCommandForm.id ) }} {{ form_row( scheduledCommandForm.name, {'attr': styleConfiguration|merge({'placeholder': 'Scheduler name'}) } ) }} {{ form_row( scheduledCommandForm.command, {'attr': styleConfiguration } ) }} {# {{ form_row( scheduledCommandForm.arguments, {'attr': styleConfiguration|merge({'placeholder': '--argument1=foo --bar'}) } ) }} #} {% if is_granted('ROLE_SUPERADMIN') %} {{ form_row( scheduledCommandForm.cronExpression, {'attr': styleConfiguration|merge({'placeholder': '*/10 * * * *'}) } ) }} {% else %} {{ form_row( scheduledCommandForm.cronExpression, {'attr': styleConfiguration|merge({'placeholder': '*/10 * * * *', 'readonly': 'readonly'}) } ) }} {% endif %} {#{{ form_row( scheduledCommandForm.cronExpression, {'attr': styleConfiguration|merge({'placeholder': '*/10 * * * *', 'readonly': 'readonly'}) } ) }}#} {# {{ form_row( scheduledCommandForm.logFile, {'attr': styleConfiguration|merge({'placeholder': 'myFile.log'}) } ) }} #} {{ form_row( scheduledCommandForm.priority, {'attr': styleConfiguration } ) }}
{{ form_widget( scheduledCommandForm.executeImmediately ) }} {{ form_label( scheduledCommandForm.executeImmediately ) }}
{{ form_widget( scheduledCommandForm.disabled ) }} {{ form_label( scheduledCommandForm.disabled ) }}
{# Form's actions #}
Cancel {{ form_widget( scheduledCommandForm.save, {'attr': {'class': 'btn-scheduler btn btn-success btn-lg pull-right'} } ) }}

{{ form_label( scheduledCommandForm.arguments ) }}

{{ form_widget( scheduledCommandForm.arguments ) }}
Cancel {{ form_widget( scheduledCommandForm.saveemail, {'attr': {'class': 'btn-scheduler btn btn-success btn-lg pull-right'} } ) }}
{{ form_end( scheduledCommandForm, {'render_rest': false} ) }} {% endblock content %} {% block javascripts %} {{ parent() }} {% endblock %}