Bug 17550 - Display initials in patron search autocomplete
Summary: Display initials in patron search autocomplete
Status: ASSIGNED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Theodoros Theodoropoulos
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-11-04 11:31 UTC by Theodoros Theodoropoulos
Modified: 2023-02-26 12:37 UTC (History)
4 users (show)

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


Attachments
Current functionality (26.70 KB, image/jpeg)
2016-11-04 11:31 UTC, Theodoros Theodoropoulos
Details
Proposed functionality (32.14 KB, image/jpeg)
2016-11-04 11:32 UTC, Theodoros Theodoropoulos
Details
Patch to implement the desired enhancement (1.35 KB, patch)
2016-11-04 12:14 UTC, Theodoros Theodoropoulos
Details | Diff | Splinter Review
Error message on applying the patch (now obsolete, referred to older patch) (8.84 KB, image/png)
2016-11-20 17:27 UTC, Chris Kirby
Details
Patch to implement the desired enhancement (1.98 KB, patch)
2016-11-21 06:19 UTC, Theodoros Theodoropoulos
Details | Diff | Splinter Review
Bug 17550: Display additional patron data in patron suggestion form (2.84 KB, patch)
2016-11-28 04:06 UTC, Chris Kirby
Details | Diff | Splinter Review
Bug 17550: Display additional patron data in patron suggestion form (2.84 KB, patch)
2016-11-28 04:10 UTC, Chris Kirby
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Theodoros Theodoropoulos 2016-11-04 11:31:05 UTC
When in Home › Circulation › Checkouts 
and the librarian wants to select a patron to perform a checkout upon, the suggestions currently display only the following patron data:
Surname, Firstname (CardNumber) Address City Zipcode Country

It would be nice if patron INITIALS were also displayed, like this:
Surname, Firstname INITIALS (CardNumber) Address City Zipcode Country

The reason is that multiple patrons may have the same Surname and Firstname and in order to distinguish them the librarians feel better to ask the patron for their initials rather than asking for the address (btw in our installation we use Father's name in place of initials, but this doesn't alter the use case)

Further more, to better distinguish the various names and to make the Surname and Firstname 'stand out', I suggest converting them to bold, while making the initials italic.

For all these changes the patch (in matter of code lines) is trivial: a few lines in two files. 

You may also find two screenshots of the current and the proposed functionality (the screenshots were taken from a Koha 3.20.x server but the change is applicable to recent versions also and the patch is created using the current master)
Comment 1 Theodoros Theodoropoulos 2016-11-04 11:31:38 UTC
Created attachment 57179 [details]
Current functionality
Comment 2 Theodoros Theodoropoulos 2016-11-04 11:32:03 UTC
Created attachment 57180 [details]
Proposed functionality
Comment 3 Theodoros Theodoropoulos 2016-11-04 12:14:02 UTC
Created attachment 57181 [details] [review]
Patch to implement the desired enhancement
Comment 4 Theodoros Theodoropoulos 2016-11-04 12:21:27 UTC
Steps to reproduce:
1/ In the Koha staff interface, go to Home › Circulation › Checkouts (/cgi-bin/koha/circ/circulation.pl)
2/ Start typing an existing patron (last)name in the "Check Out" textarea
3/ Suggestions are provided without patron Initials being displayed

With the patch applied, when following the above steps, Initials are displayed in italics and Lastname/Firstname are in bold
Comment 5 Chris Kirby 2016-11-20 17:27:45 UTC
Created attachment 57663 [details]
Error message on applying the patch (now obsolete, referred to older patch)

Hi Theodorus,
I get an error on applying this patch (see attached screenshot).
Comment 6 Theodoros Theodoropoulos 2016-11-21 06:19:38 UTC
Created attachment 57672 [details] [review]
Patch to implement the desired enhancement
Comment 7 Theodoros Theodoropoulos 2016-11-21 06:28:30 UTC
@Chris: You're probably right.
I was lazy and created the old patch manually and tested it with 'patch -p1' (which worked).
I now used git bz for the whole process, so it should be OK.
Comment 8 Chris Kirby 2016-11-21 16:09:03 UTC
Hi Theodoros,
I tested and now it seems to work. I am new to this, but it looks like the commit message may need updating per 
https://wiki.koha-community.org/wiki/Commit_messages. 

