mirror of
https://github.com/moodle/moodle.git
synced 2025-03-14 04:30:15 +01:00
Added dialog to confirm deletion of activity.
This commit is contained in:
parent
09575480bb
commit
1752e584de
@ -548,6 +548,10 @@ resource_class.prototype.toggle_hide = function(target,e,superficial,force){
|
||||
resource_class.prototype.delete_button = function(){
|
||||
if(this.debug)YAHOO.log("Deleteing "+this.getEl().id+"from parent "+this.parentObj.getEl().id);
|
||||
|
||||
if(!confirm('Are you sure you wish to delete this '+this.is+"?")){
|
||||
return false;
|
||||
}
|
||||
|
||||
this.getEl().parentNode.removeChild(this.getEl());
|
||||
this.parentObj.remove_resource(this);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user