This is part of the refactoring happening in bug 30975
Created attachment 146077 [details] [review] Bug 32819: Fix cataloguing/value_builder/stocknumberam123.pl Use event parameter This is part of the refactoring happening in bug 30975 Test plan: 1. Verify that the plugin continues to work as before
Created attachment 146409 [details] [review] Bug 32819: Fix cataloguing/value_builder/stocknumberam123.pl Use event parameter This is part of the refactoring happening in bug 30975 Test plan: 1. Verify that the plugin continues to work as before Signed-off-by: David Nind <david@davidnind.com>
Testing notes (using KTD): 1. Added stocknumberam123.pl as a plugin to 952$i for the BKS framework (MARC21). 2. Adding an inventory number with a prefix: 2.1 Add "PREFIX 0009678570" to an item for a record 2.3 Add "PREFIX" to another item for a different record 2.4 Click the three dots ==> Incremented and PREFIX 0009678571 added to the item 3. Adding a numerical inventory number: 3.1 Add 0009000000 to an item for a record 3.2 For another item for another record without a 952$i value, click the three dots ==> Number incremented and 0009000001 added to the item Description of plugin ~~~~~~~~~~~~~~~~~~~~~ This plugin is specific to AM123 but could be used as a base for similar operations. It is used for stocknumber computation. If the user send an empty string, we return a simple incremented stocknumber. If a prefix is submited, we look for the highest stocknumber with this prefix, and return it incremented. In this case, a stocknumber has this form : "PREFIX 0009678570". - PREFIX is an upercase word - a space separator - 10 digits, with leading 0s if needed
Created attachment 147725 [details] [review] Bug 32819: Fix cataloguing/value_builder/stocknumberam123.pl Use event parameter This is part of the refactoring happening in bug 30975 Test plan: 1. Verify that the plugin continues to work as before Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Pushed to master for 23.05. Nice work everyone, thanks!
Nice work, thanks everyone! Pushed to 22.11.x for the next release.
Backported to 22.05.x for upcoming 22.05.11
applied to 21.11 for 21.11.19
Not backported to 21.05.x