Commit 5757a1e9 authored by Pietri Yoann's avatar Pietri Yoann Committed by Levy--Falk Hugo

Avec le name ça marche mieux

parent 838c5999
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<script src="/javascript/jquery-timepicker/jquery-ui-timepicker-addon.js"></script> <script src="/javascript/jquery-timepicker/jquery-ui-timepicker-addon.js"></script>
<link href="/javascript/jquery-ui/css/smoothness/jquery-ui.min.css" rel="stylesheet"/> <link href="/javascript/jquery-ui/css/smoothness/jquery-ui.min.css" rel="stylesheet"/>
<link href="/javascript/jquery-timepicker/jquery-ui-timepicker-addon.css" rel="stylesheet"/> <link href="/javascript/jquery-timepicker/jquery-ui-timepicker-addon.css" rel="stylesheet"/>
<input {{attrs}} name="datetimepicker" type="text" class="form-control" placeholder="Date"/> <input {{attrs}} name="{{name}}" type="text" class="form-control" placeholder="Date"/>
<script> <script>
$(document).ready(function(){ $(document).ready(function(){
$("#{{id}}").datetimepicker({ $("#{{id}}").datetimepicker({
......
...@@ -29,6 +29,7 @@ class DateTimePicker(Input): ...@@ -29,6 +29,7 @@ class DateTimePicker(Input):
super().render(name, value, attrs) super().render(name, value, attrs)
flat_attrs = flatatt(attrs) flat_attrs = flatatt(attrs)
context = Context({ context = Context({
'name': name,
'attrs': flat_attrs, 'attrs': flat_attrs,
'id': attrs['id'], 'id': attrs['id'],
'closeText': _("Close"), 'closeText': _("Close"),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment