From 0f58f9d2326fe9570716fa5fecfd0edc2ce060f2 Mon Sep 17 00:00:00 2001 From: Sam Minnee Date: Sat, 26 Apr 2008 06:35:27 +0000 Subject: [PATCH] Merged revisions 52795 via svnmerge from http://svn.silverstripe.com/open/modules/sapphire/branches/govtsecurity ........ r52795 | sminnee | 2008-04-15 22:19:09 +1200 (Tue, 15 Apr 2008) | 1 line Allow FormResponse loading into CTF pop-up ........ git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@53488 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- javascript/ComplexTableField_popup.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/javascript/ComplexTableField_popup.js b/javascript/ComplexTableField_popup.js index 750918899..2564142ae 100755 --- a/javascript/ComplexTableField_popup.js +++ b/javascript/ComplexTableField_popup.js @@ -11,6 +11,10 @@ ComplexTableFieldPopupForm.prototype = { }); }, + loadNewPage : function(content) { + this.innerHTML = content; + } + submitForm : function(e) { // if custom validation implementation (extend class to implement) if(this.validate) { @@ -46,7 +50,9 @@ ComplexTableFieldPopupForm.prototype = { }, updateTableAfterSave : function(response) { - eval(response.responseText); + try { + eval(response.responseText); + } catch(er) { alert(er.message); } var theForm = document.getElementsByTagName("form")[0];