Bugzilla – Attachment 176923 Details for
Bug 38942
Item template toolbar is not like other toolbars
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 38942: Fix display issues with item-template-toolbar
Bug-38942-Fix-display-issues-with-item-template-to.patch (text/plain), 7.71 KB, created by
PTFS Europe Sandboxes
on 2025-01-22 17:08:48 UTC
(
hide
)
Description:
Bug 38942: Fix display issues with item-template-toolbar
Filename:
MIME Type:
Creator:
PTFS Europe Sandboxes
Created:
2025-01-22 17:08:48 UTC
Size:
7.71 KB
patch
obsolete
>From e3952ec38c83ceee7f37464f006ad2f7ffecaf20 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Tue, 21 Jan 2025 21:27:43 +0000 >Subject: [PATCH] Bug 38942: Fix display issues with item-template-toolbar > >This patch does the following: >-Adds a 'btn' and 'btn-default' class to the buttons in the item-template-toolbar >-Removes the btn-group parent containers >-Changes the wording of the remember session checkbox to 'Remember for session', just like it is on the check out screen for due dates. >-Adds a visual divider after the 'Remember for session' checkbox >-Add CSS to addbiblio.css to make the checkbox/label appear a little nicer > >To test: >-Add an item and 'Save as template' >-Notice the toolbar buttons look different from other toolbars in Koha. >-Apply patch >-Look again, the buttons should look better, hopefully! > >Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> >--- > .../intranet-tmpl/prog/css/addbiblio.css | 10 +++ > .../prog/en/modules/cataloguing/additem.tt | 68 ++++++++----------- > 2 files changed, 40 insertions(+), 38 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/css/addbiblio.css b/koha-tmpl/intranet-tmpl/prog/css/addbiblio.css >index ae89201194..4968aa99b2 100644 >--- a/koha-tmpl/intranet-tmpl/prog/css/addbiblio.css >+++ b/koha-tmpl/intranet-tmpl/prog/css/addbiblio.css >@@ -326,6 +326,16 @@ tbody tr.active td { > width: 15em; > } > >+#item-template-toolbar div:has(label[for="use_template_for_session"]) { >+ display: flex; >+ align-items: center; >+} >+ >+#item-template-toolbar div:has(label[for="use_template_for_session"])::after { >+ content: "|"; >+ padding-left: 7px; >+} >+ > #toolbar { > padding: 5px 0; > } >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/additem.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/additem.tt >index a41569fe99..359c594815 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/additem.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/additem.tt >@@ -214,57 +214,49 @@ > > [% IF item_templates.owned.count || item_templates.shared.count %] > <div id="item-template-toolbar" class="btn-toolbar"> >- <div class="btn-group"> >- <select name="template_id" id="template_id" class="select2" style="width: 20em"> >- <option value="0" selected="selected">Do not use template</option> >- <optgroup label="My templates"> >- [% FOREACH t IN item_templates.owned %] >- [% IF t.id == template_id %] >- <option data-editor="1" value="[% t.id | html %]" selected="selected">[% t.name | html %][% IF t.is_shared %] (shared)[% END %]</option> >+ <select name="template_id" id="template_id" class="select2" style="width: 20em"> >+ <option value="0" selected="selected">Do not use template</option> >+ <optgroup label="My templates"> >+ [% FOREACH t IN item_templates.owned %] >+ [% IF t.id == template_id %] >+ <option data-editor="1" value="[% t.id | html %]" selected="selected">[% t.name | html %][% IF t.is_shared %] (shared)[% END %]</option> >+ [% ELSE %] >+ <option data-editor="1" value="[% t.id | html %]">[% t.name | html %][% IF t.is_shared %] (shared)[% END %]</option> >+ [% END %] >+ [% END %] >+ </optgroup> >+ <optgroup label="Shared templates"> >+ [% FOREACH t IN item_templates.shared %] >+ [% IF t.id == template_id %] >+ [% IF CAN_user_editcatalogue_manage_item_editor_templates %] >+ <option data-editor="1" value="[% t.id | html %]" selected="selected">[% t.name | html %]</option> > [% ELSE %] >- <option data-editor="1" value="[% t.id | html %]">[% t.name | html %][% IF t.is_shared %] (shared)[% END %]</option> >+ <option data-editor="0" value="[% t.id | html %]" selected="selected">[% t.name | html %]</option> > [% END %] >- [% END %] >- </optgroup> >- <optgroup label="Shared templates"> >- [% FOREACH t IN item_templates.shared %] >- [% IF t.id == template_id %] >- [% IF CAN_user_editcatalogue_manage_item_editor_templates %] >- <option data-editor="1" value="[% t.id | html %]" selected="selected">[% t.name | html %]</option> >- [% ELSE %] >- <option data-editor="0" value="[% t.id | html %]" selected="selected">[% t.name | html %]</option> >- [% END %] >+ [% ELSE %] >+ [% IF CAN_user_editcatalogue_manage_item_editor_templates %] >+ <option data-editor="1" value="[% t.id | html %]">[% t.name | html %]</option> > [% ELSE %] >- [% IF CAN_user_editcatalogue_manage_item_editor_templates %] >- <option data-editor="1" value="[% t.id | html %]">[% t.name | html %]</option> >- [% ELSE %] >- <option data-editor="0" value="[% t.id | html %]">[% t.name | html %]</option> >- [% END %] >+ <option data-editor="0" value="[% t.id | html %]">[% t.name | html %]</option> > [% END %] > [% END %] >- </optgroup> >- </select> >- </div> >- <div class="btn-group"> >- <button type="submit" id="load_template_submit" name="load_template_submit" value="1"><i class="fa-solid fa-table-list"></i> Apply template</button> >- </div> >- <div class="btn-group"> >+ [% END %] >+ </optgroup> >+ </select> >+ <button class="btn btn-default" type="submit" id="load_template_submit" name="load_template_submit" value="1"><i class="fa-solid fa-table-list"></i> Apply template</button> >+ <div> > <label for="use_template_for_session"> > [% IF use_template_for_session %] > <input type="checkbox" id="use_template_for_session" name="use_template_for_session" checked="checked"> > [% ELSE %] > <input type="checkbox" id="use_template_for_session" name="use_template_for_session"> > [% END %] >- For session</label> >+ Remember for session >+ </label> > </div> > >- <div class="btn-group"> >- <button type="submit" id="unload_template_submit" name="unload_template_submit" value="1"><i class="fa fa-eraser"></i> Clear template</button> >- </div> >- >- <div class="btn-group"> >- <button type="submit" id="delete_template_submit" name="delete_template_submit" value="1" disabled><i class="fa fa-trash-can"></i> Delete template</button> >- </div> >+ <button class="btn btn-default" ype="submit" id="unload_template_submit" name="unload_template_submit" value="1"><i class="fa fa-eraser"></i> Clear template</button> >+ <button class="btn btn-default" type="submit" id="delete_template_submit" name="delete_template_submit" value="1" disabled><i class="fa fa-trash-can"></i> Delete template</button> > </div> > [% END %] > >-- >2.39.5
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 38942
:
176885
|
176923
|
177748
|
177754