TPAC: Remove noise, misleading text from myopac/holds/circs/circ_history
authorDan Scott <dscott@laurentian.ca>
Mon, 10 Sep 2012 13:32:17 +0000 (09:32 -0400)
committerLebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Wed, 10 Oct 2012 20:35:55 +0000 (16:35 -0400)
There are many "class='hide_me'" elements that will never be displayed
and which are currently just extra bits to ship over the wire. Same for
the inline comments.

Also move most of the inline styles out to the stylesheet.

Also remove the explicit widths on the table cells; if the font size
changes or the translated text is wider than the table cells, then the
display will become comical.

Also remove explicit <br> tags from localized strings; given the
likelihood that font sizes and column widths will change, <br> tags
inside localized strings make very little sense.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Open-ILS/src/templates/opac/css/style.css.tt2
Open-ILS/src/templates/opac/myopac/circ_history.tt2
Open-ILS/src/templates/opac/myopac/circs.tt2
Open-ILS/src/templates/opac/myopac/holds.tt2
Open-ILS/src/templates/opac/parts/login/password_hint.tt2
Open-ILS/src/templates/opac/parts/place_hold_result.tt2
Open-ILS/web/css/skin/default/opac/semiauto.css

index d988d05..c22b9ce 100644 (file)
@@ -285,6 +285,11 @@ span.dash_divider {
     text-decoration: none;
 }
 
+.checkbox_col {
+    width: 1%;
+    padding-left: 10px !important;
+}
+
 #adv_search.on, #num_search.on, #expert_search.on {
     color: [% css_colors.accent_darker %];
     background: [% css_colors.background %];
@@ -584,6 +589,17 @@ div.format_icon {
     margin:0;
 }
 
+#holds_temp_parent tr td div {
+    margin-top: 10px;
+    margin-bottom: 10px;
+}
+
+#holds_temp_parent tr td div.format_icon {
+    margin-top: 6px;
+    margin-bottom: 6px;
+    float: none;
+}
+
 #results_header_bar {
     background: [% css_colors.accent_medium %];
     border-top:1px solid [% css_colors.accent_mediumdark %];
@@ -804,11 +820,17 @@ table.acct_notes th {
     font-weight:bold;
     text-transform:uppercase;
     font-size: [% css_fonts.size_smaller %];
+    border-collapse: collapse;
 }
 
 #acct_checked_main_header td, #acct_holds_main_header td, #acct_checked_hist_header td, #acct_list_header td, #acct_list_header_anon td, #temp_list_holds td {
     background: [% css_colors.accent_lighter2 %];
-    padding: 8px 0px 7px 0px;
+    padding: 10px;
+}
+
+#acct_checked_main_header th, #acct_holds_main_header th, #acct_checked_hist_header th, #acct_list_header th, #acct_list_header_anon th, #temp_list_holds th {
+    text-align: left;
+    padding: 0px 10px 0px 10px;
 }
 
 #acct_list_header select, #acct_list_header_anon select {
index 4e8c861..9b6d78d 100644 (file)
     <div class="clear-both"></div>
 
     [% IF ctx.circs.size < 1 %]
-    <div class="warning_box">
-        <big><strong>[% l('There are no items in your circulation history.') %]</strong></big>
-    </div>
+    <div class="warning_box">[% l('There are no items in your circulation history.') %]</div>
     [% ELSE %]
 
     <div id='checked_main'>
-        <table style='border-collapse:collapse;'>
-            <thead id="acct_checked_main_header">
+        <table id="acct_checked_main_header">
+            <thead>
                 <tr>
