It looks like between bug 30407 and bug 25560 we lost the line that made the update conditional: $item->notforloan($rules->{$key})->store({ log_action => 0, skip_record_index => 1, skip_holds_queue => 1 }) unless $rules->{$key} eq 'ONLYMESSAGE';
Created attachment 160499 [details] [review] Bug 35692: Unit test
Created attachment 160500 [details] [review] Bug 35692: Do not update not for loan status if ONLYMESSAGE is provided To test: 1 - Set UpdateNotForLoanStatusOnCheckin to: _ALL_: -1: ONLYMESSAGE 2 - Set an item in the catalog as -1/Ordered 3 - Check the item in 4 - Confirm you see the message 5 - View the record details 6 - Item is now for loan 7 - Check item in again, no message 8 - Apply patch, restart all 9 - Set item as not for loan -1/Ordered 10 - Check item in, you see the message 11 - Check it in again, still see message 12 - Check the detail page, item still marked as ordered
Hi Nick, I noticed that too! I submitted a patchset in https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35293 but happy for your patchset to be upstreamed instead :) Thanks, Alex
Created attachment 160501 [details] [review] Bug 35692: Unit test Signed-off-by: David Nind <david@davidnind.com>
Created attachment 160502 [details] [review] Bug 35692: Do not update not for loan status if ONLYMESSAGE is provided To test: 1 - Set UpdateNotForLoanStatusOnCheckin to: _ALL_: -1: ONLYMESSAGE 2 - Set an item in the catalog as -1/Ordered 3 - Check the item in 4 - Confirm you see the message 5 - View the record details 6 - Item is now for loan 7 - Check item in again, no message 8 - Apply patch, restart all 9 - Set item as not for loan -1/Ordered 10 - Check item in, you see the message 11 - Check it in again, still see message 12 - Check the detail page, item still marked as ordered Signed-off-by: David Nind <david@davidnind.com>
Hi Nick, There is one difference between this and bug 35293 (the patchset I wrote) and that is 35293 re-adds the reference to ONLYMESSAGE into the UpdateNotForLoanStatusOnCheckin system preference which was also lost between bug 30407 and bug 25560 : https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160361 Would you like me to copy that patch over to your bug report here? Thanks, Alex
(In reply to Alex Buckley from comment #6) > Hi Nick, > > There is one difference between this and bug 35293 (the patchset I wrote) > and that is 35293 re-adds the reference to ONLYMESSAGE into the > UpdateNotForLoanStatusOnCheckin system preference which was also lost > between bug 30407 and bug 25560 : > https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160361 > > Would you like me to copy that patch over to your bug report here? > > Thanks, > Alex Hi Alex, either way works, you could also just copy my unit test over to the other and then mark them duplicate. I didn't see yours initially because the depends on wasn't marked :-)
*** This bug has been marked as a duplicate of bug 35293 ***
(In reply to Nick Clemens from comment #7) > (In reply to Alex Buckley from comment #6) > > Hi Nick, > > > > There is one difference between this and bug 35293 (the patchset I wrote) > > and that is 35293 re-adds the reference to ONLYMESSAGE into the > > UpdateNotForLoanStatusOnCheckin system preference which was also lost > > between bug 30407 and bug 25560 : > > https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160361 > > > > Would you like me to copy that patch over to your bug report here? > > > > Thanks, > > Alex > > Hi Alex, either way works, you could also just copy my unit test over to the > other and then mark them duplicate. I didn't see yours initially because the > depends on wasn't marked :-) Thanks so much Nick for making those changes! Apologies for not marking the depends on for bug 35293