Bug 15751 - Koha offline circulation Firefox addon does not update last seen date for check-ins
Summary: Koha offline circulation Firefox addon does not update last seen date for che...
Status: Pushed to oldstable
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Martin Renvoize
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-02-05 19:05 UTC by Owen Leonard
Modified: 2020-05-15 17:31 UTC (History)
15 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:
20.05.00, 19.11.06, 19.05.11


Attachments
Bug 15751: Add ModDateLastSeen to ProcessOfflineReturn (1.04 KB, patch)
2019-12-11 11:55 UTC, Martin Renvoize
Details | Diff | Splinter Review
Bug 15751: Add ModDateLastSeen to ProcessOfflineReturn (1.06 KB, patch)
2019-12-11 12:14 UTC, Martin Renvoize
Details | Diff | Splinter Review
Bug 15751: Add ModDateLastSeen to ProcessOfflineReturn (1.11 KB, patch)
2020-04-10 10:17 UTC, sandboxes@biblibre.com
Details | Diff | Splinter Review
Bug 15751: Add ModDateLastSeen to ProcessOfflineReturn (1.21 KB, patch)
2020-05-01 08:37 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2016-02-05 19:05:29 UTC
When I check in something using the KOCT the last seen date is not updated.

It does update the last seen date upon checkout, for what it's worth.
Comment 1 Alex Arnaud 2017-12-05 16:48:21 UTC
It's clear for me that the problem exists on Koha side. It seems that ProcessOfflineReturn use MarkIssueReturned and not AddReturn (which do the ModDateLastSeen). I wonder why there is 2 subs handling checkin and not one...
Comment 2 Martin Renvoize 2019-12-11 11:55:51 UTC
Created attachment 96201 [details] [review]
Bug 15751: Add ModDateLastSeen to ProcessOfflineReturn

Test plan:
1) Before the patch when one checks in something using the KOCT the last seen
date is not updated.
2) After the patch when one checks in something using the KOCT the last seen
   date is updated.
Comment 3 Martin Renvoize 2019-12-11 11:56:57 UTC
The reason for two subs is that a KOCT transaction cannot deal with the error cases that AddReturn can throw.. as such we perform the actual return regardless of any normal error cases.
Comment 4 Martin Renvoize 2019-12-11 12:14:48 UTC
Created attachment 96203 [details] [review]
Bug 15751: Add ModDateLastSeen to ProcessOfflineReturn

Test plan:
1) Before the patch when one checks in something using the KOCT the last seen
date is not updated.
2) After the patch when one checks in something using the KOCT the last seen
   date is updated.
Comment 5 Jonathan Druart 2019-12-16 09:55:32 UTC
I am wondering if the fix is not to use AddReturn instead of MarkIssueReturned. See also bug 21494 and https://lists.koha-community.org/pipermail/koha-devel/2019-December/045432.html
Comment 6 Magnus Enger 2020-03-23 19:45:19 UTC
Looking at signing off this. 

Tempted to set it to "in discussion" because of comment 5, but I think Martin sort of answered it in comment 3?

Then I see there are no tests for ProcessOfflineReturn, and not for ProcessOfflineIssue or ProcessOfflinePayment either. But asking for that might be a bit too much on this bug?
Comment 7 sandboxes@biblibre.com 2020-04-10 10:17:12 UTC
Patch tested with a sandbox, by Laurence Rault <laurence.rault@biblibre.com>
Comment 8 sandboxes@biblibre.com 2020-04-10 10:17:34 UTC
Created attachment 102692 [details] [review]
Bug 15751: Add ModDateLastSeen to ProcessOfflineReturn

Test plan:
1) Before the patch when one checks in something using the KOCT the last seen
date is not updated.
2) After the patch when one checks in something using the KOCT the last seen
   date is updated.

Signed-off-by: Laurence Rault <laurence.rault@biblibre.com>
Comment 9 Marcel de Rooy 2020-05-01 08:37:46 UTC
Created attachment 104074 [details] [review]
Bug 15751: Add ModDateLastSeen to ProcessOfflineReturn

Test plan:
1) Before the patch when one checks in something using the KOCT the last seen
date is not updated.
2) After the patch when one checks in something using the KOCT the last seen
   date is updated.

Signed-off-by: Laurence Rault <laurence.rault@biblibre.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 10 Martin Renvoize 2020-05-01 09:01:48 UTC
(In reply to Magnus Enger from comment #6)
> Looking at signing off this. 
> 
> Tempted to set it to "in discussion" because of comment 5, but I think
> Martin sort of answered it in comment 3?
> 
> Then I see there are no tests for ProcessOfflineReturn, and not for
> ProcessOfflineIssue or ProcessOfflinePayment either. But asking for that
> might be a bit too much on this bug?

Adding tests would certainly be preferable.. I'm going to keep this one in my queue and attempt to write tests as part of push.
Comment 11 Martin Renvoize 2020-05-04 07:41:47 UTC
Nice work everyone!

Pushed to master for 20.05
Comment 12 Joy Nelson 2020-05-08 23:00:22 UTC
backported to 19.11.x for 19.11.06
Comment 13 Lucas Gass 2020-05-15 17:31:32 UTC
backported to 19.05.x for 19.05.11