[Bug 21979] New: Add option to SIP2 config to send shelving location ( or other field ) in CR instead of collection code
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Bug ID: 21979 Summary: Add option to SIP2 config to send shelving location ( or other field ) in CR instead of collection code Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: SIP2 Assignee: koha-bugs@lists.koha-community.org Reporter: kyle@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org CC: colin.campbell@ptfs-europe.com Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |kyle@bywatersolutions.com |ity.org | -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Add option to SIP2 config |Add option to SIP2 config |to send shelving location ( |to send arbitrary item |or other field ) in CR |field in CR instead of |instead of collection code |collection code -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 --- Comment #1 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 82998 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=82998&action=edit Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. Test Plan: 1) Apply this patch 2) Set the new option cr_item_field to 'shelving_location' 3) Restart the SIP server 3) Perform a checkin via SIP 4) Note the CR field contains the shelving location code in the response 5) Perform an item information request 6) Note the CR field contains the shelving location code in the response -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #82998|0 |1 is obsolete| | --- Comment #2 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 83102 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=83102&action=edit Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. Test Plan: 1) Apply this patch 2) Set the new option cr_item_field to 'shelving_location' 3) Restart the SIP server 3) Perform a checkin via SIP 4) Note the CR field contains the shelving location code in the response 5) Perform an item information request 6) Note the CR field contains the shelving location code in the response -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Josef Moravec <josef.moravec@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |black23@gmail.com, | |josef.moravec@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Jesse Maseto <jesse@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jesse@bywatersolutions.com --- Comment #3 from Jesse Maseto <jesse@bywatersolutions.com> --- Hi Kyle, There are a few merge conflicts with this patch. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #83102|0 |1 is obsolete| | --- Comment #4 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 93358 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=93358&action=edit Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. Test Plan: 1) Apply this patch 2) Set the new option cr_item_field to 'shelving_location' 3) Restart the SIP server 3) Perform a checkin via SIP 4) Note the CR field contains the shelving location code in the response 5) Perform an item information request 6) Note the CR field contains the shelving location code in the response -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Jesse Maseto <jesse@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Jesse Maseto <jesse@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #93358|0 |1 is obsolete| | --- Comment #5 from Jesse Maseto <jesse@bywatersolutions.com> --- Created attachment 93535 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=93535&action=edit Works as expected. Thanks. -JesseM Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. Test Plan: 1) Apply this patch 2) Set the new option cr_item_field to 'shelving_location' 3) Restart the SIP server 3) Perform a checkin via SIP 4) Note the CR field contains the shelving location code in the response 5) Perform an item information request 6) Note the CR field contains the shelving location code in the response Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Bouzid Fergani <bouzid.fergani@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |bouzid.fergani@inlibro.com --- Comment #6 from Bouzid Fergani <bouzid.fergani@inlibro.com> --- Hi Kyle, We have conflict in etc/SIPconfig.xml when applying. Bug 21979 - Add option to SIP2 config to send arbitrary item field in CR instead of collection code 93535 - Works as expected. Thanks. Apply? [(y)es, (n)o, (i)nteractive] y Applying: Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Using index info to reconstruct a base tree... M etc/SIPconfig.xml Falling back to patching base and 3-way merge... Auto-merging etc/SIPconfig.xml CONFLICT (content): Merge conflict in etc/SIPconfig.xml error: Failed to merge in the changes. Patch failed at 0001 Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code The copy of the patch that failed is found in: .git/rebase-apply/patch When you have resolved this problem run "git bz apply --continue". If you would prefer to skip this patch, instead run "git bz apply --skip". To restore the original branch and stop patching run "git bz apply --abort". Patch left in /tmp/Works-as-expected-Thanks-ELLAUG.patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org --- Comment #7 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Kyle, I did not test but I see: + $resp .= maybe_add( FID_COLLECTION_CODE, $item->collection_code, $server ); then: + if ( my $CR = $server->{account}->{cr_item_field} ) { + $resp .= maybe_add( FID_COLLECTION_CODE, $item->{$CR} ); + } else { + $resp .= maybe_add( FID_COLLECTION_CODE, $item->collection_code ); + } Is that correct? (twice maybe_add with FID_COLLECTION_CODE) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #93535|0 |1 is obsolete| | --- Comment #8 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 98066 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=98066&action=edit Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. Test Plan: 1) Apply this patch 2) Set the new option cr_item_field to 'shelving_location' 3) Restart the SIP server 3) Perform a checkin via SIP 4) Note the CR field contains the shelving location code in the response 5) Perform an item information request 6) Note the CR field contains the shelving location code in the response Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 --- Comment #9 from Kyle M Hall <kyle@bywatersolutions.com> --- (In reply to Jonathan Druart from comment #7)
Kyle, I did not test but I see:
+ $resp .= maybe_add( FID_COLLECTION_CODE, $item->collection_code, $server );
then:
+ if ( my $CR = $server->{account}->{cr_item_field} ) { + $resp .= maybe_add( FID_COLLECTION_CODE, $item->{$CR} ); + } else { + $resp .= maybe_add( FID_COLLECTION_CODE, $item->collection_code ); + }
Is that correct? (twice maybe_add with FID_COLLECTION_CODE)
Fixed! Looks like the original patch got a bad rebase perhaps. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Bouzid Fergani <bouzid.fergani@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #98066|0 |1 is obsolete| | --- Comment #10 from Bouzid Fergani <bouzid.fergani@inlibro.com> --- Created attachment 101308 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=101308&action=edit Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. Test Plan: 1) Apply this patch 2) Set the new option cr_item_field to 'shelving_location' 3) Restart the SIP server 3) Perform a checkin via SIP 4) Note the CR field contains the shelving location code in the response 5) Perform an item information request 6) Note the CR field contains the shelving location code in the response Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Patch doesn't apply --- Comment #11 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Patch no longer applies, please rebase! Apply? [(y)es, (n)o, (i)nteractive] y Applying: Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Using index info to reconstruct a base tree... M C4/SIP/ILS/Item.pm M C4/SIP/Sip/MsgType.pm M etc/SIPconfig.xml Falling back to patching base and 3-way merge... Auto-merging etc/SIPconfig.xml Auto-merging C4/SIP/Sip/MsgType.pm Auto-merging C4/SIP/ILS/Item.pm CONFLICT (content): Merge conflict in C4/SIP/ILS/Item.pm error: Failed to merge in the changes. Patch failed at 0001 Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code The copy of the patch that failed is found in: .git/rebase-apply/patch When you have resolved this problem run "git bz apply --continue". If you would prefer to skip this patch, instead run "git bz apply --skip". To restore the original branch and stop patching run "git bz apply --abort". Patch left in /tmp/Bug-21979-Add-option-to-SIP2-config-to-send-arbitr-uD5jqS.patch I have some issues setting up SIP on my kohadevbox - looking for a tutor! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #101308|0 |1 is obsolete| | --- Comment #12 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 108502 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=108502&action=edit Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. Test Plan: 1) Apply this patch 2) Set the new option cr_item_field to 'shelving_location' 3) Restart the SIP server 3) Perform a checkin via SIP 4) Note the CR field contains the shelving location code in the response 5) Perform an item information request 6) Note the CR field contains the shelving location code in the response Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #108502|0 |1 is obsolete| | --- Comment #13 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 110746 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=110746&action=edit Bug 21979: Add option to SIP2 config to send arbitrary item field in CR instead of collection code Some libraries need to send a different field as the collection code, depending on how the library catalogs items. We should allow any arbitrary item field to be used as the value for the CR field. Test Plan: 1) Apply this patch 2) Set the new option cr_item_field to 'shelving_location' 3) Restart the SIP server 3) Perform a checkin via SIP 4) Note the CR field contains the shelving location code in the response 5) Perform an item information request 6) Note the CR field contains the shelving location code in the response Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA CC| |martin.renvoize@ptfs-europe | |.com --- Comment #14 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- This works as expected and the code reads well... Should we be adding Unit Tests for these SIP additions however...? Passing QA and letting the RM weight in on the above. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 --- Comment #15 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 110757 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=110757&action=edit Bug 21979: Add unit tests -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |20.11.00 released in| | Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 --- Comment #16 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 20.11, thanks to everybody involved! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lucas@bywatersolutions.com --- Comment #17 from Lucas Gass <lucas@bywatersolutions.com> --- enhancement will not be backported to 20.05.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21979 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |27589 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27589 [Bug 27589] Error when specifying CR field in SIP Config -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org