Owen Leonard
a344b8cf8c
This patch makes a number of changes in order to improve the way the staff client's header menu adjusts at narrower browser widths: - Updated version of Bootstrap 3.3.7 which includes the "collapse" JavaScript plugin. - Modified default Bootstrap CSS using Bootstrap's customization tool. These changes facilitate the removal of some custom CSS (overriding Bootstrap) from staff-global.scss. - Added Bootstrap config file for loading customizations at https://getbootstrap.com/docs/3.3/customize/ - Revised button classes for buttons in Bootstrap-styled toolbars. The modified default CSS resets the base font size in Bootstrap to better match our global CSS. A side-effect of this is that toolbar buttons ended up looking smaller than they should. Changing the button class solves this. - Restructure the header menu in order to allow different rules to govern the appearance of the navigational part of the menu (Circulation, Search, etc) and the user menu (Set library, My account, Log out). - Modify the cart JS to so that the popup works well at narrow widths. To test, apply the patch, regenerate the staff client CSS, and clear your browser cache. - Log in to the staff client and observe the layout of the header menu as you adjust the browser to various widths. - Confirm that sections of the menu "collapse" as the window gets narrower. - Confirm that dropdown menus behave correctly and that links work. - Confirm that the Cart link works as expected when the cart empty and when it has items. - Install and enable multiple translations, including at least one set of sub-languages (e.g. fr-FR and fr-CA). - Test the appearance of the language menus in the footer at various browser widths. - View pages with button toolbars and confirm that they appear unchanged (e.g. biblio detail page, patron detail page). NOTE: While this patch is intended to make improvements to staff client responsiveness, it does so within a limited scope. There are still many pages which do not work well at narrower browser widths. Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz> Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
173 lines
6.7 KiB
Text
173 lines
6.7 KiB
Text
[% USE raw %]
|
|
[% USE Asset %]
|
|
[% INCLUDE 'doc-head-open.inc' %]
|
|
<title>Koha › Administration ›
|
|
[% IF ( add_form ) %][% IF ( searchfield ) %] Printers › Modify printer '[% searchfield | html %]'[% ELSE %] Printers › New printer[% END %][% END %]
|
|
[% IF ( add_validate ) %] Printers › Printer added[% END %]
|
|
[% IF ( delete_confirm ) %] Printers › Confirm deletion of printer '[% searchfield | html %]'[% END %]
|
|
[% IF ( delete_confirmed ) %] Printers › Printer deleted[% END %]
|
|
[% IF ( else ) %]Printers[% END %]</title>
|
|
[% INCLUDE 'doc-head-close.inc' %]
|
|
[% IF ( loop ) %]
|
|
[% INCLUDE 'datatables.inc' %]
|
|
<script>
|
|
//<![CDATA[
|
|
$(document).ready(function() {
|
|
$("#printerst").dataTable($.extend(true, {}, dataTablesDefaults, {
|
|
"aoColumnDefs": [
|
|
{ "aTargets": [ -1 ], "bSortable": false, "bSearchable": false },
|
|
],
|
|
"aaSorting": [[ 0, "asc" ]],
|
|
"sPaginationType": "four_button"
|
|
}));
|
|
});
|
|
//]]>
|
|
</script>
|
|
[% END %]
|
|
</head>
|
|
<body id="admin_printers" class="admin">
|
|
[% INCLUDE 'header.inc' %]
|
|
[% INCLUDE 'cat-search.inc' %]
|
|
|
|
<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> › [% IF ( add_form ) %][% IF ( searchfield ) %] <a href="/cgi-bin/koha/admin/printers.pl">Printers</a> › Modify printer '[% searchfield | html %]'[% ELSE %] <a href="/cgi-bin/koha/admin/printers.pl">Printers</a> › New printer[% END %][% END %]
|
|
[% IF ( add_validate ) %] <a href="/cgi-bin/koha/admin/printers.pl">Printers</a> › Printer added[% END %]
|
|
[% IF ( delete_confirm ) %] <a href="/cgi-bin/koha/admin/printers.pl">Printers</a> › Confirm deletion of printer '[% searchfield | html %]'[% END %]
|
|
[% IF ( delete_confirmed ) %] <a href="/cgi-bin/koha/admin/printers.pl">Printers</a> › Printer deleted[% END %]
|
|
[% IF ( else ) %]Printers[% END %]</div>
|
|
|
|
<div class="main container-fluid">
|
|
<div class="row">
|
|
<div class="col-sm-10 col-sm-push-2">
|
|
<main>
|
|
|
|
[% IF ( add_form ) %]
|
|
|
|
[% IF ( searchfield ) %]
|
|
<h1>Modify printer</h1>
|
|
[% ELSE %]
|
|
<h1>New printer</h1>
|
|
[% END %]
|
|
<form action="[% script_name | html %]" name="Aform" method="post" class="validated">
|
|
<input type="hidden" name="op" value="add_validate" />
|
|
[% IF ( searchfield ) %]
|
|
<input type="hidden" name="add" value="0" />
|
|
[% ELSE %]
|
|
<input type="hidden" name="add" value="1" />
|
|
[% END %]
|
|
<fieldset class="rows">
|
|
<ol> [% IF ( searchfield ) %]
|
|
<li>
|
|
<span class="label">Printer name: </span>
|
|
<input type="hidden" name="printername" id="" value="[% searchfield | html %]" />[% searchfield | html %]
|
|
</li>
|
|
[% ELSE %]
|
|
<li>
|
|
<label for="printername" class="required">Printer name: </label>
|
|
<input type="text" name="printername" id="printername" size="40" maxlength="40" class="required" required="required" />
|
|
<span class="required">Required</span>
|
|
</li>
|
|
[% END %]
|
|
<li>
|
|
<label for="printqueue" class="required">Queue: </label>
|
|
<input type="text" name="printqueue" id="printqueue" size="20" maxlength="20" value="[% printqueue | html %]" class="required" required="required" />
|
|
<span class="required">Required</span>
|
|
</li>
|
|
<li>
|
|
<label for="printtype">Type: </label>
|
|
<input type="text" name="printtype" id="printtype" size="20" maxlength="20" value="[% printtype | html %]" />
|
|
</li></ol>
|
|
</fieldset>
|
|
<fieldset class="action"><input type="submit" value="Submit" /> <a class="cancel" href="/cgi-bin/koha/admin/printers.pl">Cancel</a></fieldset>
|
|
</form>
|
|
|
|
[% END %]
|
|
|
|
[% IF ( add_validate ) %]
|
|
<h3>Printer added</h3>
|
|
<form action="[% script_name | html %]" method="post">
|
|
<fieldset class="action"> <input type="submit" value="OK" /></fieldset>
|
|
</form>
|
|
[% END %]
|
|
|
|
[% IF ( delete_confirm ) %]
|
|
<div class="dialog alert">
|
|
<h3>Confirm deletion of printer <em>[% searchfield | html %]</em></h3>
|
|
|
|
<table>
|
|
<tr>
|
|
<th scope="row">Printer: </th><td>[% searchfield | html %]</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">Queue: </th><td>[% printqueue | html %]</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">Type: </th><td>[% printtype | html %]</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<form action="[% script_name | html %]" method="post">
|
|
<input type="hidden" name="op" value="delete_confirmed" />
|
|
<input type="hidden" name="searchfield" value="[% searchfield | html %]" />
|
|
<button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> Yes, delete</button>
|
|
</form>
|
|
<form action="/cgi-bin/koha/admin/printers.pl" method="get">
|
|
<button type="submit" class="deny"><i class="fa fa-fw fa-remove"></i> No, do not delete</button>
|
|
</form>
|
|
</div>
|
|
[% END %]
|
|
|
|
[% IF ( delete_confirmed ) %]
|
|
<div class="dialog message">
|
|
<h3>Printer deleted</h3>
|
|
<form action="[% script_name | html %]" method="post">
|
|
<button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> OK</button>
|
|
</form>
|
|
</div>
|
|
|
|
[% END %]
|
|
|
|
[% IF ( else ) %]
|
|
|
|
<div id="toolbar" class="btn-toolbar">
|
|
<a class="btn btn-default" id="newprinter" href="/cgi-bin/koha/admin/printers.pl?op=add_form"><i class="fa fa-plus"></i> New printer</a>
|
|
</div>
|
|
|
|
<h2>Printers</h2>
|
|
[% IF ( searchfield ) %]
|
|
You searched for [% searchfield | html %]</span>
|
|
[% END %]
|
|
|
|
[% IF ( loop ) %]
|
|
<table id="printerst">
|
|
<thead>
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Queue</th>
|
|
<th>Type</th>
|
|
<th> </th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
[% FOREACH loo IN loop %]
|
|
<tr>
|
|
<td>[% loo.printername | html %]</td>
|
|
<td>[% loo.printqueue | html %]</td>
|
|
<td>[% loo.printtype | html %]</td>
|
|
<td class="actions"><a class="btn btn-default btn-xs" href="[% loo.script_name | url %]?op=add_form&searchfield=[% loo.printername |uri %]"><i class="fa fa-pencil"></i> Edit</a> <a class="btn btn-default btn-xs" href="[% loo.script_name | url %]?op=delete_confirm&searchfield=[% loo.printername |uri %]"><i class="fa fa-trash"></i> Delete</a></td>
|
|
</tr>
|
|
[% END %]
|
|
</tbody>
|
|
</table>[% ELSE %]<div class="dialog message">No printers defined.</div>[% END %]
|
|
[% END %]
|
|
|
|
</main>
|
|
</div> <!-- /.col-sm-10.col-sm-push-2 -->
|
|
|
|
<div class="col-sm-2 col-sm-pull-10">
|
|
<aside>
|
|
[% INCLUDE 'admin-menu.inc' %]
|
|
</aside>
|
|
</div> <!-- /.col-sm-2.col-sm-pull-10 -->
|
|
</div> <!-- /.row -->
|
|
|
|
[% INCLUDE 'intranet-bottom.inc' %]
|