html fix (detected by translator)
[koha.git] / koha-tmpl / opac-tmpl / prog / en / modules / opac-suggestions.tmpl
index e3e7cea..675b309 100644 (file)
@@ -2,6 +2,48 @@
 <!-- TMPL_IF name="op_add" -->Enter a new purchase suggestion<!-- /TMPL_IF -->
 <!-- TMPL_IF name="op_else" -->Purchase Suggestions<!-- /TMPL_IF -->
 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
+<script type="text/javascript" src="<!-- TMPL_VAR name="themelang" -->/lib/jquery/plugins/jquery.checkboxes.pack.js"></script>
+<script type="text/javascript" src="<!-- TMPL_VAR name="themelang" -->/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
+<script type="text/JavaScript" language="JavaScript">
+//<![CDATA[
+$.tablesorter.addParser({
+    id: 'articles', 
+    is: function(s) {return false;  }, 
+    format: function(s) { return s.toLowerCase().replace(/^(the|an|a) /,''); }, 
+    type: 'text' 
+});
+
+       $(function() {
+                       $("#suggestt").tablesorter({
+                               widgets : ['zebra'],
+                               <!-- TMPL_IF NAME="loggedinusername" -->sortList: [[1,0]],<!-- TMPL_ELSE -->sortList: [[0,0]],<!-- /TMPL_IF -->
+                       headers: {
+                               <!-- TMPL_IF NAME="loggedinusername" -->
+                                       <!-- TMPL_IF NAME="OPACViewOthersSuggestions" -->
+                                       0: { sorter: false },2: { sorter: 'articles' },2: {sorter: false },4: {sorter: false},5:{sorter:false}
+                                       <!-- TMPL_ELSE -->
+                                       0: { sorter: false },2: { sorter: 'articles' },2: {sorter: false },3: {sorter: false},4:{sorter:false}
+                                       <!-- /TMPL_IF -->
+                               <!-- TMPL_ELSE -->
+                               <!-- TMPL_IF NAME="OPACViewOthersSuggestions" -->
+                                       0: { sorter: 'articles' },1: {sorter: false },3: {sorter: false},4:{sorter:false}
+                                       <!-- TMPL_ELSE -->
+                                       0: { sorter: 'articles' },1: {sorter: false },2: {sorter: false},3:{sorter:false}
+                                       <!-- /TMPL_IF -->
+                               <!-- /TMPL_IF -->
+                               }
+                       }); 
+                       $("#CheckAll").click(function(){
+                       $(".checkboxed").checkCheckboxes();
+                       return false;
+                   });
+                   $("#CheckNone").click(function(){
+                       $(".checkboxed").unCheckCheckboxes();
+                       return false;
+                   }); 
+       });
+//]]>
+</script>
 </head>
 <body>
 <!-- TMPL_INCLUDE name="masthead.inc" -->
    <div id="bd">
        <div id="yui-main">
        <div class="yui-b"><div class="yui-g">
-
+<div class="container">
 <!-- TMPL_IF name="op_add" -->
     <h1>Enter a new purchase suggestion</h1>
 
-    <p>Fill this form to suggest the library a new acquisition. You will be emailed when the library processes your purchase suggestion</p>
+    <p>Please fill out this form to make a purchase suggestion. You will receive an email when the library processes your purchase suggestion</p>
     <p>No fields are mandatory. Enter whatever information you have. The "Notes" field can be used to provide any additional information.</p>
     <form action="/cgi-bin/koha/opac-suggestions.pl" method="post">
    <fieldset class="rows"> <ol>
-    <li><label for="title">Summary:</label><input type="text" id="title" name="title" size="50" maxlentgh="80" /></li>
+    <li><label for="title">Title:</label><input type="text" id="title" name="title" size="50" maxlentgh="80" /></li>
     <li><label for="author">Author:</label><input type="text" id="author" name="author" size="50" maxlength="80" /></li>
     <li><label for="copyrightdate">Copyright date:</label><input type="text" id="copyrightdate" name="copyrightdate" size="4" maxlength="4" /></li>
     <li><label for="publishercode">Publisher:</label><input type="text" id="publishercode" name="publishercode" size="50" maxlength="80" /></li>
 <!-- /TMPL_IF -->
 
 <!-- TMPL_IF name="op_else" -->
-    <h1>Purchase Suggestions</h1>
+    <h1><!-- TMPL_UNLESS NAME="OPACViewOthersSuggestions" --><!-- TMPL_IF NAME="loggedinusername" -->My <!-- /TMPL_IF --><!-- /TMPL_UNLESS -->Purchase Suggestions</h1>
     <!-- TMPL_IF NAME="suggestions_loop" -->
-            <form action="/cgi-bin/koha/opac-suggestions.pl" method="get">
+    <!-- TMPL_IF NAME="OPACViewOthersSuggestions" -->
+       <form action="/cgi-bin/koha/opac-suggestions.pl" method="get">
     <table>
         <tr>
                 <th>
                     </select>
                 </td>
                 <th>
-                    <input type="submit" value="Set Filter" />
+                    <input type="submit" value="Search" />
                 </th>
         </tr>
                </table>
-            </form>
+            </form><!-- /TMPL_IF -->
         <form action="/cgi-bin/koha/opac-suggestions.pl" method="post">
             <input type="hidden" name="op" value="delete_confirm" />
