| 
      
            Lines 2-7
          
      
      
        Link Here
      
     | 
  
        
          | 2 | 
              <title>Koha › Tools › Quote editor</title>  | 
          2 | 
              <title>Koha › Tools › Quote editor</title>  | 
        
        
          | 3 | 
              [% INCLUDE 'doc-head-close.inc' %]  | 
          3 | 
              [% INCLUDE 'doc-head-close.inc' %]  | 
        
        
          | 4 | 
              <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />  | 
          4 | 
              <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />  | 
        
            
               | 
               | 
              5 | 
                  <link rel="stylesheet" type="text/css" href="[% themelang %]/css/quotes.css" />  | 
            
        
          | 5 | 
              <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.dataTables.min.js"></script>  | 
          6 | 
              <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.dataTables.min.js"></script>  | 
        
        
          | 6 | 
              <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/dataTables.fnReloadAjax.js"></script>  | 
          7 | 
              <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/dataTables.fnReloadAjax.js"></script>  | 
        
        
          | 7 | 
              [% INCLUDE 'datatables-strings.inc' %]  | 
          8 | 
              [% INCLUDE 'datatables-strings.inc' %]  | 
        
  
    | 
      
            Lines 39-45
          
      
      
        Link Here
      
     | 
  
        
          | 39 | 
                                  var quoteID = $('td', nRow)[0].innerHTML; | 
          40 | 
                                  var quoteID = $('td', nRow)[0].innerHTML; | 
        
        
          | 40 | 
                                  $(nRow).attr("id", quoteID); /* set row ids to quote id */ | 
          41 | 
                                  $(nRow).attr("id", quoteID); /* set row ids to quote id */ | 
        
        
          | 41 | 
                                  $('td:eq(0)', nRow).click(function() {$(this.parentNode).toggleClass('selected',this.clicked);}); /* add row selectors */ | 
          42 | 
                                  $('td:eq(0)', nRow).click(function() {$(this.parentNode).toggleClass('selected',this.clicked);}); /* add row selectors */ | 
        
          
            
              | 42 | 
                                      $('td:eq(0)', nRow).attr("title", "Click ID to select/deselect quote"); | 
              43 | 
                                      $('td:eq(0)', nRow).attr("title", _("Click ID to select/deselect quote")); | 
            
        
          | 43 | 
                                  if (isNaN(quoteID)) { | 
          44 | 
                                  if (isNaN(quoteID)) { | 
        
        
          | 44 | 
                                      noEditFields = [0,1,2,3]; /* all fields when adding a quote */  | 
          45 | 
                                      noEditFields = [0,1,2,3]; /* all fields when adding a quote */  | 
        
        
          | 45 | 
                                  }  | 
          46 | 
                                  }  | 
        
  
    | 
      
            Lines 101-111
          
      
      
        Link Here
      
     | 
  
        
          | 101 | 
                              });  | 
          102 | 
                              });  | 
        
        
          | 102 | 
                          }  | 
          103 | 
                          }  | 
        
        
          | 103 | 
                          else { | 
          104 | 
                          else { | 
        
          
            
              | 104 | 
                                  alert('Please supply both the text and source of the quote before saving.'); | 
              105 | 
                                  alert(_('Please supply both the text and source of the quote before saving.')); | 
            
        
          | 105 | 
                          }  | 
          106 | 
                          }  | 
        
        
          | 106 | 
                      }  | 
          107 | 
                      }  | 
        
        
          | 107 | 
                      else if (e.keyCode == 27) { | 
          108 | 
                      else if (e.keyCode == 27) { | 
        
          
            
              | 108 | 
                              if (confirm('Are you sure you want to cancel adding this quote?')) { | 
              109 | 
                              if (confirm(_('Are you sure you want to cancel adding this quote?'))) { | 
            
        
          | 109 | 
                              oTable.fnDeleteRow(node);  | 
          110 | 
                              oTable.fnDeleteRow(node);  | 
        
        
          | 110 | 
                          }  | 
          111 | 
                          }  | 
        
        
          | 111 | 
                          else { | 
          112 | 
                          else { | 
        
  
    | 
      
            Lines 134-142
          
      
      
        Link Here
      
     | 
  
        
          | 134 | 
                            return this.id;  | 
          135 | 
                            return this.id;  | 
        
        
          | 135 | 
                      }).get().join(', '); | 
          136 | 
                      }).get().join(', '); | 
        
        
          | 136 | 
                      if (!idsToDelete) { | 
          137 | 
                      if (!idsToDelete) { | 
        
          
            
              | 137 | 
                              alert('Please select a quote(s) by clicking the quote id(s) you desire to delete.'); | 
              138 | 
                              alert(_('Please select a quote(s) by clicking the quote id(s) you desire to delete.')); | 
            
        
          | 138 | 
                      }  | 
          139 | 
                      }  | 
        
          
            
              | 139 | 
                          else if (confirm('Are you sure you wish to delete quote(s) '+idsToDelete+'?')) { | 
              140 | 
                          else if (confirm(_('Are you sure you wish to delete quote(s) ')+idsToDelete+'?')) { | 
            
        
          | 140 | 
                          oTable.$('.selected').each(function(){ | 
          141 | 
                          oTable.$('.selected').each(function(){ | 
        
        
          | 141 | 
                                  var quoteID = $(this).attr('id'); | 
          142 | 
                                  var quoteID = $(this).attr('id'); | 
        
        
          | 142 | 
                                      $.ajax({ | 
          143 | 
                                      $.ajax({ | 
        
  
    | 
      
            Lines 173-182
          
      
      
        Link Here
      
     | 
  
        
          | 173 | 
                      <div class="yui-b">  | 
          174 | 
                      <div class="yui-b">  | 
        
        
          | 174 | 
                          [% INCLUDE 'quotes-toolbar.inc' %]  | 
          175 | 
                          [% INCLUDE 'quotes-toolbar.inc' %]  | 
        
        
          | 175 | 
                          <h2>Quote editor</h2>  | 
          176 | 
                          <h2>Quote editor</h2>  | 
        
          
            
              | 176 | 
                              <table id="quotes_editor" style="float: left; width: 100%;">  | 
              177 | 
                              <div id="instructions">  | 
            
            
               | 
               | 
              178 | 
                              <fieldset id="quote_editor_help" class="rows">  | 
            
            
              | 179 | 
                                  <legend>Instructions</legend>  | 
            
            
              | 180 | 
                                  <div id="quote_editor_inst">  | 
            
            
              | 181 | 
                                      <ul>  | 
            
            
              | 182 | 
                                      <li>Click on the 'Add Quote' button to add a single quote; Press the <Enter> key to save the quote. <b>Note:</b> Both the 'source' and 'text' fields must have content in order for the quote to be saved.</li>  | 
            
            
              | 183 | 
                                      <li>Click on any field to edit the contents; Press the <Enter> key to save edit.</li>  | 
            
            
              | 184 | 
                                      <li>Click on one or more quote numbers to select entire quotes for deletion; Click the 'Delete Quote(s)' button to delete selected quotes.</li>  | 
            
            
              | 185 | 
                                      <li>Click the 'Import Quotes' button in the toolbar to import a CSV file of quotes.</li>  | 
            
            
              | 186 | 
                                      </ul>  | 
            
            
              | 187 | 
                                  </div>  | 
            
            
              | 188 | 
                              </fieldset>  | 
            
            
              | 189 | 
                              </div>  | 
            
            
              | 190 | 
                              <table id="quotes_editor">  | 
            
        
          | 177 | 
                          <thead>  | 
          191 | 
                          <thead>  | 
        
        
          | 178 | 
                              <tr>  | 
          192 | 
                              <tr>  | 
        
          
            
              | 179 | 
                                      <th><span style="cursor: help" onclick="event.stopPropagation();alert('Click on the quote\'s id to select or deselect the quote. Multiple quotes may be selected.');">ID</span></th> | 
              193 | 
                                      <th><span style="cursor: help" onclick="event.stopPropagation();alert(_('Click on the quote\'s id to select or deselect the quote. Multiple quotes may be selected.'));">ID</span></th> | 
            
        
          | 180 | 
                                  <th>Source</th>  | 
          194 | 
                                  <th>Source</th>  | 
        
        
          | 181 | 
                                  <th>Text</th>  | 
          195 | 
                                  <th>Text</th>  | 
        
        
          | 182 | 
                                  <th>Last Displayed</th>  | 
          196 | 
                                  <th>Last Displayed</th>  | 
        
  
    | 
      
            Lines 194-200
          
      
      
        Link Here
      
     | 
  
        
          | 194 | 
                              </tr>  | 
          208 | 
                              </tr>  | 
        
        
          | 195 | 
                          </tbody>  | 
          209 | 
                          </tbody>  | 
        
        
          | 196 | 
                          </table>  | 
          210 | 
                          </table>  | 
        
          
            
              | 197 | 
                              <fieldset id="footer" class="action" style="height:25px;">  | 
              211 | 
                              <fieldset id="footer" class="action">  | 
            
        
          | 198 | 
                          </fieldset>  | 
          212 | 
                          </fieldset>  | 
        
        
          | 199 | 
                      </div>  | 
          213 | 
                      </div>  | 
        
        
          | 200 | 
                  </div>  | 
          214 | 
                  </div>  | 
        
            
              | 201 | 
              -   | 
               | 
               |