Bugzilla – Attachment 179684 Details for
Bug 39446
ILL request status shows empty in OPAC if status_alias used and lib_opac empty
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 39446: Show both status and status_alias
Bug-39446-Show-both-status-and-statusalias.patch (text/plain), 4.02 KB, created by
Pedro Amorim
on 2025-03-25 13:36:24 UTC
(
hide
)
Description:
Bug 39446: Show both status and status_alias
Filename:
MIME Type:
Creator:
Pedro Amorim
Created:
2025-03-25 13:36:24 UTC
Size:
4.02 KB
patch
obsolete
>From 87c1bbcd9fbaf9580755ab1007aa33fc6d379bb8 Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@ptfs-europe.com> >Date: Tue, 25 Mar 2025 13:27:13 +0000 >Subject: [PATCH] Bug 39446: Show both status and status_alias > >If a request has a status_alias and that status_alias does not have a lib_opac defined, it'll show as an empty status on the OPAC. >Staff UI always shows the request's status and adds the status_alias only if that is defined. The same should happen on the OPAC. > >To test: >1) Enabled ILLModule >2) Create a new ILL request, visit: >http://localhost:8081/cgi-bin/koha/ill/ill-requests.pl?method=create&backend=Standard >3) Add '42' on the cardnumber. Pick any library. Click 'Create'. >4) Add a new 'status_alias' entry, visit the authorized values page: >http://localhost:8081/cgi-bin/koha/admin/authorised_values.pl >5) Search for 'ill_'. Pick 'ILL_STATUS_ALIAS'. Click 'Add a new authorized value'. >6) Enter the 'Authorized value' of 'test', and 'Description' of 'test'. Click 'Save'. >7) Visit the previously created ILL request: >http://localhost:8081/cgi-bin/koha/ill/ill-requests.pl?op=illview&illrequest_id=1 >8) Click 'Edit request' from the top toolbar. >9) On the 'Status' dropdown, pick 'test'. Click 'Submit'. >10) Visit the ILL on the OPAC: >http://localhost:8080/cgi-bin/koha/opac-illrequests.pl >11) Notice the 'status' column is empty. Click the 'View', notice the 'status' entry is empty. >12) Apply patch. Repeat >--- > .../bootstrap/en/modules/opac-illrequests.tt | 12 ++++++++++-- > 1 file changed, 10 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-illrequests.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-illrequests.tt >index b3a5bfad6c1..02cbcfd2ce6 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-illrequests.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-illrequests.tt >@@ -155,7 +155,12 @@ > <td> [% IF request.metadata.Title %][% request.metadata.Title | html %][% ELSE %]<span>N/A</span>[% END %] </td> > <td>[% request.backend | html %]</td> > <td> [% IF type %][% type | html %][% ELSE %]<span>N/A</span>[% END %] </td> >- <td>[% request.status_alias ? request.statusalias.lib_opac : request.capabilities.$status.name | html %]</td> >+ <td> >+ [% request.capabilities.$status.name | html %] >+ [% IF request.status_alias && request.statusalias.lib_opac %] >+ <i><strong>([% request.statusalias.lib_opac | html %])</strong></i> >+ [% END %] >+ </td> > <td data-order="[% request.placed | html %]">[% request.placed | $KohaDates %]</td> > <td data-order="[% request.updated | html %]">[% request.updated | $KohaDates %]</td> > <td> >@@ -195,7 +200,10 @@ > </li> > <li> > <label for="status">Status:</label> >- [% request.status_alias ? request.statusalias.lib_opac : request.capabilities.$status.name | html %] >+ [% request.capabilities.$status.name | html %] >+ [% IF request.status_alias && request.statusalias.lib_opac %] >+ <i><strong>([% request.statusalias.lib_opac | html %])</strong></i> >+ [% END %] > </li> > <li> > <label for="medium">Request type:</label> >-- >2.39.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 39446
:
179684
|
180130