From 5843c76546d5769493099faed2fbce39fbe3b6f3 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marc=20V=C3=A9ron?= Date: Fri, 20 Nov 2015 22:58:40 +0100 Subject: [PATCH] Bug 15231 - Import patrons: Remove string splitting by html tags to avoid weird translations Some of the strings in Home > Tools > Import patrons contain html tags and therefore are splitted in the translation tool. This makes it nearly impossible to create correct translations from the partial strings. Additinally, the notes for Extended patron attributes never displayed (due to a bug). To test: - Apply patch - Enable Syspref 'ExtendedPAtronAttributes' - Go to Home > Tools > Import patrons and verify, that the Notes at the right of the screen make sense Signed-off-by: Hector Castro Split html tags removed, notes at right side it displayed correctly Signed-off-by: Brendan A Gallagher --- .../prog/en/modules/tools/import_borrowers.tt | 36 ++++++++++++------- 1 file changed, 23 insertions(+), 13 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/import_borrowers.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/import_borrowers.tt index f8d9303804..362d222ff3 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/import_borrowers.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/import_borrowers.tt @@ -96,8 +96,8 @@ [% END %] [% ELSE %]
    -
  • Select a file to import into the borrowers table
  • -
  • If a cardnumber exists in the table, you can choose whether to ignore the new one or overwrite the old one.
  • +
  • Select a file to import into the borrowers table.
  • +
  • If a cardnumber exists in the table, you can choose whether to ignore the new one or overwrite the old one.
@@ -193,19 +193,29 @@

Notes:

    -
  • The first line in the file must be a header row defining which columns you are supplying in the import file.
  • -
  • Download a starter CSV file with all the columns here. Values are comma-separated.
  • -
  • OR choose which fields you want to supply from the following list:
    • - [% FOREACH columnkey IN borrower_fields %]'[% columnkey.field %]', [% END %] -
  • -[% IF ( ExtendedPatronAttributes ) %] -
  • 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: INSTID:12345,LANG:fr or STARTDATE:January 1 2010,TRACK:Day. 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: "STARTDATE:January 1, 2010","TRACK:Day". The second syntax would be required if the data might have a comma in it, like a date string. +
  • Header: The first line in the file must be a header row defining which columns you are supplying in the import file.
  • +
  • Separator: Values are comma-separated.
  • +
  • Starter CSV: Koha provides a starter CSV with all the columns. +
  • +
  • Field list: Alternatively, you can create your own CSV and choose which fields you want to supply from the following list: +
    • + [% FOREACH columnkey IN borrower_fields %]'[% columnkey.field %]', [% END %] +
    +
  • +[% IF ( Koha.Preference('ExtendedPatronAttributes') == 1 ) %] +
  • Extended patron attributes: 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. +
    • Example 1: INSTID:12345,LANG:fr
    • Example 2: STARTDATE:January 1 2010,TRACK:Day
    +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: +
    • Example 3: "STARTDATE:January 1, 2010","TRACK:Day"
    +The second syntax would be required if the data might have a comma in it, like a date string.
  • [% END %] -
  • The fields 'branchcode' and 'categorycode' are required and must match valid entries in your database.
  • -
  • 'password' should be stored in plaintext, and will be converted to a Bcrypt hash (if your passwords are already encrypted, talk to your system administrator about options).
  • -
  • Date formats should match your system preference, and must be zero-padded, e.g. '01/02/2008'. Alternatively, -you can supply dates in ISO format (e.g., '2010-10-28'). +
  • Required fields: The fields 'branchcode' and 'categorycode' are required and must match valid entries in your database.
  • +
  • Password: Values for the field 'password' should be stored in plaintext, and will be converted to a Bcrypt hash (if your passwords are already encrypted, talk to your system administrator about options).
  • +
  • Date formats: Date values should match your system preference, and must be zero-padded. +
    • Example: '01/02/2008'
    +Alternatively, you can supply dates in ISO format. +
    • Example: '2010-10-28'
-- 2.39.5