From: dbs Date: Fri, 20 Aug 2010 03:35:59 +0000 (+0000) Subject: Add a speedbump (confirmation dialog) when deleting authority records X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=8d63a5b63a29eadf0c18498176eee55b161ba81e;p=evergreen%2Fbjwebb.git Add a speedbump (confirmation dialog) when deleting authority records git-svn-id: svn://svn.open-ils.org/ILS/trunk@17276 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/web/js/ui/default/cat/authority/list.js b/Open-ILS/web/js/ui/default/cat/authority/list.js index 5cffc9eab..367c09958 100644 --- a/Open-ILS/web/js/ui/default/cat/authority/list.js +++ b/Open-ILS/web/js/ui/default/cat/authority/list.js @@ -73,6 +73,12 @@ function displayAuthorities(data) { // "Delete" menu item new dijit.MenuItem({"id": "delete_" + authId, "onClick":function(){ recId = this.id.slice(this.id.lastIndexOf('_') + 1); + + // Deleting an authority record is unusual; let's be 100% sure + if (!confirm("Are you sure you want to delete record " + recId + "?")) { + return; + } + pcrud = new openils.PermaCrud(); auth_rec = pcrud.retrieve("are", recId); if (auth_rec) {