-                    <td width="32%" style="padding-left:5px;">
-                        <span title="Click to sort" class='pointer'>[% l('Title') %]</span> /
-                        <span title="Click to sort" class='pointer'>[% l('Author') %]</span>
-                    </td>
-                    <td width="10%" style="padding-left:5px;">
-                        <span title="Click to sort" class='pointer'>[% l('Checkout Date') %]</span>
-                    </td>
-                    <td width="10%" style="padding-left:5px;">
-                        <span title="Click to sort" class='pointer'>[% l('Due Date') %]</span>
-                    </td>
-                    <td width="10%" style="padding-left:5px;">
-                        <span title="Click to sort" class='pointer'>[% l('Date Returned') %]</span>
-                    </td>
-                    <td width="16%">
-                        <span title="Click to sort" class='pointer'>[% l('Barcode') %]</span>
-                    </td>
-                    <td width="22%">
-                        <span title="Click to sort" class='pointer'>[% l('Call Number') %]</span>
-                    </td>
+                    <th>[% l('Title / Author') %]</th>
+                    <th>[% l('Checkout Date') %]</th>
+                    <th>[% l('Due Date') %]</th>
+                    <th>[% l('Date Returned') %]</th>
+                    <th>[% l('Barcode') %]</th>
+                    <th>[% l('Call Number') %]</th>
                 </tr>
             </thead>
             <tbody>
@@ -74,7 +59,7 @@
                     attrs = {marc_xml => circ.marc_xml};
                     PROCESS get_marc_attrs args=attrs; %]
                     <tr>
-                        <td style="padding-left:5px;padding-bottom:10px;">
+                        <td>
                             <a href="[% mkurl(ctx.opac_root _ '/record/' _ circ.circ.target_copy.call_number.record.id) %]" 
                                 name="[% l('Catalog record') %]">[% attrs.title | html %]</a>
                             [% IF attrs.author %] /
                             )%]">[% attrs.author | html %]</a>
                             [% END %]
                         </td>
-                        <td style="padding-left:5px;">
+                        <td>
                             [% date.format(ctx.parse_datetime(circ.circ.xact_start),DATE_FORMAT); %]
                         </td>
-                        <td style="padding-left:5px;">
+                        <td>
                             [% date.format(ctx.parse_datetime(circ.circ.due_date),DATE_FORMAT); %]
                         </td>
