Created attachment 135018 [details] [review] Bug 30775: Make 952w to have datepicker plugin by default This field (Price effective from) is very similar to 952d, but it doesn't have dateaccessioned.pl plugin by default, Apart of worse usability of this it is also allows to enter wrong date which will be converted in 0000-00-00 in DB and even lead to crashes by code in other places. So, adding this plugin not only improves usability (user can have datepicker) but also adds date field validation. Test plan: 1. Head over to MARC frameworks from your administration page, check 952 subfield structure of your default framework structure. 2. dateaccessioned.pl is set as a plugin for 952d by default but is missing from 952w. 3. Apply the patch and reset your koha, drop db and use reset_all alias. 4. Check frameworks structure again and ensure that datepicker plugin is set by default for 952w. 5. Edit some item to ensure that datepicker works for that 952w.
Created attachment 135461 [details] [review] Bug 30775: Make 952w to have datepicker plugin by default This field (Price effective from) is very similar to 952d, but it doesn't have dateaccessioned.pl plugin by default, Apart of worse usability of this it is also allows to enter wrong date which will be converted in 0000-00-00 in DB and even lead to crashes by code in other places. So, adding this plugin not only improves usability (user can have datepicker) but also adds date field validation. Test plan: 1. Head over to MARC frameworks from your administration page, check 952 subfield structure of your default framework structure. 2. dateaccessioned.pl is set as a plugin for 952d by default but is missing from 952w. 3. Apply the patch and reset your koha, drop db and use reset_all alias. 4. Check frameworks structure again and ensure that datepicker plugin is set by default for 952w. 5. Edit some item to ensure that datepicker works for that 952w. Signed-off-by: David Nind <david@davidnind.com>
Testing notes (using koha-testing-docker): - For step 3: apply the patch, then reset_all ==> 952$w should have dateaccessioned.pl
Created attachment 136152 [details] [review] Bug 30775: Make 952w to have datepicker plugin by default This field (Price effective from) is very similar to 952d, but it doesn't have dateaccessioned.pl plugin by default, Apart of worse usability of this it is also allows to enter wrong date which will be converted in 0000-00-00 in DB and even lead to crashes by code in other places. So, adding this plugin not only improves usability (user can have datepicker) but also adds date field validation. Test plan: 1. Head over to MARC frameworks from your administration page, check 952 subfield structure of your default framework structure. 2. dateaccessioned.pl is set as a plugin for 952d by default but is missing from 952w. 3. Apply the patch and reset your koha, drop db and use reset_all alias. 4. Check frameworks structure again and ensure that datepicker plugin is set by default for 952w. 5. Edit some item to ensure that datepicker works for that 952w. Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Good call, works as described and is a sensible default. PQA
Pushed to master for 22.11. Nice work everyone, thanks!
Backported to 22.05.x for 22.05.04
pushed to 21.11.x for 21.11.11
Not backported to oldoldstable (21.05.x). Feel free to ask if it's needed. Nothing to document, marking resolved.