Currently when displaying an item in the log viewer for 'cataloguing' modifications we display text/link like: Item 972 from Bibliographic record 438 Librarians tend to use the barcode as the unique ID of the record, and we should display this info so they can more easily identify the items.
Created attachment 190621 [details] [review] Bug 41477: Handle deleted items We have a variable 'object_found' - without this we assume the item has been deleted To test: 1 - Delete one of the items you modified, note the itemnumber 2 - Click the 'Modification log' tab - you don't see this item 3 - Search using the itemnumber in 'Object' field 4 - You have empty barcode field and broken links 5 - Apply this patch 6 - Reload 7 - You see the itemnumber and a note that it has been deleted
kohadev-koha@kohadevbox:koha(bug_41477)$ git bz apply 41477 Bug 41477 - Show barcode of item in the action logs 190621 - Bug 41477: Handle deleted items Apply? [(y)es, (n)o, (i)nteractive] y Applying: Bug 41477: Handle deleted items error: sha1 information is lacking or useless (koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt). error: could not build fake ancestor Patch failed at 0001 Bug 41477: Handle deleted items
Created attachment 190667 [details] [review] Bug 41477: Display barcode for items in cataloguing action logs This patch displays the barcode, already passed to the template, when viewing modification logs for items. To test: 1 - Find a biblio 2 - Add or edit some items on the biblio 3 - Edit them again to ensure we have some data 4 - Click 'Modification log' tab on the left in biblio view 5 - See items are displayed only by itemnumber 6 - Apply patch 7 - Reload 8 - Now you see the current barcode for the item 9 - Use itemnumber of one of the items as the 'Object' and search 10 - Verify you still see barcode info
Created attachment 190668 [details] [review] Bug 41477: Handle deleted items We have a variable 'object_found' - without this we assume the item has been deleted To test: 1 - Delete one of the items you modified, note the itemnumber 2 - Click the 'Modification log' tab - you don't see this item 3 - Search using the itemnumber in 'Object' field 4 - You have empty barcode field and broken links 5 - Apply this patch 6 - Reload 7 - You see the itemnumber and a note that it has been deleted
QA unhappy - log below. Space character needed twice, before "<span": line 283: Barcode:<span line 293: Itemnumber:<span kohadev-koha@kohadevbox:koha(bug_41477)$ qa Tag v25.05.00-1 found in /kohadevbox/koha — checking out branch main in /kohadevbox/qa-test-tools Already on 'main' Your branch is up to date with 'origin/main'. testing 2 commit(s) (applied to 7776239 '6c Bug 41432: Prefetch items and borr') Processing files [RUNNING] koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt [error] ID0H0orrxh.tt: SyntaxError: Void elements do not have end tags "br" (2:93) [error] 1 | [error] > 2 | Barcode:<span class="barcode">#~189~#</span></br> [error] | ^^^^^ [error] 3 | <a [error] 4 | href="/cgi-bin/koha/catalogue/moredetail.pl?item=#~190~#&biblionumber=#~191~#&bi=#~192~##item#~193~#" [FAIL] koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt Result: [FAIL] koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt FAIL filters missing_filter at line 293 ( Itemnumber:<span class="itemnumber">[% loopro.object %]</span></br>) FAIL tidiness File is not tidy, please run `perl misc/devel/tidy.pl koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt` Processing additional checks PASS!