-                        <td style="padding-left:5px;">
+                        <td>
                             [% 
                                 IF circ.circ.checkin_time; 
                                     date.format(ctx.parse_datetime(circ.circ.checkin_time),DATE_FORMAT); 
index bf3ab0e..8ff44ac 100644 (file)
 
     <div class="header_middle">
         <span class="float-left">[% l('Current Items Checked Out') %]</span>
-        <span class="float-right">
-            <a class="hide_me" href="#">[% l('Export List') %]</a>
-        </span>
     </div>
     <div class="clear-both"></div>
     [% IF ctx.circs.size < 1 %]
-    <div class="warning_box">
-        <big><strong>[% l('You have no items checked out.') %]</strong></big>
-    </div>
+    <div class="warning_box">[% l('You have no items checked out.') %]</div>
     [% ELSE %]
     [% IF ctx.success_renewals %]
     <div class="renew-summary">
                         class="opac-button" />
                 </td>
                 <td style="padding-left:5px;">
-                    <a href="#"><img alt="Renewing Help"
+                    <a href="#"><img alt="[% l('Renewing Help') %]"
                         src="[% ctx.media_prefix %]/images/question-mark.png" /></a>
                 </td>
             </tr>
         </table>
-        <table id="acct_checked_main_header" cellpadding='0' cellspacing='0'
-            border='0'>
+        <table id="acct_checked_main_header" cellpadding='0' cellspacing='0' border='0'>
+            <thead>
             <tr>
-                <td width="1%" style="padding-left:10px;">
+                <th class="checkbox_column">
                     <input type="checkbox" id="check_all_checked"
                         onclick="var inputs=document.getElementsByTagName('input'); for (i = 0; i < inputs.length; i++) { if (inputs[i].name == 'circ' && !inputs[i].disabled) inputs[i].checked = this.checked;}"
                     />
-                </td>
-                <td width="40%" style="padding-left:5px;">
-                    <span title="Click to sort" class='pointer'>
-                        Title
-                    </span> /
-                    <span title="Click to sort" class='pointer'>
-                        Author
-                    </span>
-                </td>
-                <td width="8%" style="padding-right:5px;" align="center">
-                    <span title="Click to sort" class='pointer'>Renews<br />Left
-                    </span>
-                </td>
-                <td width="13%" style="padding-left:5px;">
-                    <span title="Click to sort" class='pointer'>Due Date</span>
-                </td>
-                <td width="16%">
-                    <span title="Click to sort" class='pointer'>barcode</span>
-                </td>
-                <td width="22%">
-                    <span title="Click to sort" class='pointer'>call number</span>
-                </td>
+                </th>
+                <th>[% l('Title / Author') %]</th>
+                <th>[% l('Renewals Left') %]</th>
+                <th>[% l('Due Date') %]</th>
+                <th>[% l('Barcode') %]</th>
+                <th>[% l('Call number') %]</th>
             </tr>
-        </table>
-   
-        <div id="checked_temp_parent">
-            <div id="acct_checked_temp">
-                <table cellpadding='0' cellspacing='0' border='0'
-                    style="margin-top:5px;">
+            </thead>
+            <tbody>
                     [% FOR circ IN ctx.circs;
                         attrs = {marc_xml => circ.marc_xml};
                         PROCESS get_marc_attrs args=attrs; %]
                     <tr>
-                        <td width="1%" style="padding-left:10px;" valign="top">
+                        <td class="checkbox_column" valign="top">
                             <input type="checkbox" name="circ"
                                 [% IF circ.circ.renewal_remaining < 1 %] disabled="disabled" [% END %]
                                 value="[% circ.circ.id %]" />
                         </td>
-                        <td width="40%"
-                            style="padding-left:5px;padding-bottom:10px;"
-                            name="author">
+                        <td name="author">
                             <a href="[% mkurl(ctx.opac_root _ '/record/' _ 
                                 circ.circ.target_copy.call_number.record.id) %]"
                                 name="[% l('Catalog record') %]">[% attrs.title | html %]</a>
                             ) %]">[% attrs.author | html %]</a>
                             [% END %]
                         </td>
-                        <td width="8%" name="renewals" align="center">
+                        <td name="renewals" align="center">
                             [% circ.circ.renewal_remaining %]
                         </td>
                         [%
                             due_date = ctx.parse_datetime(circ.circ.due_date);
                             due_class = (date.now > date.format(due_date, '%s')) ? 'error' : '';
                         %]
-                        <td width="13%" style="padding-left:5px;" name="due_date" class='[% due_class %]'>
+                        <td name="due_date" class='[% due_class %]'>
                             [% date.format(due_date, DATE_FORMAT) %]
                         </td>
-                        <td width="16%" name="barcode">
+                        <td name="barcode">
                             [% circ.circ.target_copy.barcode | html %]
                         </td>
-                        <td width="22%" name="call_number">
+                        <td name="call_number">
                             [% circ.circ.target_copy.call_number.label | html %]
                         </td>
                     </tr>
         </form>
     </div>
     [% END %]
-    <div id='non_cat_circs_div' class='hide_me'>
-        <br/>
-        <div style='text-align: center'><b>[% l("Other Circulations") %]</b></div>
-        <table class='data_grid' width='100%'>
-            <thead>
-                <tr>
-                    <td>[% l("Circulating Library") %]</td>
-                    <td>[% l("Circulation Type") %]</td>
-                    <td>[% l("Please return by ...") %]</td>
-                </tr>
-            </thead>
-            <tbody id='non_cat_circs_tbody'>
-                <tr id='non_cat_circs_row'>
-                    <td name='circ_lib'/>
-                    <td name='item_type'/>
-                    <td name='circ_time'/>
-                </tr>
-            </tbody>
-        </table>
-    </div>
 </div>
 [% END %]
