Commit 129280f06e38572227ddbbe67a0e1b98cb7b8282
1 parent
a0ad6974
Exists in
master
and in
5 other branches
Datepicker included [Issue:#418]
Showing
1 changed file
with
8 additions
and
1 deletions
Show diff stats
users/templates/users/create.html
... | ... | @@ -38,8 +38,8 @@ |
38 | 38 | {% else %} |
39 | 39 | <label for="{{ field.auto_id }}">{{ field.label }}</label> |
40 | 40 | {% endif %} |
41 | - <input type="text" class="form-control input-sm date-picker" name="{{field.name}}" min="{{now|date:'SHORT_DATE_FORMAT'}}"> | |
42 | 41 | |
42 | + {% render_field field class='form-control date-picker' %} | |
43 | 43 | {% elif field.auto_id == 'id_image' %} |
44 | 44 | {% if field.field.required %} |
45 | 45 | <label for="{{ field.auto_id }}">{{ field.label }}<span>*</span></label> |
... | ... | @@ -136,4 +136,11 @@ |
136 | 136 | </br> |
137 | 137 | </br> |
138 | 138 | </br> |
139 | +<script type="text/javascript"> | |
140 | +var locale = navigator.language || navigator.userLanguage; | |
141 | + | |
142 | +$('.date-picker').datepicker({ | |
143 | + language: locale, | |
144 | +}); | |
145 | +</script> | |
139 | 146 | {% endblock %} | ... | ... |