From c094c0dfdd19e9e1d68801a2d718e1ccf3060b5b Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Sun, 28 Apr 2019 22:53:55 -0400 Subject: [PATCH] Bug 13420: Sort "Serial enumeration" by published date So far the sorting on volume information is incorrect. It sorts by the string displayed in the cell, which may not have any logics. A better solution would be to use Kyle's suggestion, see comments 7, 8, but it will need much more work. This patch suggests to use the publication date to sort this column. Note: In the code there is a switch depending on the existence of items.publisheddate, but I do not think it is valid, this valid should always exist if the item is received (did I miss something?) Test plan: You need to have different existing subscription, using different numbering. On the detail page of the bibliographic record you should be able to sort the serials (tab "Holdings") by "Serial enumeration". The sort will now use the publication dates. Signed-off-by: Martin Renvoize Signed-off-by: Josef Moravec Signed-off-by: Martin Renvoize Signed-off-by: Joy Nelson (cherry picked from commit d9485314eb86c8c5a466aba57c54680f053c79c3) Signed-off-by: Lucas Gass --- koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt index 83fb19eb33..ccba88543a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt @@ -204,7 +204,7 @@ Home library [% IF ( itemdata_ccode ) %]Collection[% END %] Call number - [% IF ( volinfo ) %]Serial enumeration / chronology[% END %] + [% IF volinfo %]Serial enumeration / chronology[% END %] Status Last seen Date accessioned @@ -247,6 +247,7 @@ [% IF ( item.itemcallnumber ) %] [% item.itemcallnumber | html %][% END %] [% IF ( volinfo ) %] + [% IF ( itemdata_enumchron ) %] [% IF item.enumchron && item.serialseq %] [% item.enumchron | html %] @@ -263,6 +264,7 @@ ([% item.publisheddate | $KohaDates %]) [% END %] [% END %] + [% END %] -- 2.39.5