LP1702911: Correct Barcode State in Add Item
[working/Evergreen.git] / Open-ILS / web / js / ui / default / staff / cat / volcopy / app.js
index bbf44a2..fce1e7a 100644 (file)
@@ -1209,7 +1209,10 @@ function($scope , $q , $window , $routeParams , $location , $timeout , egCore ,
                                         ((!$scope.only_vols) ? true : false)
                                     );
 
-                                    if (proto.barcode) cp.barcode( proto.barcode );
+                                    if (proto.barcode) {
+                                        cp.barcode( proto.barcode );
+                                        cp.empty_barcode = false;
+                                    }
 
                                     itemSvc.addCopy(cp)
                                 });
@@ -1256,7 +1259,10 @@ function($scope , $q , $window , $routeParams , $location , $timeout , egCore ,
                                     true
                                 );
 
-                                if (proto.barcode) cp.barcode( proto.barcode );
+                                if (proto.barcode) {
+                                    cp.barcode( proto.barcode );
+                                    cp.empty_barcode = false;
+                                }
 
                                 itemSvc.addCopy(cp)
                             }