Bug 10515: make behavior of library category fetchers consistent with other fetchers
[koha_fer] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / transport-cost-matrix.tt
index 8d12419..4ec0710 100644 (file)
@@ -1,5 +1,5 @@
 [% INCLUDE 'doc-head-open.inc' %]
-<title>Koha &rsaquo; Administration &rsaquo; Transport Cost Matrix</title>
+<title>Koha &rsaquo; Administration &rsaquo; Transport cost matrix</title>
 [% INCLUDE 'doc-head-close.inc' %]
 
 <script type="text/javascript">
@@ -38,18 +38,11 @@ function form_submit (f) {
     $(f).find('input:disabled').removeAttr("disabled");
     return true;
 }
-
-$(document).ready(function() {
-    show_transport_cost_matrix([% IF UseTransportCostMatrix %]true[% ELSE %]false[% END %]);
-});
 //]]>
 </script>
 <style type="text/css">
 .disabled-transfer {
-    background-color: red;
-}
-.errors {
-    color: red;
+    background-color: #FF8888;
 }
 </style>
 
@@ -58,7 +51,7 @@ $(document).ready(function() {
 [% INCLUDE 'header.inc' %]
 [% INCLUDE 'cat-search.inc' %]
 
-<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> &rsaquo; Transport Cost Matrix</div>
+<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> &rsaquo; Transport cost matrix</div>
 
 <div id="doc3" class="yui-t1">
 
@@ -69,30 +62,34 @@ $(document).ready(function() {
             Defining transport costs between libraries
     </h1>
 [% IF ( WARNING_transport_cost_matrix_off ) %]
-<div class="dialog message">Because the "UseTransportCostMatrix" system preference is currently not enabled, Transport Cost Matrix is not being used.  Go <a href="/cgi-bin/koha/admin/preferences.pl?op=search&amp;searchfield=UseTransportCostMatrix">here</a> if you wish to enable this feature.</div>
+<div class="dialog message">Because the "UseTransportCostMatrix" system preference is currently not enabled, the transport cost matrix is not being used.  Go <a href="/cgi-bin/koha/admin/preferences.pl?op=search&amp;searchfield=UseTransportCostMatrix">here</a> if you wish to enable this feature.</div>
 [% END %]
 
-    <div class="container">
-        <form method="post" action="?" onSubmit="return form_submit(this);">
+    [% IF ( errors ) %]<div class="dialog alert">
+        <h4>There were problems with your submission</h4>
+        <ul>
+            [% FOR e IN errors %]
+                <li>[% e %]</li>
+            [% END %]
+        </ul>
+    </div>[% END %]
+
+        <form method="post" action="?" onsubmit="return form_submit(this);">
             <input type="hidden" name="op" value="set-cost-matrix" />
-            <div id="transport-cost-matrix">
+            <fieldset id="transport-cost-matrix">
                 <div class="help">
-                    <p>Costs are decimal values 0 to some arbitrarymax value (1 or 100), 0 being minimum (no) cost.</p>
-                    <p>Red cells signify no transfer allowed</p>
-                    <p>Click on the cell to edit</p>
+                    <p>Costs are decimal values between some arbitrary maximum value (e.g. 1 or 100) and 0 which is the minimum (no) cost.</p>
+                    <p>Red cells signify no transfer allowed.</p>
+                    <p>Click on individual cells to edit.</p>
                 </div>
-                <ul class="errors" %]>
-                [% FOR e IN errors %]
-                    <li>[% e %]</li>
-                [% END %]
-                </ul>
+
                 <table>
                     <tr>
                         <th>From \ To</th>
-                [% FOR b IN branchloop %]
+                        [% FOR b IN branchloop %]
                         <th>[% b.name %]</th>
-                [% END %]
-                    <tr>
+                        [% END %]
+                    </tr>
                 [% FOR bf IN branchfromloop %]
                     <tr>
                         <th>[% bf.name %]</th>
@@ -118,12 +115,13 @@ $(document).ready(function() {
                     </tr>
                 [% END %]
                 </table>
-            </div>
-            <input type="submit" value="Save" class="submit" />
+            </fieldset>
+            <fieldset class="action">
+                <input type="submit" value="Save" class="submit" /> <a href="/cgi-bin/koha/admin/transport-cost-matrix.pl" class="cancel">Cancel</a>
+            </fieldset>
         </form>
     </div>
     </div>
-    </div>
 <div class="yui-b">
 [% INCLUDE 'admin-menu.inc' %]
 </div>