index 8321067..5b5a36a 100644 (file)
@@ -47,7 +47,7 @@
         </span>
 
         <span style="float:right;">
-            <a class="hide_me" href="#">Export List</a>
+            <a class="hide_me" href="#">[% l('Export List') %]</a>
         </span>
     </div>
     <div class="clear-both"></div>
                 </td>
                 <td width="1" style="padding-left:5px;">
                     <a href="#"><img
-                        alt="Holds Help"
+                        alt="[% l('Holds Help') %]"
                         src="[% ctx.media_prefix %]/images/question-mark.png" /></a>
                 </td>
                 <td style="padding-left:5px;" class='error'>
                     [%  IF ctx.hold_suspend_post_capture;
-                            l('One or more holds could not be suspended because<br/>the item is at (or en route to) the pickup library.');
+                            l('One or more holds could not be suspended because the item is at (or en route to) the pickup library.');
                         END;
                     %]
                 </td>
                 <td align="right">
-                    [% l("Show") %] &nbsp; &nbsp;
                     [% IF CGI.param("available") %]
-                    <a href="[% mkurl('holds', {},['limit','offset','available']) %]">[% l('all') %]</a> |
-                    <strong>[% l("only available") %]</strong>
+                    <a href="[% mkurl('holds', {}, ['limit','offset','available']) %]">[% l('Show all') %]</a> |
+                    <strong>[% l("Show only available") %]</strong>
                     [% ELSE %]
-                    <strong>[% l("all") %]</strong> |
-                    <a href="[% mkurl('holds', {available => 1}, ['limit','offset']) %]">[% l("only available") %]</a>
+                    <strong>[% l("Show all") %]</strong> |
+                    <a href="[% mkurl('holds',{available => 1},['limit','offset']) %]">[% l("Show only available") %]</a>
                     [% END %] &nbsp; &nbsp;
                     [% l("holds") %]
                     <select class="hide_me" id="holds_sort">
-                        <option value="">-- Sort By --</option>
-                        <option value="title">Title</option>
-                        <option value="pickup">PickUp Location</option>
-                        <option value="status">Status</option>
+                        <option value="">[% l('-- Sort By --') %]</option>
+                        <option value="title">[% l('Title') %]</option>
+                        <option value="pickup">[% l('PickUp Location') %]</option>
+                        <option value="status">[% l('Status') %]</option>
                     </select>
                 </td>
             </tr>
         </table>
         [% IF ctx.holds.size < 1 %]
-        <div class="warning_box">
-            <big><strong>[% l('No holds found.') %]</strong></big>
-        </div>
+        <div class="warning_box">[% l('No holds found.') %]</div>
         [% ELSE %]
-        <table id="acct_holds_main_header" cellpadding='0' cellspacing='0'
-            border='0' width="100%">
+        <div class="hide_me">
+            <select id="hold_pickup_lib_temp" name="hold_pickup_lib_sel" class="hide_me"></select>
+        </div>
+        <table id="acct_holds_main_header" cellpadding='0' cellspacing='0' border='0'>
+            <thead>
             <tr>
-                <td width="36" align="center">
+                <th align="center">
                     <input type="checkbox" onclick="var inputs=document.getElementsByTagName('input'); for (i = 0; i < inputs.length; i++) { if (inputs[i].name == 'hold_id' && !inputs[i].disabled) inputs[i].checked = this.checked;}"/>
