[Koha-bugs] [Bug 32306] Hold modifications don't log correctly

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon Jan 23 17:10:31 CET 2023


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32306

Emily Lamancusa <emily.lamancusa at montgomerycountymd.gov> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #144216|0                           |1
        is obsolete|                            |

--- Comment #4 from Emily Lamancusa <emily.lamancusa at montgomerycountymd.gov> ---
Created attachment 145588
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=145588&action=edit
Bug 32306: Log after storing changes in ModReserve

When one modifies holds from records holds page, these
changes don't log into action_logs table correctly.
Instead holds data before modifications is stored to action_logs.

This patch moves call for logaction after changes have
been stored in ModReserve.

To test:
1. Find hold to modify.
2. If possible, locate this hold from action_logs table:
SELECT * FROM action_logs WHERE module = "HOLDS" AND object = <reserve_id>;
3. Modify hold, change its pickup library from A to B.
4. Save changes.
5. Take a look at action_logs table.
=> Modification is saved, but holds pickup library is still A.
6. Modify hold again, e.g add expiration date.
7. Save.
8. Find this new modification from action_logs.
=> In action_logs table expiration date is empty, but pickup library is now B.
9. Apply this patch.
10. Modify hold, change its pickup library back from B to A.
11. Save changes.
=> In action_logs table holds modification has now a correct pickup library A.

Also prove t/db_dependent/Reserves.t.

Sponsored-by: Koha-Suomi Oy
Signed-off-by: Emily Lamancusa <emily.lamancusa at montgomerycountymd.gov>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list