From 004974d43a038046cb3569fa9e506722faa9cd43 Mon Sep 17 00:00:00 2001 From: Bill Erickson Date: Wed, 5 Jun 2013 17:29:36 -0400 Subject: [PATCH] LP1187016 Prevent new copies on activated POs If a PO has already been activated, prevent users from adding new copies in the Item Count entry under the full lineitem copy grid. Signed-off-by: Bill Erickson Signed-off-by: Kathy Lussier Signed-off-by: Ben Shum --- Open-ILS/web/js/ui/default/acq/common/li_table.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Open-ILS/web/js/ui/default/acq/common/li_table.js b/Open-ILS/web/js/ui/default/acq/common/li_table.js index f007bf6b8b..16665c4d7d 100644 --- a/Open-ILS/web/js/ui/default/acq/common/li_table.js +++ b/Open-ILS/web/js/ui/default/acq/common/li_table.js @@ -1734,6 +1734,12 @@ function AcqLiTable() { acqLitBatchUpdateCopies.onClick = function() { self.batchCopyUpdate() }; acqLitCopyCountInput.attr('value', '0'); + if (this.isPO && PO && PO.order_date()) { + // prevent adding copies to activated POs + acqLitCopyCountInput.attr('disabled', true); + acqLitAddCopyCount.attr('disabled', true); + } + while(this.copyTbody.childNodes[0]) this.copyTbody.removeChild(this.copyTbody.childNodes[0]); -- 2.43.2