From 3b9a816bf183bc333709f1da963cdb3e5f9bb4db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joonas=20Kylm=C3=A4l=C3=A4?= Date: Thu, 17 Sep 2015 11:35:32 +0000 Subject: [PATCH] Bug 14805: (follow-up) fix a bug in previous code and change msg string Previously the code didn't work if there was only one batch available for selection. This fixes that now. Also there was a bug with wrong string showing now it's changed to a general one, "items". I choosed the string "items" because there was difficulties adding the plural part of the word. One cannot add just s to the end of the word batch like you can in the case of profile. Sponsored-by: Vaara-kirjastot --- koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt index ffddcac..71bc6fd 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt @@ -21,7 +21,7 @@ var msg; if (element_ids.length > 1) { - msg = _("Are you sure you want to delete %s batches?").format(element_ids.length); + msg = _("Are you sure you want to delete %s items?").format(element_ids.length, element_ids.length); } else if (element_ids.length == 1) { msg = _("Are you sure you want to delete %s %s?").format("[% PROCESS translate_card_element element=card_element %]", element_ids[0]); } @@ -78,8 +78,8 @@ return GB_showCenter(_("Export patron cards"), "/cgi-bin/koha/patroncards/print.pl?" + getstr, 700, 800); }; function selected_layouts(op) { - var selected = new Array; if (document.layouts.action.length) { + var selected = new Array(); for (i=0;i