https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=42936 Bug ID: 42936 Summary: Display cardnumber under item status if no name is given Initiative type: --- Sponsorship --- status: Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Patrons Assignee: koha-bugs@lists.koha-community.org Reporter: magnus@libriotech.no QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, kyle@bywatersolutions.com Target Milestone: --- To reproduce: - HidePatronName = Show - Remove "surname" from BorrowerMandatoryField - Add a patron without any name information, but with a cardnumber - Find an item and issue it to the patron without a name - Find the detail page for the record that the issued item belongs to In the "Status" column, it will say something like "Checked out to A patron from Centerville: due 07/04/2026". It should give the cardnumber as a patron identifier, and the cardnumber should have a link to the patron detail page. This might sound a bit far fetched, but we do have a library that wants to store no name information in Koha, and only use the cardnumber to identify patrons. And Koha does allow patrons with no name information, so we should do our best to display useful information in this situation. The library in question says Koha used to show the cardnumber before the upgrade to 25.05, but the code responsible for displaying the patron information has moved around a bit, so I have not been able to pin point when the regression occured. As far as I can tell, the problematic code is this, which is in js-patron-format.inc in 25.05.x and in patron-format.js in main: if (name.replace(" ", "").length == 0) { if (patron.library) { return _("A patron from %s").format(patron.library.name); } else { return _("A patron from another library"); } } It makes the library name or "another library" display if there are no spaces in "name", but the reason there is no spaces in "name" could be that there is no name information to display. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.