[Bug 26459] New: Allow sip_cli_emulator to handle cancelling holds
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Bug ID: 26459 Summary: Allow sip_cli_emulator to handle cancelling holds Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Command-line Utilities Assignee: koha-bugs@lists.koha-community.org Reporter: nick@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org CC: robin@catalyst.net.nz -- 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=26459 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 --- Comment #1 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 110071 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=110071&action=edit Bug 26459: Add hold-mode option to sip_cli_emulator To test: 1 - Apply patch 2 - Restart all 3 - Place an item level hold for a patron via the staff client 4 - Cancel the hold using the sip_cli_emulator with hold-mode: - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --patron {cardnumber} --item {BARCODE} -m hold -l CPL --hold-mode - 5 - Run the sip_cli_emulator with no params 6 - Verify help text is understandable -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |nick@bywatersolutions.com |ity.org | -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 David Nind <david@davidnind.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=26459 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #110071|0 |1 is obsolete| | --- Comment #2 from David Nind <david@davidnind.com> --- Created attachment 113066 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113066&action=edit Bug 26459: Add hold-mode option to sip_cli_emulator To test: 1 - Apply patch 2 - Restart all 3 - Place an item level hold for a patron via the staff client 4 - Cancel the hold using the sip_cli_emulator with hold-mode: - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --patron {cardnumber} --item {BARCODE} -m hold -l CPL --hold-mode - 5 - Run the sip_cli_emulator with no params 6 - Verify help text is understandable Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kyle@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |victor@tuxayo.net --- Comment #3 from Victor Grousset/tuxayo <victor@tuxayo.net> --- It works and QA tools are happy :) 1. It seems these two lines of code do the same thing: default to + if not - passed hold_mode => $hold_mode eq '-' ? '-' : '+', my $hold_mode = $params->{hold_mode} || '+'; 2. IIUC we are using a separated flag as opposed to having something like "-m hold+"/"-m hold" and "-m hold-" (not sure if that would be more clear to use) because that reflects better the underlying SIP protocol. (direct mapping to the flag) A bit verbose the separate flag but that should make sense. 3. Accepts +: Add hold or -: Cancel hold, defaults to + Is ↓that↓ more clear? Accepts "+" to add hold or "-" to cancel hold, defaults to + 4. Not really related thing, shouldn't the following place an item level hold? sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --patron 23529001000463 --item 39999000000511 -m hold -l CPL It places a record level one. (which can be piled up and bypasses Holds per record circ rule) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 --- Comment #4 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 118980 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=118980&action=edit Bug 26459: (follow-up) Clarify language and remove duplicated code -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 --- Comment #5 from Nick Clemens <nick@bywatersolutions.com> --- (In reply to Victor Grousset/tuxayo from comment #3)
It works and QA tools are happy :)
1. It seems these two lines of code do the same thing: default to + if not - passed
hold_mode => $hold_mode eq '-' ? '-' : '+', my $hold_mode = $params->{hold_mode} || '+';
OK, removed
2. IIUC we are using a separated flag as opposed to having something like "-m hold+"/"-m hold" and "-m hold-" (not sure if that would be more clear to use) because that reflects better the underlying SIP protocol. (direct mapping to the flag) A bit verbose the separate flag but that should make sense.
I can rebuild if there is strong preference, I just wanted a quikc way to do this
3. Accepts +: Add hold or -: Cancel hold, defaults to + Is ↓that↓ more clear? Accepts "+" to add hold or "-" to cancel hold, defaults to +
Yes, updated
4. Not really related thing, shouldn't the following place an item level hold?
sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --patron 23529001000463 --item 39999000000511 -m hold -l CPL
It places a record level one. (which can be piled up and bypasses Holds per record circ rule)
See bug 26461 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 --- Comment #6 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Thanks for the fixes :)
2.
I can rebuild if there is strong preference, I just wanted a quikc way to do this
It's ok, I was just surprised by the params but they also make sense. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113066|0 |1 is obsolete| | --- Comment #7 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Created attachment 119026 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119026&action=edit Bug 26459: Add hold-mode option to sip_cli_emulator To test: 1 - Apply patch 2 - Restart all 3 - Place an item level hold for a patron via the staff client 4 - Cancel the hold using the sip_cli_emulator with hold-mode: - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --patron {cardnumber} --item {BARCODE} -m hold -l CPL --hold-mode - 5 - Run the sip_cli_emulator with no params 6 - Verify help text is understandable Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #118980|0 |1 is obsolete| | --- Comment #8 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Created attachment 119027 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119027&action=edit Bug 26459: (follow-up) Clarify language and remove duplicated code Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA --- Comment #9 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Still work, QA tools happy, code ok :) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |21.05.00 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 --- Comment #10 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 21.05, 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=26459 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m Status|Pushed to master |Pushed to stable Version(s)|21.05.00 |21.05.00,20.11.05 released in| | --- Comment #11 from Fridolin Somers <fridolin.somers@biblibre.com> --- Applies on 20.11.x, I choose to backport. Pushed to 20.11.x for 20.11.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26459 Andrew Fuerste-Henry <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |andrew@bywatersolutions.com Status|Pushed to stable |RESOLVED Resolution|--- |FIXED --- Comment #12 from Andrew Fuerste-Henry <andrew@bywatersolutions.com> --- enhancement, not backporting to 20.05. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org