From 870a7fa4cb080a7e4eac550694b4a656fc278a83 Mon Sep 17 00:00:00 2001 From: Cesar Velez Date: Fri, 19 Jan 2018 14:43:38 -0500 Subject: [PATCH] LP#1702557-Make Acq MarcEditor Just Have Save Button Like the changes to the z3950 marceditor UI, and serials, make the Acq marceditor have a simple Save button, instead of the Modify + Save Edits buttons needed to save a change. Same change as in 1710405, et al. Note this also fixes a propagation issue that prevented changes from marceditor's scope.marcXml from making it to the modal controller scope, and being saved. Props to miker for helping me debug this! Signed-off by: Cesar Velez Signed-off-by: Kathy Lussier --- Open-ILS/src/templates/staff/acq/t_edit_marc_order_record.tt2 | 4 +--- Open-ILS/web/js/ui/default/staff/acq/app.js | 2 +- Open-ILS/web/js/ui/default/staff/cat/services/marcedit.js | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/Open-ILS/src/templates/staff/acq/t_edit_marc_order_record.tt2 b/Open-ILS/src/templates/staff/acq/t_edit_marc_order_record.tt2 index 1deeb5b314..7fb287e81d 100644 --- a/Open-ILS/src/templates/staff/acq/t_edit_marc_order_record.tt2 +++ b/Open-ILS/src/templates/staff/acq/t_edit_marc_order_record.tt2 @@ -6,11 +6,9 @@ diff --git a/Open-ILS/web/js/ui/default/staff/acq/app.js b/Open-ILS/web/js/ui/default/staff/acq/app.js index e97ea29b91..4be57531ff 100644 --- a/Open-ILS/web/js/ui/default/staff/acq/app.js +++ b/Open-ILS/web/js/ui/default/staff/acq/app.js @@ -80,7 +80,7 @@ function($scope , $routeParams , $location , $window , $timeout , egCore , $uibM $scope.focusMe = true; $scope.args = args; $scope.dirty_flag = false; - $scope.ok = function(args) { $uibModalInstance.close(args) } + $scope.ok = function() { $uibModalInstance.close($scope.args) } $scope.cancel = function () { $uibModalInstance.dismiss() } }] }).result.then(function (args) { diff --git a/Open-ILS/web/js/ui/default/staff/cat/services/marcedit.js b/Open-ILS/web/js/ui/default/staff/cat/services/marcedit.js index 24a08c1619..c4708ea92b 100644 --- a/Open-ILS/web/js/ui/default/staff/cat/services/marcedit.js +++ b/Open-ILS/web/js/ui/default/staff/cat/services/marcedit.js @@ -1368,7 +1368,7 @@ angular.module('egMarcMod', ['egCoreMod', 'ui.bootstrap']) $scope.saveRecord = function () { if ($scope.inPlaceMode) { $scope.marcXml = $scope.record.toXmlString(); - return processOnSaveCallbacks(); + return $timeout(processOnSaveCallbacks); } $scope.mangle_005(); $scope.Record().editor(egCore.auth.user().id()); -- 2.43.2