Uh oh!
There was an error while loading. Please reload this page.
280 areyousure - #366
Conversation
Uh oh!
There was an error while loading. Please reload this page.
felixrindt
left a comment
There was a problem hiding this comment.
@garinm90 Nice! Using the plugin is was very simple! Only thing on my mind now is internationalization. How do we get an e.g. german translation into the alert?
| }).on("formAdded", "div", function (event) { | ||
| handleForms($(event.target)); | ||
| }); | ||
| $('form').trigger('reinitialize.areYouSure'); |
There was a problem hiding this comment.
I moved this line up here, as this function is used for all dynamically added inputs and it now also fully works in the shift edit view when changing the signup method (which was done using a select and some view-specific JS).
garinm90
commented
Mar 15, 2021
After doing some digging looks like Django offers a solution for this. I'll look into adding this so future JavaScript modules will also have access to these translations! |
felixrindt
commented
Mar 20, 2021
By the way, we are already using jsi18n... |
Are you sure?-Prompts #280
Add are you sure jQuery plugin.
Load this plugin on form pages. Add classes to inputs that dynamically create new forms to be monitored.