Bug 20035: Switch single-column templates to Bootstrap grid: Patron clubs
authorOwen Leonard <oleonard@myacpl.org>
Thu, 18 Jan 2018 17:33:00 +0000 (17:33 +0000)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 15 Feb 2018 16:30:23 +0000 (13:30 -0300)
This patch updates two single-column Patron clubs templates to
use the Bootstrap grid.

- clubs/clubs-add-modify.tt - Tools -> Patron clubs -> New club.
- clubs/templates-add-modify.tt - Tools -> Patron clubs -> New club
  template. Also changed in this file: Markup corrections. Label "for"
  attribute should match the form field's id attribute.

Each of these pages should look correct, with a single centered column
with wide margins on either side. At lower browser widths the margins
should disappear.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
koha-tmpl/intranet-tmpl/prog/en/modules/clubs/clubs-add-modify.tt
koha-tmpl/intranet-tmpl/prog/en/modules/clubs/templates-add-modify.tt

index 3d7da82..170a56b 100644 (file)
     [% END %]
 </div>
 
-<div id="doc" class="yui-t7">
-    <div id="bd">
-        <div class="yui-main">
+<div class="main container-fluid">
+    <div class="row">
+        <div class="col-md-8 col-md-offset-2">
+
             <form method="post" class="validated">
                 <input type="hidden" name="id" value="[% club.id %]" />
                 <input type="hidden" name="club_template_id" value="[% club_template.id %]" />
index e90a5dc..efb8cce 100644 (file)
     [% END %]
 </div>
 
-<div id="doc" class="yui-t7">
-    <div id="bd">
-        <div class="yui-main">
+<div class="main container-fluid">
+    <div class="row">
+        <div class="col-md-8 col-md-offset-2">
+
             <form method="post" class="validated">
                 <input type="hidden" name="id" value="[% club_template.id %]" />
 
                         </li>
 
                         <li>
-                            <label for="description">Description:</label>
+                            <label for="club-template-description">Description:</label>
                             <input id="club-template-description" name="description" type="text" value="[% club_template.description %]" />
                         </li>
 
                         <li>
-                            <label for="is_enrollable_from_opac">Allow public enrollment:</label>
+                            <label for="club-template-is-enrollable-from-opac">Allow public enrollment:</label>
                             [% IF club_template.is_enrollable_from_opac %]
                                 <input type="checkbox" id="club-template-is-enrollable-from-opac" name="is_enrollable_from_opac" checked="checked" />
                             [% ELSE %]
@@ -67,7 +68,7 @@
                         </li>
 
                         <li>
-                            <label for="is_email_required">Require valid email address:</label>
+                            <label for="club-template-is-email-required">Require valid email address:</label>
                             [% IF club_template.is_email_required %]
                                 <input type="checkbox" id="club-template-is-email-required" name="is_email_required" checked="checked" />
                             [% ELSE %]
@@ -77,7 +78,7 @@
                         </li>
 
                         <li>
-                            <label for="branchcode">Library:</label>
+                            <label for="club-template-branchcode">Library:</label>
                             <select name="branchcode" id="club-template-branchcode">
                                 <option value=""></option>
                                 [% PROCESS options_for_libraries libraries => Branches.all( selected => club_template.branchcode ) %]
                                     </li>
 
                                     <li>
-                                        <label for="field-description-[% f.id %]">Authorised value category:</label>
+                                        <label for="field-authorised-value-category-[% f.id %]">Authorised value category:</label>
                                         <select name="club_template_field_authorised_value_category" id="field-authorised-value-category-[% f.id %]">
                                             <option value=""></option>
                                             [% PROCESS options_for_authorised_value_categories authorised_value_categories => AuthorisedValues.GetCategories( selected => f.authorised_value_category) %]
                                     </li>
 
                                     <li>
-                                        <label for="enrollment-field-description-[% f.id %]">Authorised value category:</label>
+                                        <label for="enrollment-field-authorised-value-category-[% f.id %]">Authorised value category:</label>
                                         <select name="club_template_enrollment_field_authorised_value_category" id="enrollment-field-authorised-value-category-[% f.id %]">
                                             <option value=""></option>
                                             [% PROCESS options_for_authorised_value_categories authorised_value_categories => AuthorisedValues.GetCategories( selected => f.authorised_value_category) %]
                 </fieldset>
             </form>
 
-        </div> <!-- /#yui-main -->
-    </div> <!-- /#bd -->
+        </div> <!-- /.col-md-8 .col-md-offset-2 -->
+    </div> <!-- /.row -->
 
 
 <div id="new-field-template" class="club-field" style="display:none">
         </li>
     </ol>
     <fieldset class="action"><a href="#" onclick="$(this).parent().parent().remove(); return false;"><i class="fa fa-trash"></i> Delete field</a></fieldset>
-    </div>
 </div>
 
 [% INCLUDE 'intranet-bottom.inc' %]