Bug 32805 - When recording localuse in the statistics table location is always NULL
Summary: When recording localuse in the statistics table location is always NULL
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Reports (show other bugs)
Version: Main
Hardware: All All
: P5 - low minor (vote)
Assignee: Lucas Gass
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-02-02 19:07 UTC by Lucas Gass
Modified: 2023-12-28 20:43 UTC (History)
1 user (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.05.00,22.11.04


Attachments
Bug 32805: Update location when recording a localuse in statistics table (1.05 KB, patch)
2023-02-02 19:10 UTC, Lucas Gass
Details | Diff | Splinter Review
Bug 32805: Update location when recording a localuse in statistics table (1.11 KB, patch)
2023-02-03 17:07 UTC, Andrew Fuerste-Henry
Details | Diff | Splinter Review
Bug 32805: Add tests (2.06 KB, patch)
2023-02-23 14:53 UTC, Lucas Gass
Details | Diff | Splinter Review
Bug 32805: Update location when recording a localuse in statistics table (1.18 KB, patch)
2023-02-23 15:30 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 32805: Add tests (2.30 KB, patch)
2023-02-23 15:30 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Lucas Gass 2023-02-02 19:07:09 UTC
When UpdateStats records a localuse in the statistics table the location is always NULL.
Comment 1 Lucas Gass 2023-02-02 19:10:48 UTC
Created attachment 146024 [details] [review]
Bug 32805: Update location when recording a localuse in statistics table

To test:
1. Create a statistical patron and checkout, checkin to them.
2. Notice in the statistics table that the location is NULL
3. Apply patch
4. Try steps 1-2 again
5. The location should be correctly recorded in statistics.location
Comment 2 Andrew Fuerste-Henry 2023-02-03 17:07:53 UTC
Created attachment 146158 [details] [review]
Bug 32805: Update location when recording a localuse in statistics table

To test:
1. Create a statistical patron and checkout, checkin to them.
2. Notice in the statistics table that the location is NULL
3. Apply patch
4. Try steps 1-2 again
5. The location should be correctly recorded in statistics.location

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Comment 3 Jonathan Druart 2023-02-23 09:25:02 UTC
This change needs a test.
Comment 4 Lucas Gass 2023-02-23 14:53:03 UTC
Created attachment 147249 [details] [review]
Bug 32805: Add tests
Comment 5 Lucas Gass 2023-02-23 14:53:51 UTC
(In reply to Jonathan Druart from comment #3)
> This change needs a test.

Added tests and setting status back to 'Signed-off'
Comment 6 Jonathan Druart 2023-02-23 15:30:28 UTC
Created attachment 147256 [details] [review]
Bug 32805: Update location when recording a localuse in statistics table

To test:
1. Create a statistical patron and checkout, checkin to them.
2. Notice in the statistics table that the location is NULL
3. Apply patch
4. Try steps 1-2 again
5. The location should be correctly recorded in statistics.location

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 7 Jonathan Druart 2023-02-23 15:30:31 UTC
Created attachment 147257 [details] [review]
Bug 32805: Add tests

JD amended patch: tidy

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 8 Tomás Cohen Arazi 2023-02-24 20:06:31 UTC
Pushed to master for 23.05.

Nice work everyone, thanks!
Comment 9 Matt Blenkinsop 2023-02-28 16:50:30 UTC
Nice work everyone!

Pushed to stable for 22.11.x
Comment 10 Lucas Gass 2023-03-08 13:55:05 UTC
Doesn't apply to 22.05.x, no backport.