From 1d546c57b1be3677263639ff330061fce33dde34 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Mon, 6 Jun 2016 10:11:36 -0400 Subject: [PATCH] Bug 14752 - (QA followup) Remove annoying modal, use dialog box instead - Uses a dialog box to warn of unique fields not copying, dialog was in place for barcode generation so removed the extar modal completey - Fixes a problem when barcode was undefined and autobarcode on - deleted an extra space in Barcodes/hbymmincr.pm Signed-off-by: sonia BOUIS Signed-off-by: Jonathan Druart Signed-off-by: Kyle M Hall --- C4/Barcodes/hbyymmincr.pm | 2 +- acqui/addorder.pl | 2 +- .../prog/en/includes/additem.js.inc | 1 + .../prog/en/modules/acqui/neworderempty.tt | 16 ---------------- koha-tmpl/intranet-tmpl/prog/js/additem.js | 8 ++++++-- 5 files changed, 9 insertions(+), 20 deletions(-) diff --git a/C4/Barcodes/hbyymmincr.pm b/C4/Barcodes/hbyymmincr.pm index 64f85c4b93..6b41e36098 100644 --- a/C4/Barcodes/hbyymmincr.pm +++ b/C4/Barcodes/hbyymmincr.pm @@ -41,7 +41,7 @@ BEGIN { sub db_max { my $self = shift; my $width = WIDTH; - my $query = "SELECT SUBSTRING(barcode,-$width) AS chunk, barcode FROM items WHERE barcode REGEXP ? ORDER BY chunk DESC LIMIT 1"; + my $query = "SELECT SUBSTRING(barcode,-$width) AS chunk, barcode FROM items WHERE barcode REGEXP ? ORDER BY chunk DESC LIMIT 1"; $debug and print STDERR "(hbyymmincr) db_max query: $query\n"; my $sth = C4::Context->dbh->prepare($query); my ($iso); diff --git a/acqui/addorder.pl b/acqui/addorder.pl index 80f01c68de..5223b7fc04 100755 --- a/acqui/addorder.pl +++ b/acqui/addorder.pl @@ -316,7 +316,7 @@ if ( $basket->{is_standing} || $orderinfo->{quantity} ne '0' ) { 'ITEM'); my $record=MARC::Record::new_from_xml($xml, 'UTF-8'); my ($barcodefield,$barcodesubfield) = GetMarcFromKohaField('items.barcode'); - my $barcode = $record->subfield($barcodefield,$barcodesubfield); + my $barcode = $record->subfield($barcodefield,$barcodesubfield) || ''; my $aBpref = C4::Context->preference('autoBarcode'); if( $barcode eq '' && $aBpref ne 'OFF'){ my $barcodeobj; diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/additem.js.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/additem.js.inc index 1ecee30c40..d7cd4d7630 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/additem.js.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/additem.js.inc @@ -3,6 +3,7 @@ var MSG_ADDITEM_JS_ADDITEM = _("Add item"); var MSG_ADDITEM_JS_ADDMULTI = _("Add multiple items"); var MSG_ADDITEM_JS_MULTIVAL = _("Number of items to add"); +var MSG_ADDITEM_JS_MULTI_UNIQUE_NOTE = _("NOTE: Fields listed in the \'UniqueItemsFields\' system preference will not be copied"); var MSG_ADDITEM_JS_SUBMITMULTI = _("Add"); var MSG_ADDITEM_JS_UPDATEITEM = _("Update item"); var MSG_ADDITEM_JS_EDIT = _("Edit"); diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt index fe659a6193..6497721e55 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt @@ -658,22 +658,6 @@ $(document).ready(function() -[% IF UniqueItemFields %] - -[% END %] -