From 831b69e6e3b558fe430a11e8462f7296d258198b Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Mon, 13 Jan 2025 12:59:36 +0000 Subject: [PATCH] Bug 38870: Remove overflow scroll from batch patron modification This patch removes the
surrounding batch patron modification results with the style "overflow:auto". Also removed is the DataTable option "scrollX". This eliminates the horizontal scrolling for the table itself, and causes the whole page to scroll horizontally instead. This is consistent with other pages in Koha. This fix lets us avoid bugs which are associated with the overflow scrolling and our DataTables implementation. (see Bug 37730). To test, apply the patch and go to Tools -> Batch patron modification - Submit a batch of patrons for modification. - On the screen showing the patrons which will be modified, the page will probably have a horizontal scrollbar already. If not, resize your browser to confirm that the whole page scrolls, not just the table. - Confirm that the table header "sticks" to the top of the screen when you scroll down, and that the header continues to be aligned correctly when you scroll horizontally. Sponsored-by: Athens County Public Libraries --- .../prog/en/modules/tools/modborrowers.tt | 207 +++++++++--------- 1 file changed, 102 insertions(+), 105 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt index 476f98b2e4..ed7cd00492 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt @@ -231,124 +231,122 @@ [% END %] [% IF borrowers %]
-
- - +
+ + + [% IF ( op == 'show' ) %] + + [% ELSE %] + + [% END %] + + + + + + + + + + + + + + + + + + + [% IF CanUpdatePasswordExpiration %] + + [% END %] + [% IF CanUpdateProtectPatron %] + + [% END %] + + + + + + [% FOREACH attrh IN attributes_header %] + + [% END %] + + + + [% FOREACH borrower IN borrowers %] [% IF ( op == 'show' ) %] - + + - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + [% IF CanUpdatePasswordExpiration %] - + [% IF borrower.password_expiration_date %] + + [% ELSE %] + + [% END %] [% END %] [% IF CanUpdateProtectPatron %] - - [% END %] - - - - - - [% FOREACH attrh IN attributes_header %] - - [% END %] - - - - [% FOREACH borrower IN borrowers %] - - [% IF ( op == 'show' ) %] - - - - - - - - - - - - - - - - - - - - [% IF CanUpdatePasswordExpiration %] - [% IF borrower.password_expiration_date %] - - [% ELSE %] - - [% END %] - [% END %] - [% IF CanUpdateProtectPatron %] - + + +

[% END %] - - - - - - [% FOREACH pa IN borrower.patron_attributes %] - [% IF ( pa.code ) %] - [%# Replace pa.attribute with pa.description if we prefer to display the description %] - - [% ELSE %] - - [% END %] + + + + [% FOREACH pa IN borrower.patron_attributes %] + [% IF ( pa.code ) %] + [%# Replace pa.attribute with pa.description if we prefer to display the description %] + + [% ELSE %] + [% END %] - - [% END %] - -
  Card numberSurnameFirst nameLibraryPatron categoryStreet numberAddressAddress 2CityStateZIP/Postal codeCountryPrimary emailPrimary phoneOther phoneFaxRegistration dateExpiry datePassword expiration dateProtectedCirculation noteOPAC noteMessageRestriction expirationRestriction comment[% attrh.attribute | html %]
  [% ELSE %] -   [% END %] - Card numberSurnameFirst nameLibraryPatron categoryStreet numberAddressAddress 2CityStateZIP/Postal codeCountryPrimary emailPrimary phoneOther phoneFaxRegistration dateExpiry date[% borrower.cardnumber | html %][% borrower.surname | html %][% borrower.firstname | html %][% Branches.GetName( borrower.branchcode ) | html %][% Categories.GetName(borrower.categorycode) | html %][% borrower.streetnumber | html %][% borrower.address | html %][% borrower.address2 | html %][% borrower.city | html %][% borrower.state | html %][% borrower.zipcode | html %][% borrower.country | html %][% borrower.email | html %][% borrower.phone | html %][% borrower.mobile | html %][% borrower.fax | html %][% borrower.dateenrolled | $KohaDates %][% borrower.dateexpiry | $KohaDates %]Password expiration date + [% borrower.password_expiration_date | $KohaDates %] + NeverProtectedCirculation noteOPAC noteMessageRestriction expirationRestriction comment[% attrh.attribute | html %]
+ + [% IF borrower.protected %] + Yes [% ELSE %] - + No [% END %] - [% borrower.cardnumber | html %][% borrower.surname | html %][% borrower.firstname | html %][% Branches.GetName( borrower.branchcode ) | html %][% Categories.GetName(borrower.categorycode) | html %][% borrower.streetnumber | html %][% borrower.address | html %][% borrower.address2 | html %][% borrower.city | html %][% borrower.state | html %][% borrower.zipcode | html %][% borrower.country | html %][% borrower.email | html %][% borrower.phone | html %][% borrower.mobile | html %][% borrower.fax | html %][% borrower.dateenrolled | $KohaDates %][% borrower.dateexpiry | $KohaDates %] - [% borrower.password_expiration_date | $KohaDates %] - Never - [% IF borrower.protected %] - Yes + [% END %] + [% borrower.borrowernotes | $raw | html_line_break %][% borrower.opacnote | html %] + [% FOREACH patron_message IN borrower.patron_messages %] + [% patron_message.message | html %]
+ + [% IF (patron_message.message_type == 'B') %] + ( OPAC ) [% ELSE %] - No + ( Staff ) [% END %] -
[% borrower.borrowernotes | $raw | html_line_break %][% borrower.opacnote | html %] - [% FOREACH patron_message IN borrower.patron_messages %] - [% patron_message.message | html %]
- - [% IF (patron_message.message_type == 'B') %] - ( OPAC ) - [% ELSE %] - ( Staff ) - [% END %] -

- [% END %] -
[% borrower.debarred | $KohaDates %][% borrower.debarredcomment | html %][% pa.code | html %]=[% pa.attribute | html %][% borrower.debarred | $KohaDates %][% borrower.debarredcomment | html %][% pa.code | html %]=[% pa.attribute | html %]
-
+ [% END %] + + [% END %] + +
[% IF ( op == 'show' ) %] @@ -507,7 +505,6 @@ let patron_table = KohaTable("borrowerst", { "order": [[ 1, "asc" ]], "autoWidth": true, - "scrollX": true, }, table_settings); $("#selectallbutton").click(function() { -- 2.39.5