-                       <table>
-                       <tr>
+                       <div><span class="checkall"><a href="#" id="CheckAll">Select All</a></span>
+               <span class="clearall"><a href="#" id="CheckNone">Clear All</a></span> | <!-- TMPL_IF NAME="loggedinusername" --><a class="new" href="/cgi-bin/koha/opac-suggestions.pl?op=add">New purchase suggestion</a><!-- TMPL_ELSE --><!-- TMPL_IF NAME="AnonSuggestions" --><a class="new" href="/cgi-bin/koha/opac-suggestions.pl?op=add">New purchase suggestion</a><!-- /TMPL_IF --><!-- /TMPL_IF -->
+</div>
+                       <table id="suggestt" class="checkboxed">
+                       <thead><tr>
             <!-- TMPL_IF NAME="loggedinusername" --><th>&nbsp;</th><!-- /TMPL_IF -->
             <th>Summary</th>
             <th>Note</th>
-            <th>Suggested by</th>
+            <!-- TMPL_IF NAME="OPACViewOthersSuggestions" --><th>Suggested by</th><!-- /TMPL_IF -->
             <th>Managed by</th>
             <th>Status</th>
-        </tr>
-        <!-- TMPL_LOOP NAME="suggestions_loop" -->
+        </tr></thead>
+        <tbody><!-- TMPL_LOOP NAME="suggestions_loop" -->
             <!-- TMPL_IF name="even" --><tr><!-- TMPL_ELSE --><tr class="highlight"><!-- /TMPL_IF -->
 <!-- TMPL_IF NAME="loggedinusername" --><td>
                     <input type="checkbox" name="delete_field" value="<!--TMPL_VAR name="suggestionid" -->" />
                 <td>
                     <!-- TMPL_VAR name="note" -->
                 </td>
+                <!-- TMPL_IF NAME="OPACViewOthersSuggestions" --><td>
+                    <!-- TMPL_IF NAME="surnamesuggestedby" -->!-- TMPL_VAR name="surnamesuggestedby" --><!-- TMPL_IF name="firstnamesuggestedby" -->,<!-- /TMPL_IF --> <!-- TMPL_VAR name="firstnamesuggestedby" --><!-- TMPL_ELSE -->&nbsp;<!-- /TMPL_IF -->
+                </td><!-- /TMPL_IF -->
                 <td>
-                    <!-- TMPL_VAR name="surnamesuggestedby" --><!-- TMPL_IF name="firstnamesuggestedby" -->,<!-- /TMPL_IF --> <!-- TMPL_VAR name="firstnamesuggestedby" -->
-                </td>
-                <td>
-                                       <!-- TMPL_VAR name="surnamemanagedby" --><!-- TMPL_IF name="firstnamemanagedby" -->,<!-- /TMPL_IF --> <!-- TMPL_VAR name="firstnamemanagedby" -->
+                                       <!-- TMPL_IF NAME="surnamemanagedby" --><!-- TMPL_VAR name="surnamemanagedby" --><!-- TMPL_IF name="firstnamemanagedby" -->,<!-- /TMPL_IF --> <!-- TMPL_VAR name="firstnamemanagedby" --><!-- TMPL_ELSE -->&nbsp;<!-- /TMPL_IF -->
                 </td>
                 <td>
                     <!-- TMPL_IF name="ASKED" -->Requested<!-- /TMPL_IF -->
                 </td>
             </tr>
         <!-- /TMPL_LOOP -->
-        <!-- TMPL_IF NAME="loggedinusername" --><tr>
-            <td colspan="9">
+       </tbody>
+    </table> <!-- TMPL_IF NAME="loggedinusername" --><fieldset class="action">
                 <input type="submit" value="Delete Checked Items" />
-            </td>
-        </tr><!-- /TMPL_IF -->
-    </table>
+            </fieldset>
+        <!-- /TMPL_IF -->
         </form>
-    <!-- TMPL_ELSE --><p>There are no pending purchase suggestions.</p><!-- /TMPL_IF -->
+    <!-- TMPL_ELSE --><p>There are no pending purchase suggestions.</p> <!-- TMPL_IF NAME="loggedinusername" --><p><a class="new" href="/cgi-bin/koha/opac-suggestions.pl?op=add">New purchase suggestion</a></p><!-- TMPL_ELSE --><!-- TMPL_IF NAME="AnonSuggestions" --><p><a class="new" href="/cgi-bin/koha/opac-suggestions.pl?op=add">New purchase suggestion</a></p><!-- /TMPL_IF --><!-- /TMPL_IF --><!-- /TMPL_IF -->
        
-       <!-- TMPL_IF NAME="loggedinusername" --><a href="/cgi-bin/koha/opac-suggestions.pl?op=add">Add a purchase suggestion</a><!-- TMPL_ELSE --><!-- TMPL_IF NAME="AnonSuggestions" --><a href="/cgi-bin/koha/opac-suggestions.pl?op=add">Add a purchase suggestion</a><!-- /TMPL_IF --><!-- /TMPL_IF -->
 <!-- /TMPL_IF -->
-
+</div>
 </div>
 </div>
 </div>
 <div class="yui-b">
+<div class="container">
 <!--TMPL_INCLUDE NAME="navigation.inc" -->
 <!-- TMPL_INCLUDE name="usermenu.inc" -->
 </div>
 </div>
-<!-- TMPL_INCLUDE NAME="opac-bottom.inc" -->
\ No newline at end of file
+</div>
+<!-- TMPL_INCLUDE NAME="opac-bottom.inc" -->