-                </td>
-                <td width="138">
-                    <span title="Click to sort"
-                        style="cursor:pointer;">
-                        Title
-                    </span>
-                </td>
-                <td width="123">
-                    <span title="Click to sort" style="cursor:pointer;">Author</span>
-                </td>
-                <td width="64">
-                    <span title="Click to sort"
-                        style="cursor:pointer;">Format</span>
-                </td>
-                <td width="136">
-                    <span title="Click to sort"
-                        style="cursor:pointer;">Pickup Location</span>
-                </td>
-                <td width="104">Activate</td>
-                <td width="106">Cancel if not<br />filled by</td>
-                <td width="95">Active</td>
-                <td width="172">
-                    <span title="Click to sort"
-                        style="cursor:pointer;">Status</span>
-                </td>
+                </th>
+                <th>[% l('Title') %]</th>
+                <th>[% l('Author') %]</th>
+                <th>[% l('Format') %]</th>
+                <th>[% l('Pickup Location') %]</th>
+                <th>[% l('Activate') %]</th>
+                <th>[% l('Cancel if not filled by') %]</th>
+                <th>[% l('Active') %]</th>
+                <th>[% l('Status') %]</th>
             </tr>
-        </table>
-        <div class="hide_me">
-            <select id="hold_pickup_lib_temp" name="hold_pickup_lib_sel"
-                class="hide_me" style="width:125px;height:21px;"></select>
-        </div>
-
-        <table cellpadding='0' cellspacing='0' border='0' width="100%">
+            </thead>
             <tbody id="holds_temp_parent">
                 [% FOR hold IN ctx.holds;
                     attrs = {marc_xml => hold.marc_xml};
                     ahr = hold.hold.hold %]
                 <tr id="acct_holds_temp" name="acct_holds_temp"
                     class="acct_holds_temp[% ahr.frozen == 't' ? ' inactive-hold' : '' %]">
-                    <td width="36" align="center" style="text-align:center;">
+                    <td align="center" style="text-align:center;">
                         <input type="checkbox" name="hold_id" value="[% ahr.id %]" />
                     </td>
-                    <td width="138">
-                        <div style="margin-top:10px;margin-bottom:10px;">
+                    <td>
+                        <div>
                             [% 
                                 title = attrs.title;
                                 IF ahr.hold_type == 'P';
                             <a href="[% mkurl(ctx.opac_root _ '/record/' _ hold.hold.bre_id) %]">[% title | html %]</a>
                         </div>
                     </td>
-                    <td width="123">
-                        <div style="margin-top:10px;margin-bottom:10px;">
+                    <td>
+                        <div>
                             <a href="[% mkurl(ctx.opac_root _ '/results',
                                 {qtype => 'author', query => attrs.author.replace('[,\.:;]', '')}
                             ) %]">[% attrs.author | html %]</a>
                         </div>
                     </td>
-                    <td width="64">
-                        <div style="width:26px;height:23px;margin-top:6px;margin-bottom:6px;">
+                    <td>
+                        <div class="format_icon">
                             [% IF attrs.format_icon %]
                             <img title="[% attrs.format_label | html %]" alt="[% attrs.format_label | html %]" src="[% attrs.format_icon %]" />
                             [% END %]
                         </div>
                     </td>
-                    <td width="136">
+                    <td>
                         [% ctx.get_aou(ahr.pickup_lib).name | html %]
                     </td>
