Bug 40105

Summary: Patrons cannot add notes when creating an ILL
Product: Koha Reporter: Eric Phetteplace <ephetteplace>
Component: ILLAssignee: Eric Phetteplace <ephetteplace>
Status: Needs Signoff --- QA Contact:
Severity: enhancement    
Priority: P1 - high CC: katrin.fischer, martin.renvoize, pedro.amorim, tomascohen
Version: Main   
Hardware: PC   
OS: Mac OS   
GIT URL: Change sponsored?: Sponsored
Patch complexity: Small patch Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Bug 40105: Patrons cannot add notes when creating an ILL
Bug 40105: Patrons cannot add notes when creating an ILL

Description Eric Phetteplace 2025-06-09 22:02:32 UTC
While there is a notesopac field for ILL requests, it's not shown on the patron-facing form to create an ILL request (/cgi-bin/koha/opac-illrequests.pl?op=add_form&backend=Standard) for any type of resource. Patrons can edit request notes by going to their dashboard > ILL requests > View an existing request > Notes but that is difficult to discover and an extra step for every request. We'd like patrons to be able to add notes to any request during the creation process.

I tried to work around this with OpacUserJS by adding a <textarea> with name="notesopac" but that did not work; the request is created successfully, but Koha discards the note.
Comment 1 Eric Phetteplace 2025-07-22 22:54:07 UTC
Created attachment 184523 [details] [review]
Bug 40105: Patrons cannot add notes when creating an ILL

Testing plan:
- Enable the ILLModule system preference
- Sign into the OPAC and make an ILL request at /cgi-bin/koha/opac-illrequests.pl
- Note there's no option to specify notes
- Apply the patch and restart services
- Make another ILL request
- Use the new notes field
- View the request and note that the notes value was saved
Comment 2 Eric Phetteplace 2025-07-22 22:56:21 UTC
Made a patch for this so it can be tried out but maybe it should have tests? I also asked in mattermost about whether to do the notes as its own distinct fieldset like custom fields (the patch's approach) or as something more incorporated into the other metadata fields but got not responses.
Comment 3 Pedro Amorim 2025-07-23 10:59:56 UTC
Hi Eric, I think this makes sense, but would it be reasonable to have a system preference to enable/disable this? i.e. Koha systems that don't require it wouldn't have a new, possibly redundant (for them), input on the form. Or, alternatively, make it an expandable input that shows upon clicking a always visible 'Want to add some notes to your request?" link.
Adding others for additional thoughts.
Comment 4 Eric Phetteplace 2025-07-23 17:19:43 UTC
Hi Pedro, I don't think a system preference for this makes sense for several reasons. One can always hide the opacnotes input with IntranetUserCSS if it's unwanted. Also, one can use a different ILL backend which provides different fields. There are a wide variety of metadata fields and resource types available in the Standard backend, but there are no analogous system preferences to control them (e.g. to show the DOI field, the conference resource type, etc.). Notes can already be added under the single ILL view, just not at the time of creation, yet there's no existing system preference to control them. A system preference seems like overkill to me and inconsistent with the way the rest of the ILL module has been designed.
Comment 5 Eric Phetteplace 2025-08-12 19:40:04 UTC
Created attachment 185354 [details] [review]
Bug 40105: Patrons cannot add notes when creating an ILL

Testing plan:
- Enable the ILLModule system preference
- Sign into the OPAC and make an ILL request at /cgi-bin/koha/opac-illrequests.pl
- Note there's no option to specify notes
- Apply the patch and restart services
- Make another ILL request
- Use the new notes field
- View the request and note that the notes value was saved

Sponsored-By: California College of the Arts
Comment 6 Eric Phetteplace 2025-08-12 19:41:45 UTC
I have added a test to this, I'm not sure how necessary it is but why not. Changing to needs signoff.