svn commit: r956129 - in /ofbiz/trunk/framework/common: script/org/ofbiz/common/CommonServices.xml servicedef/services.xml

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r956129 - in /ofbiz/trunk/framework/common: script/org/ofbiz/common/CommonServices.xml servicedef/services.xml

jleroux@apache.org
Author: jleroux
Date: Fri Jun 18 21:08:24 2010
New Revision: 956129

URL: http://svn.apache.org/viewvc?rev=956129&view=rev
Log:
New updateNote service

Modified:
    ofbiz/trunk/framework/common/script/org/ofbiz/common/CommonServices.xml
    ofbiz/trunk/framework/common/servicedef/services.xml

Modified: ofbiz/trunk/framework/common/script/org/ofbiz/common/CommonServices.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/script/org/ofbiz/common/CommonServices.xml?rev=956129&r1=956128&r2=956129&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/script/org/ofbiz/common/CommonServices.xml (original)
+++ ofbiz/trunk/framework/common/script/org/ofbiz/common/CommonServices.xml Fri Jun 18 21:08:24 2010
@@ -229,4 +229,14 @@ under the License.
         </iterate>
         <field-to-result field="themeResources"/>
     </simple-method>
+
+    <simple-method method-name="updateNote" short-description="Update a note">
+        <entity-one entity-name="NoteData" value-field="noteData">
+            <field-map field-name="noteId" from-field="parameters.noteId"/>
+        </entity-one>
+        <set-nonpk-fields map="parameters" value-field="noteData"/>
+        <store-value value-field="noteData"/>
+        <field-to-result field="noteData.noteId" result-name="noteId"/>
+    </simple-method>
+    
 </simple-methods>

Modified: ofbiz/trunk/framework/common/servicedef/services.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/servicedef/services.xml?rev=956129&r1=956128&r2=956129&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/servicedef/services.xml (original)
+++ ofbiz/trunk/framework/common/servicedef/services.xml Fri Jun 18 21:08:24 2010
@@ -48,14 +48,21 @@ under the License.
     </service>
 
     <service name="createNote" engine="java"
-            location="org.ofbiz.common.CommonServices" invoke="createNote">
+        location="org.ofbiz.common.CommonServices" invoke="createNote">
         <description>Create a new note record</description>
         <attribute name="partyId" type="String" mode="INOUT" optional="true"/>
         <attribute name="noteName" type="String" mode="IN" optional="true"/>
         <attribute name="note" type="String" mode="IN" allow-html="safe"/>
         <attribute name="noteId" type="String" mode="OUT"/>
     </service>
-
+    
+    <service name="updateNote" engine="simple" default-entity-name="NoteData"
+        location="component://common/script/org/ofbiz/common/CommonServices.xml" invoke="updateNote">
+        <description>Update a note record</description>
+        <auto-attributes include="pk" mode="INOUT" optional="false"/>
+        <auto-attributes include="nonpk" mode="IN" optional="true"/>
+    </service>
+    
     <service name="adjustDebugLevels" engine="java"
              location="org.ofbiz.common.CommonServices" invoke="adjustDebugLevels" auth="true">
         <description>Sets/Updates cached debugging levels</description>