View | Details | Raw Unified | Return to bug 12929
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/import_borrowers.tt (-1 / +1 lines)
Lines 195-201 Link Here
195
<li>The first line in the file must be a header row defining which columns you are supplying in the import file.</li>
195
<li>The first line in the file must be a header row defining which columns you are supplying in the import file.</li>
196
<li><b>Download a starter CSV file with all the columns <a href="?sample=1">here</a>.</b>  Values are comma-separated.</li>
196
<li><b>Download a starter CSV file with all the columns <a href="?sample=1">here</a>.</b>  Values are comma-separated.</li>
197
<li>OR choose which fields you want to supply from the following list:<ul><li>
197
<li>OR choose which fields you want to supply from the following list:<ul><li>
198
    [% FOREACH columnkey IN columnkeys %]'[% columnkey.key %]', [% END %]
198
    [% FOREACH columnkey IN borrower_fields %]'[% columnkey.field %]', [% END %]
199
</li></ul></li>
199
</li></ul></li>
200
[% IF ( ExtendedPatronAttributes ) %]
200
[% IF ( ExtendedPatronAttributes ) %]
201
<li>If loading patron attributes, the 'patron_attributes' field should contain a comma-separated list of attribute types and values. The attribute type code and a colon should precede each value. For example: <b>INSTID:12345,LANG:fr</b> or <b>STARTDATE:January 1 2010,TRACK:Day</b>. If an input record has more than one attribute, the fields should either be entered as an unquoted string (previous examples), or with each field wrapped in separate double quotes and delimited by a comma: <b>&quot;STARTDATE:January 1, 2010&quot;,&quot;TRACK:Day&quot;</b>.  The second syntax would be required if the data might have a comma in it, like a date string.
201
<li>If loading patron attributes, the 'patron_attributes' field should contain a comma-separated list of attribute types and values. The attribute type code and a colon should precede each value. For example: <b>INSTID:12345,LANG:fr</b> or <b>STARTDATE:January 1 2010,TRACK:Day</b>. If an input record has more than one attribute, the fields should either be entered as an unquoted string (previous examples), or with each field wrapped in separate double quotes and delimited by a comma: <b>&quot;STARTDATE:January 1, 2010&quot;,&quot;TRACK:Day&quot;</b>.  The second syntax would be required if the data might have a comma in it, like a date string.
(-)a/tools/import_borrowers.pl (-3 / +3 lines)
Lines 85-92 $template->param( branches => $branches ) if ( $branches ); Link Here
85
# get the patron categories and pass them to the template
85
# get the patron categories and pass them to the template
86
my $categories = GetBorrowercategoryList();
86
my $categories = GetBorrowercategoryList();
87
$template->param( categories => $categories ) if ( $categories );
87
$template->param( categories => $categories ) if ( $categories );
88
my $columns = C4::Templates::GetColumnDefs( $input );
88
my $columns = C4::Templates::GetColumnDefs( $input )->{borrowers};
89
$template->param( borrower_fields => $columns->{borrowers} );
89
$columns = [ grep { $_->{field} ne 'borrowernumber' ? $_ : () } @$columns ];
90
$template->param( borrower_fields => $columns );
90
91
91
if ($input->param('sample')) {
92
if ($input->param('sample')) {
92
    print $input->header(
93
    print $input->header(
93
- 

Return to bug 12929