Bugzilla – Attachment 95738 Details for
Bug 24093
Sorting indicators broken on list contents view
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 24093: Sorting indicators broken on list contents view
Bug-24093-Sorting-indicators-broken-on-list-conten.patch (text/plain), 5.28 KB, created by
Maryse Simard
on 2019-11-22 19:59:45 UTC
(
hide
)
Description:
Bug 24093: Sorting indicators broken on list contents view
Filename:
MIME Type:
Creator:
Maryse Simard
Created:
2019-11-22 19:59:45 UTC
Size:
5.28 KB
patch
obsolete
>From 4acb8bc1be95c7baa6ef7e197aad53875597d737 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Fri, 22 Nov 2019 18:41:28 +0000 >Subject: [PATCH] Bug 24093: Sorting indicators broken on list contents view > >This patch updates the table markup for the lists contents view so that >the table sort state is correctly indicated by arrows in the table >headers. The markup changes allow the standard DataTables CSS to apply >to this table even though it is not a DataTable. > >To test, apply the patch, go to Lists, and view any list with multiple >titles attached. > > - The list should be sorted by default according to the list's > settings, and the arrow in the header row should correctly reflect > the sorting column and direction. > - Test re-sorting the table by each of the different sortable columns, > confirming each time that the sorting arrows are correct. > >Signed-off-by: Maryse Simard <maryse.simard@inlibro.com> >--- > .../prog/en/modules/virtualshelves/shelves.tt | 50 +++++++++++----------- > 1 file changed, 24 insertions(+), 26 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >index 57f5e24..72420dd 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >@@ -159,44 +159,42 @@ > </div> > [% END %] > >- <table id="searchresults"> >+ <table id="searchresults" class="dataTable"> >+ <thead> > <tr> > [% IF ( itemsloop ) %]<th class="checkall"> </th>[% END %] > > [% UNLESS ( item_level_itypes ) %]<th>Item type</th>[% END %] >- <th> >+ [% IF sortfield == 'title' %] >+ <th class="sorting_[% direction | html %]"> >+ [% ELSE %] >+ <th class="sorting"> >+ [% END %] > <a href="/cgi-bin/koha/virtualshelves/shelves.pl?op=view&shelfnumber=[% shelf.shelfnumber | uri %]&sortfield=title&direction=[% IF sortfield != 'title' %]asc[% ELSE %][% new_direction | uri %][% END %]">Title</a> >- [% IF sortfield == 'title' %] >- <img src="[% interface | html %]/[% theme | html %]/img/[% direction | html %].gif" alt="[% direction | html %] sort" /> >- [% ELSE %] >- <img src="[% interface | html %]/[% theme | html %]/img/ascdesc.gif" alt="" /> >- [% END %] > </th> >- <th> >+ [% IF sortfield == 'author' %] >+ <th class="sorting_[% direction | html %]"> >+ [% ELSE %] >+ <th class="sorting"> >+ [% END %] > <a href="/cgi-bin/koha/virtualshelves/shelves.pl?op=view&shelfnumber=[% shelf.shelfnumber | uri %]&sortfield=author&direction=[% IF sortfield != 'author' %]asc[% ELSE %][% new_direction | uri %][% END %]">Author</a> >- [% IF sortfield == 'author' %] >- <img src="[% interface | html %]/[% theme | html %]/img/[% direction | html %].gif" alt="[% direction | html %] sort" /> >- [% ELSE %] >- <img src="[% interface | html %]/[% theme | html %]/img/ascdesc.gif" alt="" /> >- [% END %] >- </th> >- <th> >+ </th> >+ [% IF sortfield == 'dateadded' %] >+ <th class="sorting_[% direction | html %]"> >+ [% ELSE %] >+ <th class="sorting"> >+ [% END %] > <a href="/cgi-bin/koha/virtualshelves/shelves.pl?op=view&shelfnumber=[% shelf.shelfnumber | uri %]&sortfield=dateadded&direction=[% IF sortfield != 'dateadded' %]asc[% ELSE %][% new_direction | uri %][% END %]">Date added</a> >- [% IF sortfield == 'dateadded' %] >- <img src="[% interface | html %]/[% theme | html %]/img/[% direction | html %].gif" alt="[% direction | html %] sort" /> >- [% ELSE %] >- <img src="[% interface | html %]/[% theme | html %]/img/ascdesc.gif" alt="" /> >- [% END %] > </th> >- <th> >+ [% IF sortfield == 'itemcallnumber' %] >+ <th class="sorting_[% direction | html %]"> >+ [% ELSE %] >+ <th class="sorting"> >+ [% END %] > <a href="/cgi-bin/koha/virtualshelves/shelves.pl?op=view&shelfnumber=[% shelf.shelfnumber | uri %]&sortfield=itemcallnumber&direction=[% IF sortfield != 'itemcallnumber' %]asc[% ELSE %][% new_direction | uri %][% END %]">Call number</a> >- [% IF sortfield == 'itemcallnumber' %] >- <img src="[% interface | html %]/[% theme | html %]/img/[% direction | html %].gif" alt="[% direction | html %] sort" /> >- [% ELSE %] >- <img src="[% interface | html %]/[% theme | html %]/img/ascdesc.gif" alt="" /> >- [% END %] > </th> > </tr> >+ </thead> > [% FOREACH itemsloo IN itemsloop %] > <tr> > [% IF itemsloop %] >-- >2.7.4
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 24093
:
95736
|
95738
|
95752