You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by jo...@apache.org on 2007/03/05 09:41:38 UTC

svn commit: r514602 - in /ofbiz/trunk/framework/service: dtd/service-mca.xsd src/org/ofbiz/service/mail/ServiceMcaAction.java

Author: jonesde
Date: Mon Mar  5 00:41:37 2007
New Revision: 514602

URL: http://svn.apache.org/viewvc?view=rev&rev=514602
Log:
Changed the runAsUser here to also be run-as-user for consistency; still supports old runAsUser in Java parsing code, though there will be a parse error

Modified:
    ofbiz/trunk/framework/service/dtd/service-mca.xsd
    ofbiz/trunk/framework/service/src/org/ofbiz/service/mail/ServiceMcaAction.java

Modified: ofbiz/trunk/framework/service/dtd/service-mca.xsd
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/service/dtd/service-mca.xsd?view=diff&rev=514602&r1=514601&r2=514602
==============================================================================
--- ofbiz/trunk/framework/service/dtd/service-mca.xsd (original)
+++ ofbiz/trunk/framework/service/dtd/service-mca.xsd Mon Mar  5 00:41:37 2007
@@ -106,7 +106,7 @@
                 </xs:restriction>
             </xs:simpleType>
         </xs:attribute>
-        <xs:attribute type="xs:string" name="runAsUser"/>
+        <xs:attribute type="xs:string" name="run-as-user"/>
         <xs:attribute name="persist" default="false">
             <xs:simpleType>
                 <xs:restriction base="xs:token">

Modified: ofbiz/trunk/framework/service/src/org/ofbiz/service/mail/ServiceMcaAction.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/service/src/org/ofbiz/service/mail/ServiceMcaAction.java?view=diff&rev=514602&r1=514601&r2=514602
==============================================================================
--- ofbiz/trunk/framework/service/src/org/ofbiz/service/mail/ServiceMcaAction.java (original)
+++ ofbiz/trunk/framework/service/src/org/ofbiz/service/mail/ServiceMcaAction.java Mon Mar  5 00:41:37 2007
@@ -25,6 +25,7 @@
 import org.ofbiz.service.ServiceUtil;
 import org.ofbiz.base.util.UtilMisc;
 import org.ofbiz.base.util.Debug;
+import org.ofbiz.base.util.UtilValidate;
 import org.ofbiz.entity.GenericValue;
 
 import org.w3c.dom.Element;
@@ -43,7 +44,9 @@
     protected ServiceMcaAction(Element action) {
         this.serviceName = action.getAttribute("service");
         this.serviceMode = action.getAttribute("mode");
-        this.runAsUser = action.getAttribute("runAsUser");
+        this.runAsUser = action.getAttribute("run-as-user");
+        // support the old, inconsistent attribute name
+        if (UtilValidate.isEmail(this.runAsUser)) this.runAsUser = action.getAttribute("runAsUser");
         this.persist = "true".equals(action.getAttribute("persist"));
     }