[Bug 39610] New: Allow for customizing the metadata shown on OPAC ILL request table
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 Bug ID: 39610 Summary: Allow for customizing the metadata shown on OPAC ILL request table Change sponsored?: --- Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: ILL Assignee: koha-bugs@lists.koha-community.org Reporter: tadeusz@sosnierz.com QA Contact: testopia@bugs.koha-community.org CC: pedro.amorim@openfifth.co.uk, tomascohen@gmail.com The stock ILL table only displays the Author and Title for each request. This is a bit bare-bones even for the Standard backend – for other backends it may be either completely invalid (if they use different fields) or insufficient. It would be useful to have a way to configure the displayed fields. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #1 from HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> --- Created attachment 180825 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=180825&action=edit Bug 39610: Make ILL request metadata fields shown in OPAC table configurable Test plan: 1. In KTD, go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=master+switch and enable the ILL module 2. Run the following script to populate the request list for user `koha`: use strict; use warnings; use Koha::ILL::Request; my $backend = 'Standard'; my $branchcode = 'CPL'; for my $n (1..100) { my $req = Koha::ILL::Request->new->load_backend($backend); my $fields = $req->_backend->_get_core_fields(); my @extended_attributes = map { +{ type => $_, value => "$_ for $n" } } keys %$fields; $req->_backend->create_api({ backend => $backend, branchcode => $branchcode, borrowernumber => 51, type => 'book', extended_attributes => \@extended_attributes, }, $req); } 3. Navigate to http://localhost:8080/cgi-bin/koha/opac-illrequests.pl, log in as `koha` as needed 4. Observe only the default Author and Title being displayed 5. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=ILLOpacMetadataFields and set `author|article_author(Article Author)` as the new value 6. On http://localhost:8080/cgi-bin/koha/opac-illrequests.pl, observe how the configured metadata values are now shown, with configured names Sponsored-by: Wiko (https://www.wiko-berlin.de/) -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #2 from HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> --- The patch above builds on top of https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39600 and applies cleanly on its commit b89287d213f9ac74d6c2bdae34a66c5883fed415 (cleanup). I'm not super-stoked on manipulating dataTables definition with TT, I'd be curious to hear your ideas for alternatives. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 Pedro Amorim <pedro.amorim@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |pedro.amorim@openfifth.co.u |y.org |k Depends on| |39600 Assignee|koha-bugs@lists.koha-commun |tadeusz@sosnierz.com |ity.org | --- Comment #3 from Pedro Amorim <pedro.amorim@openfifth.co.uk> --- Hi Tadeusz, thank you for this work. Please change the bug status to 'Needs Sign-off' if patch ready to be looked at or 'In Discussion' if it's just a PoC that you want feedback on (either status should be fine tbh) Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39600 [Bug 39600] Paginate (and modernize) OPAC ILL requests table -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #4 from Pedro Amorim <pedro.amorim@openfifth.co.uk> --- (In reply to HKS3 Tadeusz Sośnierz from comment #2)
I'm not super-stoked on manipulating dataTables definition with TT, I'd be curious to hear your ideas for alternatives.
I wouldn't worry too much about manipulating dataTables definition with TT, it's an established pattern utilized elsewhere (see patron-search.inc). I like the idea here but we're losing i18n. Previously, the 'Author' and 'Title' - even though hardcoded - were translatable. Now, we're relying on the table column headers to be inserted directly in the syspref within parenthesis, which works, but doesn't look ideal, and certainly not translatable. See bug 38339, it's making the display names of the attributes translatable. Even though that can't be applied here directly (because we don't have an ILL request - to know its backend - when defining the table column headers) I feel like using that in some way could be an option? I'm not sure, but I don't have a better idea at the moment either! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #5 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- We should be ready to move this one forward now :) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #180825|0 |1 is obsolete| | --- Comment #6 from HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> --- Created attachment 181864 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=181864&action=edit Bug 39610: Make ILL request metadata fields shown in OPAC table configurable Test plan: 1. In KTD, go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=master+switch and enable the ILL module 2. Run the following script to populate the request list for user `koha`: use strict; use warnings; use Koha::ILL::Request; my $backend = 'Standard'; my $branchcode = 'CPL'; for my $n (1..100) { my $req = Koha::ILL::Request->new->load_backend($backend); my $fields = $req->_backend->_get_core_fields(); my @extended_attributes = map { +{ type => $_, value => "$_ for $n" } } keys %$fields; $req->_backend->create_api({ backend => $backend, branchcode => $branchcode, borrowernumber => 51, type => 'book', extended_attributes => \@extended_attributes, }, $req); } 3. Navigate to http://localhost:8080/cgi-bin/koha/opac-illrequests.pl, log in as `koha` as needed 4. Observe only the default Author and Title being displayed 5. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=ILLOpacMetadataFields and set `author|article_author(Article Author)` as the new value 6. On http://localhost:8080/cgi-bin/koha/opac-illrequests.pl, observe how the configured metadata values are now shown, with configured names Sponsored-by: Wiko (https://www.wiko-berlin.de/) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #7 from HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> --- Created attachment 181865 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=181865&action=edit Bug 39610: Attempt to translate customized metadata headers -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #8 from HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> --- Rebased on main and added best-effort translations. The extra-configured names will of course not be translated (unless they match some "stock" available translations). I also noticed here that some translations that could be used here are only available in -staff-prog.po, so won't show up here – I'm not sure what the process is for maximizing their availability. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 Roman Dolny <roman.dolny@jezuici.pl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA CC| |roman.dolny@jezuici.pl --- Comment #9 from Roman Dolny <roman.dolny@jezuici.pl> --- It works as described (thank you for test plan with script!) and almost done, but there is no: - adding the appropriate sql to installer/data/mysql/mandatory/sysprefs.sql - atomicupdate which are needded for new system preference ILLOpacMetadataFields. Waiting for attachments. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #181864|0 |1 is obsolete| | --- Comment #10 from HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> --- Created attachment 183153 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=183153&action=edit Bug 39610: Make ILL request metadata fields shown in OPAC table configurable Test plan: 1. In KTD, go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=master+switch and enable the ILL module 2. Run the following script to populate the request list for user `koha`: use strict; use warnings; use Koha::ILL::Request; my $backend = 'Standard'; my $branchcode = 'CPL'; for my $n (1..100) { my $req = Koha::ILL::Request->new->load_backend($backend); my $fields = $req->_backend->_get_core_fields(); my @extended_attributes = map { +{ type => $_, value => "$_ for $n" } } keys %$fields; $req->_backend->create_api({ backend => $backend, branchcode => $branchcode, borrowernumber => 51, type => 'book', extended_attributes => \@extended_attributes, }, $req); } 3. Navigate to http://localhost:8080/cgi-bin/koha/opac-illrequests.pl, log in as `koha` as needed 4. Observe only the default Author and Title being displayed 5. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=ILLOpacMetadataFields and set `author|article_author(Article Author)` as the new value 6. On http://localhost:8080/cgi-bin/koha/opac-illrequests.pl, observe how the configured metadata values are now shown, with configured names Sponsored-by: Wiko (https://www.wiko-berlin.de/) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #181865|0 |1 is obsolete| | --- Comment #11 from HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> --- Created attachment 183154 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=183154&action=edit Bug 39610: Attempt to translate customized metadata headers -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #12 from HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> --- Created attachment 183155 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=183155&action=edit Bug 39610: Add SQL bits for ILLOpacMetadataFields -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 HKS3 Tadeusz Sośnierz <tadeusz@sosnierz.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 Roman Dolny <roman.dolny@jezuici.pl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 Roman Dolny <roman.dolny@jezuici.pl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #183153|0 |1 is obsolete| | Attachment #183154|0 |1 is obsolete| | Attachment #183155|0 |1 is obsolete| | --- Comment #13 from Roman Dolny <roman.dolny@jezuici.pl> --- Created attachment 183310 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=183310&action=edit Bug 39610: Make ILL request metadata fields shown in OPAC table configurable Test plan: 1. In KTD, go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=master+switch and enable the ILL module 2. Run the following script to populate the request list for user `koha`: use strict; use warnings; use Koha::ILL::Request; my $backend = 'Standard'; my $branchcode = 'CPL'; for my $n (1..100) { my $req = Koha::ILL::Request->new->load_backend($backend); my $fields = $req->_backend->_get_core_fields(); my @extended_attributes = map { +{ type => $_, value => "$_ for $n" } } keys %$fields; $req->_backend->create_api({ backend => $backend, branchcode => $branchcode, borrowernumber => 51, type => 'book', extended_attributes => \@extended_attributes, }, $req); } 3. Navigate to http://localhost:8080/cgi-bin/koha/opac-illrequests.pl, log in as `koha` as needed 4. Observe only the default Author and Title being displayed 5. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=ILLOpacMetadataFields and set `author|article_author(Article Author)` as the new value 6. On http://localhost:8080/cgi-bin/koha/opac-illrequests.pl, observe how the configured metadata values are now shown, with configured names Sponsored-by: Wiko (https://www.wiko-berlin.de/) Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #14 from Roman Dolny <roman.dolny@jezuici.pl> --- Created attachment 183311 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=183311&action=edit Bug 39610: Attempt to translate customized metadata headers Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 --- Comment #15 from Roman Dolny <roman.dolny@jezuici.pl> --- Created attachment 183312 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=183312&action=edit Bug 39610: Add SQL bits for ILLOpacMetadataFields Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Patch doesn't apply CC| |lucas@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39610 Bug 39610 depends on bug 39600, which changed state. Bug 39600 Summary: Use the API to render the OPAC ILL requests table https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39600 What |Removed |Added ---------------------------------------------------------------------------- Status|Needs documenting |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org