Altering system log search form to conform with other similar forms; escaping output...
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / tools / import_borrowers.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha &rsaquo; Cataloging &rsaquo; Import Patrons <!-- TMPL_IF NAME="uploadborrowers" -->&rsaquo; Results<!-- /TMPL_IF --></title>
3 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4 <style type="text/css">
5     .yui-u fieldset.rows label.widelabel { width: 12em; }
6     code { background-color: yellow; }
7 </style>
8 </head>
9 <body>
10 <!-- TMPL_INCLUDE NAME="header.inc" -->
11 <!-- TMPL_INCLUDE NAME="patron-search.inc"-->
12
13 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> &rsaquo; <a href="/cgi-bin/koha/tools/import_borrowers.pl">Import Patrons</a><!-- TMPL_IF name="uploadborrowers" --> &rsaquo; Results<!-- /TMPL_IF --></div>
14
15 <div id="doc3" class="yui-t2">
16    
17    <div id="bd">
18         <div id="yui-main">
19         <div class="yui-b">
20 <div class="yui-g">
21 <div class="yui-u first">
22 <h1>Import Patrons</h1>
23 <!-- TMPL_IF name="uploadborrowers" -->
24 <h5>Import results :</h5>
25 <ul>
26         <li><!-- TMPL_VAR name="imported" --> imported records <!-- TMPL_IF name="lastimported" -->(last was <!-- TMPL_VAR name="lastimported" -->)<!-- /TMPL_IF --></li>
27         <li><!-- TMPL_VAR name="overwritten" --> overwritten <!-- TMPL_IF name="lastoverwritten" -->(last was <!-- TMPL_VAR name="lastoverwritten" -->)<!-- /TMPL_IF --></li>
28         <li><!-- TMPL_VAR name="alreadyindb" --> not imported because already in borrowers table and overwrite disabled <!-- TMPL_IF name="lastalreadyindb" -->(last was <!-- TMPL_VAR name="lastalreadyindb" -->)<!-- /TMPL_IF --></li>
29         <li><!-- TMPL_VAR name="invalid" --> not imported because they are not in the expected format <!-- TMPL_IF name="lastinvalid" -->(last was <!-- TMPL_VAR name="lastinvalid" -->)<!-- /TMPL_IF --></li>
30         <li><!-- TMPL_VAR name="total" --> records parsed</li>
31         <li><a href="/cgi-bin/koha/tools/tools-home.pl">Back to Tools</a></li>
32 </ul>
33   <!-- TMPL_IF NAME="ERRORS" -->
34   <br /><br />
35     <div>
36     <h5>Error analysis:</h5>
37     <ul>
38     <!-- TMPL_LOOP NAME="ERRORS" -->
39         <!-- TMPL_IF NAME="badheader" --><li>Header row could not be parsed</li><!-- /TMPL_IF -->
40         <!-- TMPL_LOOP NAME="missing_criticals" -->
41         <li>
42             <!-- TMPL_IF NAME="badparse" -->
43                 Line <span class="linenumber"><!-- TMPL_VAR NAME="line" --></span> could not be parsed!
44             <!-- TMPL_ELSE -->
45                 Critical field &quot;<!-- TMPL_VAR NAME="key" -->&quot; missing on line <span class="linenumber"><!-- TMPL_VAR NAME="line" --></span>
46                 (borrowernumber: <!-- TMPL_VAR NAME="borrowernumber" -->; surname: <!-- TMPL_VAR NAME="surname" -->).
47             <!-- /TMPL_IF -->
48             <br /><code><!-- TMPL_VAR NAME="lineraw" --></code>
49         </li>
50         <!-- /TMPL_LOOP -->
51     <!-- /TMPL_LOOP -->
52     </ul>
53     </div>
54   <!-- /TMPL_IF -->
55 <!-- TMPL_ELSE -->
56 <ul>
57         <li>Select a file to import into the borrowers table</li>
58         <li>If a cardnumber exists in the table, you can choose whether to ignore the new one or overwrite the old one.</li>
59 </ul>
60 <form method="post" action="<!-- TMPL_VAR name="SCRIPT_NAME" -->" enctype="multipart/form-data">
61 <fieldset class="rows">
62 <legend>Import into the borrowers table</legend>
63 <ol>
64         <li>
65                 <label for="uploadborrowers">Select the file to import: </label>
66                 <input type="file" id="uploadborrowers" name="uploadborrowers" />
67         </li>
68 </ol></fieldset>
69     <fieldset class="rows">
70         <legend>Field to use for record matching</legend>
71         <ol>
72             <li class="radio">
73                 <select name="matchpoint" id="matchpoint">
74                     <option value="cardnumber">Cardnumber</option>
75                     <!-- TMPL_LOOP NAME="matchpoints" -->
76                         <option value="<!-- TMPL_VAR NAME="code" -->"><!-- TMPL_VAR NAME="description" --></option>
77                     <!-- /TMPL_LOOP -->
78                 </select>
79             </li>
80         </ol>
81     </fieldset>
82 <fieldset class="rows">
83 <legend>Default values</legend>
84 <ol>
85     <!-- TMPL_LOOP NAME="columnkeys" -->
86         <li>
87                 <label class="widelabel" for="<!-- TMPL_VAR NAME="key" -->"><!-- TMPL_VAR NAME="key" --></label>
88                 <input id="<!-- TMPL_VAR NAME="key" -->" name="<!-- TMPL_VAR NAME="key" -->" />
89         </li>
90     <!-- /TMPL_LOOP -->
91 </ol></fieldset>
92         <fieldset class="rows">
93         <legend>If matching record is already in the borrowers table:</legend><ol><li class="radio">
94                  
95                 <input type="radio" id="overwrite_cardnumberno" name="overwrite_cardnumber" value="0" checked="checked" /><label for="overwrite_cardnumberno">Ignore this one, keep the existing one</label></li>
96 <li class="radio">
97                         <input type="radio" id="overwrite_cardnumberyes" name="overwrite_cardnumber" value="1" /><label for="overwrite_cardnumberyes">Overwrite the existing one with this</label>
98         </li></ol></fieldset>
99         <fieldset class="action"><input type="submit" value="Import" /></fieldset>
100 </form>
101 <!-- /TMPL_IF -->
102 </div>
103 <div class="yui-u">
104 <h2>Notes:</h2>
105 <ul>
106 <li><b>Download a starter CSV file with all the columns <a href="?sample=1">here</a>.</b>  Values are comma-separated.</li>
107 <li>OR format your file in CSV format with the following fields:</li>
108 <ul><li>
109     <!-- TMPL_LOOP name="columnkeys" -->'<!-- TMPL_VAR name="key" -->', <!-- /TMPL_LOOP -->
110 </li></ul>
111 <!-- TMPL_IF NAME="ExtendedPatronAttributes" -->
112 <li>If loading patron attributes, the 'patron_attributes' field should contain a comma-separated list of attribute types 
113 and values.  The attribute type code and a ':' should precede each value. For example: &quot;INSTID:12345,LANG:fr&quot;.  This
114 means that if an input record has more than one attribute, the 'patron_attributes' field must be wrapped in double quotation marks.
115 <li>
116 <!-- /TMPL_IF -->
117 <li>The fields 'branchcode' and 'categorycode' are <b>required</b> and <b>must match</b> valid entries in your database.</li>
118 <li>'password' should be stored in plaintext, and will be converted to a md5 hash (if your passwords are already encrypted, talk to your systems administrator about options).</li>
119 <li>Date formats should match your system preference, and <b>must</b> be zero-padded, e.g. '01/02/2008'.</li>
120 <li>You may optionally include a header row, defining which columns you are supplying in the import file.</li>
121 </ul>
122 </div>
123 </div>
124
125 </div>
126 </div>
127 <div class="yui-b noprint">
128 <!-- TMPL_INCLUDE NAME="tools-menu.inc" -->
129 </div>
130 </div>
131 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->