-                    <td width="104">
-                        <!-- <input
-                            title="Enter a date (e.g. 10/21/2010)"
-                            class="hide_me" style="width:91px;"
-                            name="activate_box" type="text" /> -->
-                        [% IF ahr.frozen == 't' AND
-                                ahr.thaw_date;
+                    <td>
+                        [% IF ahr.frozen == 't' AND ahr.thaw_date;
                             date.format(ctx.parse_datetime(ahr.thaw_date), DATE_FORMAT);
                         END %]
                     </td>
-                    <td width="106">
-                        <!-- <input title="[% l('Enter a date (e.g. 10/21/2010)') %]"
-                            class="hide_me" style="width:91px;"
-                            name="hold_expires_box" type="text" />-->
+                    <td>
                         [% IF ahr.expire_time;
                             date.format(ctx.parse_datetime(ahr.expire_time), DATE_FORMAT);
                         END %]
                     </td>
-                    <td width="95">
-                        <!-- <select name="hold_active_sel"
-                            style="width:90px;" class="hide_me">
-                            <option value="f">Active</option>
-                            <option value="t">Suspended</option>
-                        </select> -->
+                    <td>
                         [% l(ahr.frozen == 'f' ? 'Active' : 'Suspended') %]
                     </td>
-                    <td width="110">
-                        <div name="acct_holds_status"
-                            style="margin-top:10px;margin-bottom:10px;">
+                    <td>
+                        <div name="acct_holds_status">
                             [% PROCESS get_hold_status hold=hold; %]
                         </div>
                     </td>
         [% END %]
         </form>
     </div>
-
-    <span id='myopac.holds.cancel.confirm' class='hide_me'>[% l("Are you sure you wish to cancel the selected holds?") %]</span>
-    <span id='myopac.holds.freeze.confirm' class='hide_me'>[% l("Are you sure you wish to suspend the selected holds?  If an item has already been selected to fulfill the hold, it will not be suspended") %]</span>
-    <span id='myopac.holds.thaw.confirm' class='hide_me'>[% l("Are you sure you wish to activate the selected holds?") %]</span>
-    <span id='myopac.holds.thaw_date.confirm' class='hide_me'>[% l("Are you sure you wish to change the activate date for the selected holds?") %]</span>
-    <span id='myopac.holds.freeze.select_thaw' class='hide_me'>[% l("Select an automatic activation date.  If no date is chosen, the holds will remain suspended until they are manually activated.") %]</span>
-
-    <table width='100%' id='myopac_holds_processing' class='hide_me'>
-        <tr><td>[% l("Processing holds... This may take a moment.") %]</td></tr>
-    </table>
-   
-    <span class='hide_me' id='myopac_holds_cancel_verify'>
-       [% l("If you wish to cancel the selected hold, click OK, otherwise click Cancel.") %]
-    </span>
-</div>
-<div id='myopac_holds_thaw_date_form' class='hide_me'>
-    <div id='myopac_holds_freeze_select_thaw'>
-        [% l("Select an automatic activation date.  If no date is chosen, the holds will remain suspended until they are manually activated.") %]
-    </div>
-    <p>
-        <input size='10' maxlength='10'
-            type='text' id='myopac_holds_thaw_date_input' />
-    </p>
-    <p>
-        <button>[% l("Submit") %]</button>
-    </p>
 </div>
 [% END %]
index a95b47f..920ae2e 100644 (file)
@@ -1,5 +1,3 @@
 <span class="lbl2">
-    [% | l('<br/>', '<br/>') %]
-       If this is your first time logging in, please enter [_1] the last 4 digits of your phone number. [_2] Example: 0926
-    [% END %]
+[%- l('If this is your first time logging in, please enter the last 4 digits of your phone number. Example: 0926'); %]
 </span>
index b933d6a..eb05167 100644 (file)
             <br/>
             <hr/>
             <div class='big-strong'>
-                [% |l %]You have permission to override some of the failed holds.<br/>  Click Submit to override and place your hold on the selected items.[% END %]
+                [% |l %]You have permission to override some of the failed holds. Click Submit to override and place your hold on the selected items.[% END %]
             </div>
             <span style='padding-right: 10px;'>
                 <input type="submit" name="submit" value="[% l('Submit') %]"
index cf36106..88f3284 100644 (file)
@@ -5,7 +5,11 @@
 .very-big-height { height: 30px; }
 .big-block { margin: auto; width: 974px; height: 0px; }
 .qtype_selector_margin { margin-right: 7px; }
-.warning_box { margin-top: 10px; }
+.warning_box {
+    margin-top: 10px;
+    font-weight: bold;
+    font-size: larger;
+}
 .pad-bottom-five { padding: 5px; }
 .item_list_padding { padding: 8px 0px 6px 0px; border: 0; }
 .opac-auto-102 { padding-bottom: 7px; }