Bugzilla – Attachment 162793 Details for
Bug 36237
Improve set-library UI after 34478
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 36237: UI improvments for set-library page
Bug-36237-UI-improvments-for-set-library-page.patch (text/plain), 5.47 KB, created by
Lucas Gass (lukeg)
on 2024-03-05 22:00:09 UTC
(
hide
)
Description:
Bug 36237: UI improvments for set-library page
Filename:
MIME Type:
Creator:
Lucas Gass (lukeg)
Created:
2024-03-05 22:00:09 UTC
Size:
5.47 KB
patch
obsolete
>From 276b04c413e1615201865b08c7c71c8005a54224 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Tue, 5 Mar 2024 21:58:59 +0000 >Subject: [PATCH] Bug 36237: UI improvments for set-library page > >To test: >1. Enable UseCirculationDesks, make some desks via UseCashRegisters > Circulation desks >2. Enable UseCashRegisters, make some registers via UseCashRegisters > Registers >3. Go to set library page. Try changing the branch, desk, or register. >4. See that UI could use some improvements. >5. APPLY patch >6. Try 3 again, making sure everything works right. >--- > circ/set-library.pl | 4 +- > .../prog/en/modules/circ/set-library.tt | 75 ++++++++++--------- > 2 files changed, 41 insertions(+), 38 deletions(-) > >diff --git a/circ/set-library.pl b/circ/set-library.pl >index 7929a2701b..55961ed949 100755 >--- a/circ/set-library.pl >+++ b/circ/set-library.pl >@@ -64,8 +64,8 @@ if ( > $session->param('branch', $branch); # update sesssion in DB > push @updated, { > updated_branch => 1, >- old_branch => $userenv_branch, >- new_branch => $branch, >+ old_branch => Koha::Libraries->find( $userenv_branch )->branchname, >+ new_branch => Koha::Libraries->find( $branch )->branchname, > }; > } # else branch the same, no update > if ( $desk_id && (!$userenv_desk or $userenv_desk ne $desk_id) ) { >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/set-library.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/set-library.tt >index 5834f2cfa5..cf00328196 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/set-library.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/set-library.tt >@@ -52,42 +52,45 @@ > <h1>Set library</h1> > > [% IF ( updated ) %] >- >-<h2>Update succeeded</h2> >-Updated:<ul> >- [% FOREACH update IN updated %] >- [% IF ( update.updated_branch || update.updated_desk || update.updated_register ) %] >- [% IF ( update.updated_branch ) %] >- <li>Library: [% update.old_branch or "?" | html %] ⇒ [% update.new_branch or "?" | html %]</li> >- [% END %] >- [% IF ( update.updated_desk ) %] >- <li>Desk: [% update.old_desk or "?" | html %] ⇒ [% LoginDeskname or "?" | html %]</li> >- [% END %] >- [% IF ( updated.updated_register ) %] >- <li>Register: [% updated.old_register or "?" | html %] ⇒ [% Registers.session_register_name or "?" | html %]</li> >- [% END %] >- [% ELSE %] >- <li>ERROR - unknown</li> >- [% END %] >- [% END %] >- </ul> >-<form method="post" action="[% referer or "/cgi-bin/koha/circ/circulation.pl" %]"> >- [% INCLUDE 'csrf-token.inc' %] >- <div class="noshow"> >- [% FOREACH recycle_loo IN recycle_loop %] >- [% SET param = recycle_loo.param %] >- [% NEXT IF param == 'op' %] >- [% NEXT IF param == 'csrf_token' %] >- [% IF param == 'original_op' %][% param = 'op' %][% END %] >- <input type="text" name="[% param | html %]" value="[% recycle_loo.value | html %]" /> >- [% IF param == 'op' %][% SET has_op = 1 %][% END %] >- [% END %] >- [% UNLESS has_op %] >- <input type="hidden" name="op" value="cud-no-op" /> [%# Trick to pass anti-CSRF requirements %] >- [% END %] >- </div> >- <button type="submit">Continue</button> >-</form> >+ <fieldset class="rows"> >+ <legend>Update succeeded</legend> >+ <ul> >+ [% FOREACH update IN updated %] >+ [% IF ( update.updated_branch || update.updated_desk || update.updated_register ) %] >+ [% IF ( update.updated_branch ) %] >+ <li>Library updated from <strong>[% update.old_branch or "?" | html %]</strong> to <strong>[% update.new_branch or "?" | html %]</strong>.</li> >+ [% END %] >+ [% IF ( update.updated_desk ) %] >+ <li>Desk updated from <strong>[% update.old_desk or "?" | html %]</strong> to <strong>[% LoginDeskname or "?" | html %]</strong>.</li> >+ [% END %] >+ [% IF ( update.updated_register ) %] >+ <li>Register updated from <strong>[% update.old_register or "?" | html %]</strong> to <strong>[% Registers.session_register_name or "?" | html %]</strong>.</li> >+ [% END %] >+ [% ELSE %] >+ <li>ERROR - unknown</li> >+ [% END %] >+ [% END %] >+ </ul> >+ </fieldset> >+ <form method="post" action="[% referer or "/cgi-bin/koha/circ/circulation.pl" %]"> >+ [% INCLUDE 'csrf-token.inc' %] >+ <div class="noshow"> >+ [% FOREACH recycle_loo IN recycle_loop %] >+ [% SET param = recycle_loo.param %] >+ [% NEXT IF param == 'op' %] >+ [% NEXT IF param == 'csrf_token' %] >+ [% IF param == 'original_op' %][% param = 'op' %][% END %] >+ <input type="text" name="[% param | html %]" value="[% recycle_loo.value | html %]" /> >+ [% IF param == 'op' %][% SET has_op = 1 %][% END %] >+ [% END %] >+ [% UNLESS has_op %] >+ <input type="hidden" name="op" value="cud-no-op" /> [%# Trick to pass anti-CSRF requirements %] >+ [% END %] >+ </div> >+ <fieldset class="action"> >+ <button class="btn btn-primary" type="submit">Continue</button> >+ </fieldset> >+ </form> > > [% ELSE %] > >-- >2.30.2
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 36237
:
162793
|
163013