From 64bff70cd953408b02b1320efc52161a9b4af507 Mon Sep 17 00:00:00 2001 From: Marc Veron Date: Fri, 10 Aug 2012 06:20:55 +0200 Subject: [PATCH] Bug 8573 - Translation difficult in picture-upload.tt due to nested sentence in if/foreach/if/elsif - construction Text could not be correctly translated due to poor parsing of nested sentences in Pootle. *Sentences de-nested to have whole sentence in each if /elsif branch *Cleaned up
  • handling: moved closing outside the for each loop to prevent orphaned closing s. *Changed indentation for better readibility *Changed WARNING to ERROR because it is an *Error* during upload. *Wording simplified (for translation). *In one case added hint to refer to online help (size). This way text should be easier to be translated in Pootle. Signed-off-by: Julian Maurice Signed-off-by: Chris Cormack (cherry picked from commit c77e60ed79ee89eae989d4c147c68f1294db6bdb) Signed-off-by: Jared Camins-Esakov --- .../prog/en/modules/tools/picture-upload.tt | 33 ++++++++++--------- 1 file changed, 18 insertions(+), 15 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tt index bb59a7da37..91e5a2c030 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tt @@ -43,26 +43,29 @@
  • [% TOTAL %] directorie(s) scanned.
  • [% HANDLED %] directorie(s) processed.
  • + [% FOREACH COUNT IN COUNTS %] -
      +
        [% IF ( COUNT.TCOUNTS ) %]
      • [% COUNT.TCOUNTS %] image(s) moved into the database:
      • [% END %] - [% FOREACH filename IN COUNT.filenames %] -
      • [% filename.source %] - Cardnumber: [% filename.cardnumber %] - [% IF ( filename.filerrors ) %]
        WARNING: This image not imported because + [% FOREACH filename IN COUNT.filenames %] +
      • [% filename.source %] - Cardnumber: [% filename.cardnumber %] + [% IF ( filename.filerrors ) %] [% FOREACH filerror IN filename.filerrors %] - [% IF ( filerror.DBERR ) %]the database returned an error. Please refer to the error log for more details.
      • - [% ELSIF ( filerror.IMGEXISTS ) %]this patron does not exist in the database. - [% ELSIF ( filerror.MIMERR ) %]the image format is unrecognized. - [% ELSIF ( filerror.CORERR ) %]the image file is corrupted. - [% ELSIF ( filerror.OPNERR ) %]Koha was unable to open the image for reading. - [% ELSIF ( filerror.OVRSIZ ) %]the image file is too big. - [% ELSIF ( filerror.CRDFIL ) %]the [% filerror.CRDFIL %] is missing. - [% ELSE %]of an unknown error. Please refer to the error log for more details.[% END %] - [% END %] - [% ELSE %] imported successfully. + [% IF ( filerror.DBERR ) %]
        ERROR: Image not imported because the database returned an error. Please refer to the error log for more details. + [% ELSIF ( filerror.IMGEXISTS ) %]
        ERROR: Image not imported because this patron does not exist in the database. + [% ELSIF ( filerror.MIMERR ) %]
        ERROR: Image not imported because the image format is unrecognized. + [% ELSIF ( filerror.CORERR ) %]
        ERROR: Image not imported because the image file is corrupted. + [% ELSIF ( filerror.OPNERR ) %]
        ERROR: Image not imported because Koha was unable to open the image for reading. + [% ELSIF ( filerror.OVRSIZ ) %]
        ERROR: Image not imported because the image file is too big (see online help for maximum size). + [% ELSIF ( filerror.CRDFIL ) %]
        ERROR: Image not imported ([% filerror.CRDFIL %] missing). + [% ELSE %]
        ERROR: Image not imported because of an unknown error. Please refer to the error log for more details. + [% END %] [% END %] + [% ELSE %] imported successfully. + [% END %] + [% END %] -
      +
    [% END %] -- 2.39.5