For example, the bug number description needs reformatting. And your test plan needs to be included.
Comment 9 Chris Kirby 2016-11-28 04:06:35 UTC Comment hidden (obsolete)
Comment 10 Chris Kirby 2016-11-28 04:10:33 UTC
Created attachment 57781 [details] [review]
Bug 17550: Display additional patron data in patron suggestion form

When in Home > Circulation > Checkouts and the librarian wants
to select a patron to perform a checkout upon, the suggestions currently display
only the following patron data:
 Surname, Firstname (CardNumber) Address City Zipcode Country.
It would be useful if patron INITIALS were also displayed, like this:
Surname, Firstname INITIALS (CardNumber) Address City Zipcode Country

To Test:
1) In the staff interface, /cgi-bin/koha/circ/circulation.pl, start typing
   an existing patron (last)name in the "Checkout" textarea.
2) Suggestions are provided, surname and firstname formatted as plain text,
   WITHOUT the patron Initials being displayed.
3) Apply the patch.
4) Repeat step 1.
5) Observe that the suggestions display surname and first name formatted in bold
   and the the Initials displayed in italics.

Signed-off-by: Chris Kirby <chris.kirby@ilsleypubliclibrary.org>
Works as advertised.
Comment 11 Theodoros Theodoropoulos 2016-11-28 07:14:18 UTC
Thanks Kris for your help. I'm also fairly new to this, so all feedback is welcome!


ps1. I was about to write a simple test plan today, but you got me :)
Let's hope it will now get a better chance of passing QA...

ps2. As for my frugal commit message body, I would have gladly put more details, but I thought it would be in vain, as it seems the Koha team uses git as a repo only and Bugzilla for everything else. Having said that, I'll try to be more descriptive next time!
Comment 12 Theodoros Theodoropoulos 2016-11-28 11:59:06 UTC
(Typo fix: Chris, not Kris! Early Monday morning and no coffee=disaster)
Comment 13 Jonathan Druart 2016-12-14 12:25:33 UTC
Theodoros, do you want me to change the name and email address used in the patch?
Comment 14 Jonathan Druart 2016-12-14 12:33:16 UTC
This value is not used anywhere else, why do you want to display it there?
To me it's not consistent to display the initials in only one place, I guess the problem is the same on the other patron search results.
Comment 15 Jonathan Druart 2017-01-02 10:42:47 UTC
(In reply to Jonathan Druart from comment #13)
> Theodoros, do you want me to change the name and email address used in the
> patch?

(In reply to Jonathan Druart from comment #14)
> This value is not used anywhere else, why do you want to display it there?
> To me it's not consistent to display the initials in only one place, I guess
> the problem is the same on the other patron search results.

Waiting for answers.
Comment 16 Theodoros Theodoropoulos 2017-01-02 11:35:10 UTC
> Theodoros, do you want me to change the name and email address used in the
> patch?
Hmmm... What is the common practice? To use the github (ie almost 'dummy') email or the bugzilla one?

> This value is not used anywhere else, why do you want to display it there?
> To me it's not consistent to display the initials in only one place, I guess
> the problem is the same on the other patron search results.
Well, this is the no.1 place where our librarians search manually for patrons to quickly check-out books to (if they don't have their library card with the barcode with them). If they manage to choose the proper patron from this screen (by verifying also the patron Initials -or the Father's name) they avoid unnecessary clicks and possibly-wrong checkouts.
The initials are also displayed in the Patron Details screen, so it's not 'only' there...
That said, indeed it would be better if this "Initials" information was concatenated in the "Name" column of the patron result list, but I suppose this would be a big change in Koha behavior and should(?) be documented... 
If, however, you consider that approach to be more consistent, I'll take a look and see how it could be done.
Comment 17 Katrin Fischer 2023-02-26 12:37:25 UTC
I can confirm that the inititals and other new/old name fields are currently not shown in the autocomplete. They also not show as part of the long name form in the patron account, but only in the labeled field.

I believe we should not just keep adding to the display. Maybe with all the new fields added to the patron form (alias, middle name and soon also preferred name?) we might want to make this configurable?


For the email address. The patches have:
From: sbujam <sbujam@users.noreply.github.com>

The mail address and name will be used to create the release notes and to show your name on the dashboard. We don't ask for a specific email address, but it should be the one you use. Same for the name: it should be the one you want to have displayed.