29
29
{% block formButtons %}
30
{% trans "Help" %}, XiboHelpRender("{{ help }}")
31
30
{% trans "Cancel" %}, XiboDialogClose()
32
31
{% trans "Save" %}, $("#dayPartEditForm").submit()
34
{% block extra %}{{ extra|json_encode|raw }}{% endblock %}
36
{% block callBack %}dayPartFormOpen{% endblock %}
35
38
{% block formHtml %}
37
40
<div class="col-md-12">
41
<ul class="nav nav-tabs" role="tablist">
42
<li class="active"><a href="#general" role="tab" data-toggle="tab"><span>{% trans "General" %}</span></a></li>
43
<li><a href="#description" role="tab" data-toggle="tab"><span>{% trans "Description" %}</span></a></li>
44
<li><a href="#exceptions" role="tab" data-toggle="tab"><span>{% trans "Exceptions" %}</span></a></li>
38
46
<form id="dayPartEditForm" class="XiboForm form-horizontal" method="put" action="{{ urlFor("daypart.edit", {id: dayPart.dayPartId}) }}">
40
{% set title %}{% trans "Name" %}{% endset %}
41
{% set helpText %}{% trans "The Name for this Daypart" %}{% endset %}
42
{{ forms.input("dayPart", title, dayPart.name, helpText, "", "required") }}
44
{% set title %}{% trans "Description" %}{% endset %}
45
{% set helpText %}{% trans "A Description of Daypart" %}{% endset %}
46
{{ forms.textarea("description", title, dayPart.description, helpText) }}
48
{% set title %}{% trans "Retired" %}{% endset %}
49
{% set helpText %}{% trans "Retire? It will no longer be visible when scheduling" %}{% endset %}
50
{{ forms.checkbox("retired", title, dayPart.isRetired, helpText) }}
52
{% set title %}{% trans "Monday start time" %}{% endset %}
53
{{ forms.time("monStart", title, dayPart.monStart) }}
47
<div class="tab-content">
48
<div class="tab-pane active" id="general">
49
{% set title %}{% trans "Name" %}{% endset %}
50
{% set helpText %}{% trans "The Name for this Daypart" %}{% endset %}
51
{{ forms.input("name", title, dayPart.name, helpText, "", "required") }}
53
{% set title %}{% trans "Retired" %}{% endset %}
54
{% set helpText %}{% trans "Retire? It will no longer be visible when scheduling" %}{% endset %}
55
{{ forms.checkbox("retired", title, dayPart.isRetired, helpText) }}
57
{% set title %}{% trans "Start Time" %}{% endset %}
58
{% set helpText %}{% trans "Enter the start time for this daypart" %}{% endset %}
59
{{ forms.time("startTime", title, dayPart.startTime, helpText) }}
61
{% set title %}{% trans "End Time" %}{% endset %}
62
{% set helpText %}{% trans "Enter the end time for this daypart. If the end time is after the start time, then the daypart will cross midnight." %}{% endset %}
63
{{ forms.time("endTime", title, dayPart.endTime, helpText) }}
66
<div class="tab-pane" id="description">
67
{% set title %}{% trans "Description" %}{% endset %}
68
{% set helpText %}{% trans "A Description of Daypart" %}{% endset %}
69
{{ forms.textarea("description", title, dayPart.description, helpText) }}
71
<div class="tab-pane" id="exceptions">
72
{% set title %}{% trans "If there are any exceptions enter them below by selecting the Day from the list and entering a start/end time." %}{% endset %}
73
{{ forms.message(title) }}
74
<div id="dayPartExceptions">