Update of /var/cvs/applications/searchrelate/templates
In directory james.mmbase.org:/tmp/cvs-serv22193/templates
Modified Files:
List.js.jsp
Log Message:
Added support for confirmation of deletion
See also: http://cvs.mmbase.org/viewcvs/applications/searchrelate/templates
Index: List.js.jsp
===================================================================
RCS file: /var/cvs/applications/searchrelate/templates/List.js.jsp,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -b -r1.10 -r1.11
--- List.js.jsp 5 Jun 2008 13:57:20 -0000 1.10
+++ List.js.jsp 5 Jun 2008 14:25:50 -0000 1.11
@@ -13,7 +13,7 @@
* The user does not need to push a commit button. All data is implicitely
committed (after a few second of inactivity, or before unload).
*
* @author Michiel Meeuwissen
- * @version $Id: List.js.jsp,v 1.10 2008/06/05 13:57:20 michiel Exp $
+ * @version $Id: List.js.jsp,v 1.11 2008/06/05 14:25:50 michiel Exp $
*/
@@ -173,6 +173,13 @@
List.prototype.bindDelete = function(a) {
a.list = this;
$(a).click(function(ev) {
+ var really = true;
+ if ($(a).hasClass("confirm")) {
+ $($(a).parents("li")[0]).addClass("highlight");
+ really = confirm("Really");
+ $($(a).parents("li")[0]).removeClass("highlight");
+ }
+ if (really) {
var url = a.href;
var params = {};
$.ajax({async: true, url: url, type: "GET", dataType: "xml", data:
params,
@@ -186,6 +193,7 @@
}
}
});
+ }
return false;
});
_______________________________________________
Cvs mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/cvs