From 2e12483c03f88e6132aa6ca416b8919328fa1f6e Mon Sep 17 00:00:00 2001 From: Jeff Godin Date: Tue, 25 Jun 2013 16:03:49 -0400 Subject: [PATCH] Make deactivation of card optional Make deactivation of current card optional when using Replace Barcode function. Signed-off-by: Jeff Godin --- Open-ILS/web/js/ui/default/actor/user/register.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Open-ILS/web/js/ui/default/actor/user/register.js b/Open-ILS/web/js/ui/default/actor/user/register.js index ced646fbae..3594ca33bf 100644 --- a/Open-ILS/web/js/ui/default/actor/user/register.js +++ b/Open-ILS/web/js/ui/default/actor/user/register.js @@ -575,8 +575,12 @@ function replaceCardHandler() { // pull old card off the cards list so we don't have a dupe sitting in there if (patron.cards().length > 0) { var old = patron.cards().filter(function(c){return (c.id() == patron.card().id())})[0]; - old.active('f'); - old.ischanged(1); + /* TADL Customization */ + var deactivate = confirm('Deactivate the original card?'); + if (deactivate) { + old.active('f'); + old.ischanged(1); + } } var newc = new fieldmapper.ac(); -- 2.11.0