[Carbon-dev] svn commit r37294 - trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences

supun at wso2.com supun at wso2.com
Sun May 31 23:57:09 PDT 2009


Author: supun
Date: Sun May 31 23:57:09 2009
New Revision: 37294
URL: http://wso2.org/svn/browse/wso2?view=rev&revision=37294

Log:
Fixing issue CARBON-3967

Added:
   trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-update-ajaxprocessor.jsp
Modified:
   trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/design_sequence.jsp
   trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-edit-ajaxprocessor.jsp

Modified: trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/design_sequence.jsp
URL: http://wso2.org/svn/browse/wso2/trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/design_sequence.jsp?rev=37294&r1=37293&r2=37294&view=diff
==============================================================================
--- trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/design_sequence.jsp	(original)
+++ trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/design_sequence.jsp	Sun May 31 23:57:09 2009
@@ -271,6 +271,7 @@
     function updateMediator(mediatorName) {
         var funcName = mediatorName + "MediatorValidate";
         var options = {
+                dataType: 'text/xml',
                 beforeSubmit:  beforeMediatorUpdate,  // pre-submit callback
                 success:       afterMediatorUpdate  // post-submit callback
             };
@@ -290,11 +291,13 @@
         document.getElementById('mediator-sourceview-header').style.display = 'none';
         document.getElementById('mediator-edit-tab').style.display = 'none';
         if (src != null && src != undefined) {
-            if (jQuery(src).find("script") != null) {
-                var wtf = jQuery(src).find("script").each(function() {
-                    eval(jQuery(this).text());
-                });
-            }            
+//            if (jQuery(src).find("script") != null) {
+//                jQuery(src).find('script').each(function() {
+//                    alert(jQuery(this).text());
+//                    eval(jQuery(this).text());
+//                });
+//            }            
+            eval(src);
         }
     }    
 

Modified: trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-edit-ajaxprocessor.jsp
URL: http://wso2.org/svn/browse/wso2/trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-edit-ajaxprocessor.jsp?rev=37294&r1=37293&r2=37294&view=diff
==============================================================================
--- trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-edit-ajaxprocessor.jsp	(original)
+++ trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-edit-ajaxprocessor.jsp	Sun May 31 23:57:09 2009
@@ -61,7 +61,7 @@
                 <a target="_blank" href="<%= helpPage %>"><fmt:message key="sequence.mediator.help"/></a>
             </div>
 
-    <form action="<%=updatePage%>" id="mediator-editor-form" name="mediator-editor-form">
+    <form action="mediator-update-ajaxprocessor.jsp" id="mediator-editor-form" name="mediator-editor-form">
         <jsp:include page="<%= editPage %>" flush="true">
             <jsp:param name="mediatorPosition" value="<%=mediatorPosition%>"/>
         </jsp:include>
@@ -73,6 +73,7 @@
 <tr class="buttonRow" style="border-top: solid 1px #ccc;">
 <td>
     <input type="hidden" id="mediatorID" name="mediatorID" value="<%=mediatorPosition%>"/>
+    <input type="hidden" id="updatePage" name="updatePage" value="<%=updatePage%>"/>
     <input type="hidden" name="random" value="<%=Math.random()%>"/>
     <input type="button" class="button"
            onclick="javascript: updateMediator('<%= mediatorInfo.getUIFolderName() %>'); return false;"

Added: trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-update-ajaxprocessor.jsp
URL: http://wso2.org/svn/browse/wso2/trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-update-ajaxprocessor.jsp?pathrev=37294
==============================================================================
--- (empty file)
+++ trunk/carbon-components/sequence-editor/org.wso2.carbon.sequences.ui/src/main/resources/web/sequences/mediator-update-ajaxprocessor.jsp	Sun May 31 23:57:09 2009
@@ -0,0 +1,31 @@
+<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1" %>
+<%--
+  ~  Copyright (c) 2008, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
+  ~
+  ~  Licensed under the Apache License, Version 2.0 (the "License");
+  ~  you may not use this file except in compliance with the License.
+  ~  You may obtain a copy of the License at
+  ~
+  ~        http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~  Unless required by applicable law or agreed to in writing, software
+  ~  distributed under the License is distributed on an "AS IS" BASIS,
+  ~  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  ~  See the License for the specific language governing permissions and
+  ~  limitations under the License.
+  --%>
+
+<%@ page import="org.wso2.carbon.mediator.service.MediatorService" %>
+<%@ page import="org.wso2.carbon.mediator.service.MediatorStore" %>
+<%@ page import="org.wso2.carbon.mediator.service.ui.Mediator" %>
+<%@ page import="org.wso2.carbon.sequences.ui.util.SequenceEditorHelper" %>
+<%@ page import="java.util.Set" %>
+<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
+<%@ taglib uri="http://wso2.org/projects/carbon/taglibs/carbontags.jar" prefix="carbon" %>
+
+<%
+    String updatePage = request.getParameter("updatePage");    
+%>
+
+
+<jsp:include page="<%= updatePage %>" flush="true"/>



More information about the Carbon-dev mailing list