https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=44098 --- Comment #2 from Andrew Fuerste-Henry <andrew@bywatersolutions.com> --- Created attachment 212154 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=212154&action=edit Bug 44098: Add ISBN column to deleted bibliographic records table This patch adds an ISBN column to the 'Deleted bibliographic records' table on the 'Restore deleted records' tool, so librarians with the book in hand can scan its ISBN into the table search to find matching deleted records. To make the column searchable and sortable, Koha::Old::Biblios->api_query_fixer is fixed: it was rewriting biblioitem attributes to 'deletedbiblioitem.*', but the relationship is named 'biblioitem', so any query on ISBN (or any other biblioitem attribute) against /api/v1/deleted/biblios returned a 500 error. It now also accepts the 'me.' prefix the staff interface DataTables add to column searches. The existing ISBN API test was querying /api/v1/biblios instead of /api/v1/deleted/biblios, and the sample record never had an ISBN, which is why the bug went unnoticed. The test is fixed and extended. Test plan: 1. Create a bibliographic record with an ISBN (020$a), then delete it 2. Go to Cataloging > Restore deleted records 3. Without the patch: note there is no ISBN column 4. Apply the patch, restart_all 5. Reload the page: an ISBN column is shown for deleted records 6. Type or scan the ISBN in the table search box: the record is found 7. Sort by the ISBN column: it works 8. Run: $ prove t/db_dependent/api/v1/deleted_biblios.t => SUCCESS Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> -- You are receiving this mail because: You are watching all bug changes.