webstaff: save copy templates now unconditional
authorGalen Charlton <gmc@esilibrary.com>
Tue, 26 Jan 2016 18:06:14 +0000 (13:06 -0500)
committerKathy Lussier <klussier@masslnc.org>
Tue, 2 Feb 2016 19:58:54 +0000 (14:58 -0500)
The save copy templates button in the volume/copy editor
no longer requires that a working template be active; this
way, users can save the set of templates after an import
without having to select one of them first.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>

Open-ILS/web/js/ui/default/staff/cat/volcopy/app.js

index cfd974a..7b72add 100644 (file)
@@ -1620,6 +1620,10 @@ function($scope , $q , $window , $routeParams , $location , $timeout , egCore ,
                         $scope.$parent.fetchTemplates();
 
                         $scope.dirty = false;
+                    } else {
+                        // save all templates, as we might do after an import
+                        egCore.hatch.setItem('cat.copy.templates', $scope.templates);
+                        $scope.$parent.fetchTemplates();
                     }
                 }