You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by su...@apache.org on 2020/05/11 07:23:41 UTC

[ofbiz-framework] branch trunk updated: Improved: Converted all TechDataCalendar related CRUD services from simple to entity-auto (#112)

This is an automated email from the ASF dual-hosted git repository.

surajk pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
     new 814b2ef  Improved: Converted all TechDataCalendar related CRUD services from simple to entity-auto (#112)
814b2ef is described below

commit 814b2ef1396b26a36c93179a123243079e5de79b
Author: Suraj Khurana <64...@users.noreply.github.com>
AuthorDate: Mon May 11 12:53:31 2020 +0530

    Improved: Converted all TechDataCalendar related CRUD services from simple to entity-auto (#112)
    
    (OFBIZ-11632)
---
 .../manufacturing/minilang/techdata/RoutingSimpleServices.xml | 11 -----------
 applications/manufacturing/servicedef/services_calendar.xml   |  4 ++--
 2 files changed, 2 insertions(+), 13 deletions(-)

diff --git a/applications/manufacturing/minilang/techdata/RoutingSimpleServices.xml b/applications/manufacturing/minilang/techdata/RoutingSimpleServices.xml
index f58f278..7a689dc 100644
--- a/applications/manufacturing/minilang/techdata/RoutingSimpleServices.xml
+++ b/applications/manufacturing/minilang/techdata/RoutingSimpleServices.xml
@@ -50,17 +50,6 @@ under the License.
         </else>
         </if-not-empty>
     </simple-method>
-
-    <simple-method method-name="updateCalendar" short-description="Update Calendar">
-        <check-permission permission="MANUFACTURING" action="_UPDATE"><fail-property resource="ManufacturingUiLabels" property="ManufacturingCalendarPermissionError"/></check-permission>
-        <check-errors/>
-        <make-value entity-name="TechDataCalendar" value-field="lookupPKMap"/>
-        <set-pk-fields map="parameters" value-field="lookupPKMap"/>
-        <find-by-primary-key entity-name="TechDataCalendar" map="lookupPKMap" value-field="lookedUpValue"/>
-        <set-nonpk-fields map="parameters" value-field="lookedUpValue"/>
-        <store-value value-field="lookedUpValue"/>
-    </simple-method>
-
     <simple-method method-name="removeCalendar" short-description="Remove Calendar">
         <check-permission permission="MANUFACTURING" action="_DELETE"><fail-property resource="ManufacturingUiLabels" property="ManufacturingCalendarPermissionError"/></check-permission>
         <check-errors/>
diff --git a/applications/manufacturing/servicedef/services_calendar.xml b/applications/manufacturing/servicedef/services_calendar.xml
index ffd3238..b861ae8 100644
--- a/applications/manufacturing/servicedef/services_calendar.xml
+++ b/applications/manufacturing/servicedef/services_calendar.xml
@@ -30,9 +30,9 @@ under the License.
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="true"/>
     </service>
-    <service name="updateCalendar" engine="simple" default-entity-name="TechDataCalendar"
-            location="component://manufacturing/minilang/techdata/RoutingSimpleServices.xml" invoke="updateCalendar">
+    <service name="updateCalendar" engine="entity-auto" default-entity-name="TechDataCalendar" invoke="update">
         <description>Update a calendar</description>
+        <permission-service service-name="manufacturingPermissionService" main-action="UPDATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="true"/>
     </service>