svn commit: r545112 - in /ofbiz/trunk/applications/product: script/org/ofbiz/product/product/ProductServices.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: r545112 - in /ofbiz/trunk/applications/product: script/org/ofbiz/product/product/ProductServices.xml servicedef/services.xml

jacopoc
Author: jacopoc
Date: Thu Jun  7 01:50:11 2007
New Revision: 545112

URL: http://svn.apache.org/viewvc?view=rev&rev=545112
Log:
Implemented standard services to create/update/delete ProductKeywords: they are going to replace the existing event. Part of issue OFBIZ-1046

Modified:
    ofbiz/trunk/applications/product/script/org/ofbiz/product/product/ProductServices.xml
    ofbiz/trunk/applications/product/servicedef/services.xml

Modified: ofbiz/trunk/applications/product/script/org/ofbiz/product/product/ProductServices.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/script/org/ofbiz/product/product/ProductServices.xml?view=diff&rev=545112&r1=545111&r2=545112
==============================================================================
--- ofbiz/trunk/applications/product/script/org/ofbiz/product/product/ProductServices.xml (original)
+++ ofbiz/trunk/applications/product/script/org/ofbiz/product/product/ProductServices.xml Thu Jun  7 01:50:11 2007
@@ -294,6 +294,23 @@
         </if-not-empty>
     </simple-method>
 
+    <!-- Product Keyword Services -->
+    <simple-method method-name="createProductKeyword" short-description="create a ProductKeyword">
+        <make-value entity-name="ProductKeyword" value-name="newEntity"/>
+        <set-pk-fields map-name="parameters" value-name="newEntity"/>
+        <set-nonpk-fields map-name="parameters" value-name="newEntity"/>
+        <create-value value-name="newEntity"/>
+    </simple-method>  
+    <simple-method method-name="updateProductKeyword" short-description="update a ProductKeyword">
+        <entity-one entity-name="ProductKeyword" value-name="lookedUpValue"/>
+        <set-nonpk-fields map-name="parameters" value-name="lookedUpValue"/>
+        <store-value value-name="lookedUpValue"/>
+    </simple-method>
+    <simple-method method-name="deleteProductKeyword" short-description="delete a ProductKeyword">
+        <entity-one entity-name="ProductKeyword" value-name="lookedUpValue"/>
+        <remove-value value-name="lookedUpValue"/>
+    </simple-method>
+
     <simple-method method-name="indexProductKeywords" short-description="Index the Keywords for a Product" login-required="false">
         <!-- this service is meant to be called from an entity ECA for entities that include a productId -->
         <!-- if it is the Product entity itself triggering this action, then a [productInstance] parameter

Modified: ofbiz/trunk/applications/product/servicedef/services.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/servicedef/services.xml?view=diff&rev=545112&r1=545111&r2=545112
==============================================================================
--- ofbiz/trunk/applications/product/servicedef/services.xml (original)
+++ ofbiz/trunk/applications/product/servicedef/services.xml Thu Jun  7 01:50:11 2007
@@ -120,6 +120,27 @@
         <attribute name="productFeatureIdThree" type="String" mode="IN" optional="true"/>
     </service>
 
+    <!-- Product Keyword Services -->
+    <service name="createProductKeyword" default-entity-name="ProductKeyword" engine="simple"
+            location="org/ofbiz/product/product/ProductServices.xml" invoke="createProductKeyword" auth="true">
+        <description>Create a ProductKeyword</description>
+        <permission-service service-name="productGenericPermission" main-action="CREATE"/>
+        <auto-attributes include="pk" mode="IN" optional="false"/>
+        <auto-attributes include="nonpk" mode="IN" optional="true"/>
+    </service>
+    <service name="updateProductKeyword" default-entity-name="ProductKeyword" engine="simple"
+            location="org/ofbiz/product/product/ProductServices.xml" invoke="updateProductKeyword" auth="true">
+        <description>Update a ProductKeyword</description>
+        <permission-service service-name="productGenericPermission" main-action="UPDATE"/>
+        <auto-attributes include="pk" mode="IN" optional="false"/>
+        <auto-attributes include="nonpk" mode="IN" optional="true"/>
+    </service>
+    <service name="deleteProductKeyword" default-entity-name="ProductKeyword" engine="simple"
+            location="org/ofbiz/product/product/ProductServices.xml" invoke="deleteProductKeyword" auth="true">
+        <description>Delete a ProductKeyword</description>
+        <permission-service service-name="productGenericPermission" main-action="DELETE"/>
+        <auto-attributes include="pk" mode="IN" optional="false"/>
+    </service>
     <service name="indexProductKeywords" engine="simple"
                 location="org/ofbiz/product/product/ProductServices.xml" invoke="indexProductKeywords" auth="false">
         <description>Index the Keywords for a Product</description>