-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
More than 1 datepicker field results in multiple CSS and JS #5
Comments
any news on this? |
I included the js in my main template like this: {% javascripts {% endjavascripts %} and tried to override the jquery_layout.html.twig, but the bundle is not reading my jquery_layout.html.twig :( |
fogs
pushed a commit
to SoftwareBetrieb/DatetimepickerBundle
that referenced
this issue
Jan 24, 2017
…collot#20 Changed div_layout.html.twig to contain all options as data-* attributes in the single_text form field. This allows initialization of datetimepicker without option in JS and you can have several fields in one form. Both form_javascript(form) and form_stylesheet(form) are not needed any more (see README for details)
fogs
pushed a commit
to SoftwareBetrieb/DatetimepickerBundle
that referenced
this issue
Jan 24, 2017
…collot#20 Changed div_layout.html.twig to contain all options as data-* attributes in the single_text form field. This allows initialization of datetimepicker without option in JS and you can have several fields in one form. Both form_javascript(form) and form_stylesheet(form) are not needed any more (see README for details)
fogs
pushed a commit
to SoftwareBetrieb/DatetimepickerBundle
that referenced
this issue
Apr 29, 2018
…collot#20 Changed div_layout.html.twig to contain all options as data-* attributes in the single_text form field. This allows initialization of datetimepicker without option in JS and you can have several fields in one form. Both form_javascript(form) and form_stylesheet(form) are not needed any more (see README for details)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I have a form with 6 different date fields. I assign the datepicker to each field, and they all work correctly.
However, where I place {{ form_stylesheet(edit_form) }} in my Twig template results in a tag to the same CSS file 6 times (i.e. the number of datepicker fields on my form.
The same is true for the JS - it adds a SCRIPT tag for each datepicker field.
Surely these files should only be included once?
The text was updated successfully, but these errors were encountered: