diff --git a/mindplot/src/main/javascript/libraries/moodialog/MooDialog.Request.js b/mindplot/src/main/javascript/libraries/moodialog/MooDialog.Request.js index 101fa6e1..a5b5cf17 100644 --- a/mindplot/src/main/javascript/libraries/moodialog/MooDialog.Request.js +++ b/mindplot/src/main/javascript/libraries/moodialog/MooDialog.Request.js @@ -15,17 +15,47 @@ MooDialog.Request = new Class({ initialize: function(url, requestOptions, options) { this.parent(options); - this.requestOptions = requestOptions || {method:'get'}; - this.requestOptions.url = url; + this.requestOptions = requestOptions || {}; this.requestOptions.update = this.content; this.requestOptions.evalScripts = true; + this.requestOptions.noCache = true; + + this.requestOptions.onFailure = function(xhr) { + // Intercept form requests ... + console.log("Failure:"); + console.log(xhr); + }.bind(this); + + this.requestOptions.onSuccess = function() { + // Intercept form requests ... + var forms = this.content.getElements('form'); + forms.forEach(function(form) { + form.addEvent('submit', function(event) { + // Intercept form ... + this.requestOptions.url = form.action; + this.requestOptions.method = form.method ? form.method : 'post'; + var request = new Request.HTML(this.requestOptions); + request.post(form); + event.stopPropagation(); + return false; + }.bind(this)) + }.bind(this)); + }.bind(this); + this.addEvent('open', function() { - var request = new Request.HTML(this.requestOptions).send(); + this.requestOptions.url = url; + this.requestOptions.method = 'get'; + var request = new Request.HTML(this.requestOptions); + request.send(); + MooDialog.Request.active = this; }.bind(this)); - if (this.options.autoOpen) this.open(); + this.addEvent('close', function() { + MooDialog.Request.active = null; + }.bind(this)); + if (this.options.autoOpen) this.open(); }, setRequestOptions: function(options) { diff --git a/wise-doc/src/main/webapp/html/editor.html b/wise-doc/src/main/webapp/html/editor.html index 62e3ba93..492a0729 100644 --- a/wise-doc/src/main/webapp/html/editor.html +++ b/wise-doc/src/main/webapp/html/editor.html @@ -196,7 +196,7 @@
-
+
diff --git a/wise-webapp/src/main/webapp/html/embedded.html b/wise-webapp/src/main/webapp/html/embedded.html index 43ae4b73..c2c45ae5 100644 --- a/wise-webapp/src/main/webapp/html/embedded.html +++ b/wise-webapp/src/main/webapp/html/embedded.html @@ -1,4 +1,16 @@ - + + + + diff --git a/wise-webapp/src/main/webapp/jsp/closeDialog.jsp b/wise-webapp/src/main/webapp/jsp/closeDialog.jsp index 8231182b..fb9ce8c0 100644 --- a/wise-webapp/src/main/webapp/jsp/closeDialog.jsp +++ b/wise-webapp/src/main/webapp/jsp/closeDialog.jsp @@ -1,8 +1,3 @@ \ No newline at end of file diff --git a/wise-webapp/src/main/webapp/jsp/mindmapEditor.jsp b/wise-webapp/src/main/webapp/jsp/mindmapEditor.jsp index 5b2a2b00..7649f6be 100644 --- a/wise-webapp/src/main/webapp/jsp/mindmapEditor.jsp +++ b/wise-webapp/src/main/webapp/jsp/mindmapEditor.jsp @@ -206,7 +206,7 @@
-
+
diff --git a/wise-webapp/src/main/webapp/jsp/mindmapList.jsp b/wise-webapp/src/main/webapp/jsp/mindmapList.jsp index 444cfbcb..1c0a79d0 100644 --- a/wise-webapp/src/main/webapp/jsp/mindmapList.jsp +++ b/wise-webapp/src/main/webapp/jsp/mindmapList.jsp @@ -14,23 +14,8 @@ - - - - +
@@ -99,17 +84,18 @@
- @@ -175,54 +161,63 @@ -
+
+ @@ -249,7 +244,9 @@ alt=""/> - : " alt="World" + : " + alt="World" @@ -275,11 +272,13 @@