/
datepicker.html
40 lines (40 loc) · 1.39 KB
/
datepicker.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<div class="form-group"
{% if visibility %} {{ visibility|safe }} {% endif %}
>
<label
class="control-label {% ifequal style "horizontal" %}col-sm-3{% endifequal %}">
{{ label }}
</label>
<div
{% ifequal style "horizontal" %}
class="col-sm-8"
{% endifequal %}
>
{% if options %}
<div class="input-group">
{% endif %}
<input type="text" class="form-control"
uib-datepicker-popup="dd/MM/yyyy"
ng-model="{{ model }}"
is-open="{{ formname }}[{{ element_name }} + '_open']"
min-date="{{ mindate}}"
max-date="maxDate"
show-button-bar="false"
show-weeks="false"
name="[[ {{ element_name}} ]]"
datepicker-options="{startingDay: 1}"
ng-focus="{{ formname }}[{{ element_name }} + '_open']=true"
close-text="Close"
{% if change %}
ng-change="{{ change }}"
{% endif %}
/>
{% if user_options %}
<span class="input-group-btn">
<button type="button" class="btn btn-default" ng-click="{{ model }} = dateHelper.now()" href="">Today</a>
<button type="button" class="btn btn-default" ng-click="{{ model }} = dateHelper.yesterday()" href="">Yesterday</a>
</span>
</div>
{% endif %}
</div>
</div>