JBAS-216 set editor/edit_date on cat_date change
authorBill Erickson <berickxx@gmail.com>
Fri, 3 Apr 2015 17:19:40 +0000 (10:19 -0700)
committerBill Erickson <berickxx@gmail.com>
Thu, 21 Mar 2019 19:46:23 +0000 (15:46 -0400)
Signed-off-by: Bill Erickson <berickxx@gmail.com>
Open-ILS/xul/staff_client/server/cat/marcedit.js

index 600fb9e..9a50e31 100644 (file)
@@ -2435,7 +2435,8 @@ function updateCatDate() {
     var originalCatDate = new Date(current_bib.cataloging_date());
     if (originalCatDate.getDate() != catDate.getDate() || originalCatDate.getMonth() != catDate.getMonth() || originalCatDate.getFullYear() != catDate.getFullYear()) {
         current_bib.cataloging_date(catDate.getFullYear() + "-" + (catDate.getMonth() + 1) + "-" + catDate.getDate());
-        current_bib.ischanged = true;
+        current_bib.editor(ses('staff_id'));
+        current_bib.edit_date('now');
         pcrud.update(current_bib);
         dojo.byId('cat-date-button').disabled = true;
         dojo.byId('clear-cat-date-button').disabled = false;
@@ -2479,6 +2480,8 @@ function clearCatDate() {
     if (current_bib.cataloging_date() === null) return;
 
     current_bib.cataloging_date(null);
+    current_bib.editor(ses('staff_id'));
+    current_bib.edit_date('now');
     pcrud.update(current_bib);
 
     // set the UI back to the today