Summary: | new plugin about Automatic Number incrementing inventory. Prefix management from a authorised values list | ||
---|---|---|---|
Product: | Koha | Reporter: | delaye <stephane.delaye> |
Component: | Cataloging | Assignee: | Jonathan Druart <jonathan.druart> |
Status: | CLOSED FIXED | QA Contact: | Ian Walls <koha.sekjal> |
Severity: | enhancement | ||
Priority: | P5 - low | CC: | f.demians, koha.aixmarseille, paul.poulain |
Version: | 3.10 | ||
Hardware: | All | ||
OS: | All | ||
GIT URL: | Change sponsored?: | Sponsored | |
Patch complexity: | --- | Documentation contact: | |
Documentation submission: | Text to go in the release notes: | ||
Version(s) released in: | Circulation function: | ||
Attachments: |
Bug 7992: Specific plugin stocknumberam123 improvements
Bug 7992: Specific plugin stocknumberam123 improvements Bug 7992: Followup use ajax with jQuery instead of YUI Bug 7992: Followup: Rename the plugin stocknumberam123 with stocknumberAV Bug 7992: New plugin stocknumberamAV Bug 7992: New plugin stocknumberAV Bug 7992: New plugin stocknumberAV |
Description
delaye
2012-04-23 07:46:28 UTC
Created attachment 9402 [details] [review] Bug 7992: Specific plugin stocknumberam123 improvements I tested from a sandbox I associated the plugin stocknumberam123.pl at 995$a -> stocknumber I created a list of authorised values INVENTORY But since the item record i can't update the 995$a , i can't write the prefix and when i want use the plugin no action Created attachment 9868 [details] [review] Bug 7992: Specific plugin stocknumberam123 improvements Bugzilla description (from delaye): 1 / Create a list of authorised values(INVENTORY_NUMBER). In which the code is the prefix and the description the last number assigned. 2/A space between the prefix and number. 3 / From a holding record, after indicate the prefix when you click on the plugin -> koha search the last number from authorised values assigned in the list and increment n +1 level meter This patch uses YUI to send a asynchronous HTTP request. But YUI is about to be replaced completly by jQuery + jQuery UI. Could you switch from YUI to jQuery? Created attachment 11600 [details] [review] Bug 7992: Followup use ajax with jQuery instead of YUI Could you please provide a test plan for this? I can't quite understand what it is supposed to do. Test plan: - Link a field with the plugin stocknumber_am123 (eg. 995$j) - add an authorised value for the category INVENTORY (eg PREFIX) with a value in the description field (eg. 50) - In the cataloguing module, add a biblio and fill the field with 'PREFIX' and click on the plugin link. The field must be filled with the string "PREFIX 0000000051" I just tried this with the following configuration: 1. Link plugin to 952$p 2. Create an authorized value in the INVENTORY category called 'PR' with the description '0000087' When I clicked the plugin, it did not populate the field. Any idea what I might have done wrong? Also, I have a question: what if you have multiple authorized value in the INVENTORY category? You can specify multiple values (prefix) under the category INVENTORY. Each prefix has his counter indicates in description field. it is not necessary to specify in description 0000. Specify 87 instead of 0000087 I am wondering if this change will cause problems for people already using the older version of the plugin. Could it make sense to give it a new name? (In reply to comment #9) > You can specify multiple values (prefix) under the category INVENTORY. > Each prefix has his counter indicates in description field. How do you choose which prefix is being used? > it is not necessary to specify in description 0000. Specify 87 instead of > 0000087 The plugin should still work if there are leading 0s, I think, and I don't see any code that tells the plugin to ignore them. (In reply to comment #11) > How do you choose which prefix is being used? You have to enter your prefix before to click on the plugin link > The plugin should still work if there are leading 0s, I think, and I don't > see any code that tells the plugin to ignore them. I have just to test and it works. (VA, INVENTORY, new, value = PREFIX, desc = 0000000051, cataloguing, fill PREFIX into 995$j, click on the link, the field is filled with "PREFIX 0000000052") (In reply to comment #10) > I am wondering if this change will cause problems for people already using > the older version of the plugin. Could it make sense to give it a new name? It is not the same behaviour. This plugin is not here to replace the currently one. The interest of the new plugin is that it will not search in the database items what is the last stocknumber but it will control the last stcknumber in authorised values. This mode of control is different avoids errors increment especially after a data migration where it can be seen that the dialing mode was not consistent. The old plugin can not "fix" while the solution proposed by the authorised values to restart the numbering consistently. And enables simpler and more effective control of the incrementation through the VA Regarding the name of the plugin I agree to change i propose : as new name - > stocknumberAV AV : authorised values (In reply to comment #12) > (In reply to comment #11) > > How do you choose which prefix is being used? > You have to enter your prefix before to click on the plugin link Thank you. This is the step I was missing. Hi Stephane - the new name makes sense to me :) I think the descriptions sounds really good and will add some interesting functionality, I was only worried about overwriting an existant script. I just tested it, and it works great. Actually, this is functionality I've been needing. A signoff is yours if you do a follow-up or revised patch changing the name of the plugin. Created attachment 11893 [details] [review] Bug 7992: Followup: Rename the plugin stocknumberam123 with stocknumberAV The problem here is that we already have a stocknumberam123 plugin, so this revised plugin needs to be called stocknumberAV, and the existing stocknumberam123 needs to be kept. With your permission, I will remove the updatedatabase stanza, and re-add the stocknumberam123 plugin in the third follow-up. To clarify, I meant amending the follow-up that you just attached. We don't want to change the functionality from under the feet of libraries currently using it. Hum, and we will have 3 plugins for stocknumber ? :) Why not? :) Created attachment 11895 [details] [review] Bug 7992: New plugin stocknumberamAV Bugzilla description (from delaye): 1 / Create a list of authorised values(INVENTORY_NUMBER). In which the code is the prefix and the description the last number assigned. 2/A space between the prefix and number. 3 / From a holding record, after indicate the prefix when you click on the plugin -> koha search the last number from authorised values assigned in the list and increment n +1 level meter Created attachment 11896 [details] [review] Bug 7992: New plugin stocknumberAV Bugzilla description (from delaye): 1 / Create a list of authorised values(INVENTORY_NUMBER). In which the code is the prefix and the description the last number assigned. 2/A space between the prefix and number. 3 / From a holding record, after indicate the prefix when you click on the plugin -> koha search the last number from authorised values assigned in the list and increment n +1 level meter the plugin stocknumberam123 already installed does not work. probably a mistake. we must keep the plugin stocknumber then add stocknumberAV related bz7992 and delete the stocknumberam123 (In reply to comment #25) > the plugin stocknumberam123 already installed does not work. probably a > mistake. we must keep the plugin stocknumber then add stocknumberAV related > bz7992 > and delete the stocknumberam123 I'd suggest that removing the plugin should be done on a different bug. Created attachment 11897 [details] [review] Bug 7992: New plugin stocknumberAV Bugzilla description (from delaye): 1 / Create a list of authorised values(INVENTORY_NUMBER). In which the code is the prefix and the description the last number assigned. 2/A space between the prefix and number. 3 / From a holding record, after indicate the prefix when you click on the plugin -> koha search the last number from authorised values assigned in the list and increment n +1 level meter Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com> Works as advertised (see provisos below). Tested the following: 1) INVENTORY category has only authorised value 'PR' => PR prefix filled in, everything else gives an error. 2) INVENTORY category has two authorised values, both work. 3) INVENTORY category has no authorised values, nothing is incremented 4) Barcode contains numbers, nothing is changed. Two potential gotchas (neither of them significant enough to warrant changing, in my opinion): 1) Prefixes must consist only of uppercase alphabetical characters. 2) Negative numbers are padded with zeros to the left of the negative sign. Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com> for information There are 3 plugin stocknumber stocknumberam123 and stocknumberAV What is the difference? stocknumber : add the branch code (branch connection) as prefix in the inventory number (eg MED_00006). stocknumberam123 plugin: in the item record you add a prefix of your choice followed by a space then the number is added . There is a control in the database items. stocknumberAV: in the item record you add a prefix who was specified authorised value (INVENTORY) then the number is added. There is a control in the authorised values (INVENTORY). QA comment * 0 side effect risk, cataloguing plugin independant from anything else * passes koha-qa.pl * documentation included Passes QA Patch pushed to master Version changed = no reason to put it in 3.8 (but no risk as well, so, chris_c, your choice ;-) ) |