Author: jleroux
Date: Fri Sep 30 08:58:30 2016
New Revision: 1762871

URL: http://svn.apache.org/viewvc?rev=1762871&view=rev
Log:
Improves: replaces hardcoded strings "this operation" by 
CommonPermissionThisOperation
(OFBIZ-8324)

Thanks: Wai

Modified:
    ofbiz/trunk/applications/order/minilang/order/OrderDeliveryServices.xml
    
ofbiz/trunk/applications/product/minilang/product/category/CategoryServices.xml
    
ofbiz/trunk/applications/product/minilang/product/inventory/InventoryServices.xml
    
ofbiz/trunk/applications/product/minilang/product/product/ProductServices.xml
    
ofbiz/trunk/applications/product/minilang/product/store/ProductStoreServices.xml

Modified: 
ofbiz/trunk/applications/order/minilang/order/OrderDeliveryServices.xml
URL: 
http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/minilang/order/OrderDeliveryServices.xml?rev=1762871&r1=1762870&r2=1762871&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/minilang/order/OrderDeliveryServices.xml 
(original)
+++ ofbiz/trunk/applications/order/minilang/order/OrderDeliveryServices.xml Fri 
Sep 30 08:58:30 2016
@@ -144,7 +144,7 @@ under the License.
     <!-- Should be called in-line to use its out parameter indicating whether 
the user has permission or not. -->
     <simple-method method-name="checkSupplierRelatedPermission" 
short-description="Check Supplier Related Permission">
         <if-empty field="callingMethodName">
-            <set value="this operation" field="callingMethodName"/>
+            <property-to-field resource="CommonUiLabels" 
property="CommonPermissionThisOperation" field="callingMethodName"/>
         </if-empty>
         <if-empty field="checkAction">
             <set value="UPDATE" field="checkAction"/>

Modified: 
ofbiz/trunk/applications/product/minilang/product/category/CategoryServices.xml
URL: 
http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/minilang/product/category/CategoryServices.xml?rev=1762871&r1=1762870&r2=1762871&view=diff
==============================================================================
--- 
ofbiz/trunk/applications/product/minilang/product/category/CategoryServices.xml 
(original)
+++ 
ofbiz/trunk/applications/product/minilang/product/category/CategoryServices.xml 
Fri Sep 30 08:58:30 2016
@@ -650,7 +650,7 @@ under the License.
         call-simple-method, and the checkAction and callingMethodName 
attributes should be in the method context -->
     <simple-method method-name="checkCategoryRelatedPermission" 
short-description="Check Product Category Related Permission">
         <if-empty field="callingMethodName">
-            <set field="callingMethodName" value="this operation"/>
+            <property-to-field resource="CommonUiLabels" 
property="CommonPermissionThisOperation" field="callingMethodName"/>
         </if-empty>
         <if-empty field="checkAction">
             <set field="checkAction" value="UPDATE"/>
@@ -740,7 +740,11 @@ under the License.
         <set field="hasPermission" type="Boolean" value="true"/>
 
         <!--  Set up for a call to checkCategoryRelatedPermission below, but 
callingMethodName is needed sooner -->
-        <set field="callingMethodName" 
from-field="parameters.resourceDescription" default-value="this operation"/>
+        <set field="resourceDescription" 
from-field="parameters.resourceDescription"/>
+        <if-empty field="resourceDescription">
+            <property-to-field resource="CommonUiLabels" 
property="CommonPermissionThisOperation" field="resourceDescription"/>
+        </if-empty>
+        <set field="callingMethodName" from-field="resourceDescription"/>
         <set field="checkAction" from-field="parameters.mainAction" 
default-value="UPDATE"/>
 
         <entity-condition list="prodCatalogCategoryList" 
entity-name="ProdCatalogCategory" filter-by-date="true">

Modified: 
ofbiz/trunk/applications/product/minilang/product/inventory/InventoryServices.xml
URL: 
http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/minilang/product/inventory/InventoryServices.xml?rev=1762871&r1=1762870&r2=1762871&view=diff
==============================================================================
--- 
ofbiz/trunk/applications/product/minilang/product/inventory/InventoryServices.xml
 (original)
+++ 
ofbiz/trunk/applications/product/minilang/product/inventory/InventoryServices.xml
 Fri Sep 30 08:58:30 2016
@@ -25,7 +25,7 @@ under the License.
         call-simple-method, and the checkAction and callingMethodName 
attributes should be in the method context -->
     <simple-method method-name="checkFacilityRelatedPermission" 
short-description="Check Facility Related Permission">
         <if-empty field="callingMethodName">
-            <set value="this operation" field="callingMethodName"/>
+            <property-to-field resource="CommonUiLabels" 
property="CommonPermissionThisOperation" field="callingMethodName"/>
         </if-empty>
         <if-empty field="checkAction">
             <set value="UPDATE" field="checkAction"/>

Modified: 
ofbiz/trunk/applications/product/minilang/product/product/ProductServices.xml
URL: 
http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/minilang/product/product/ProductServices.xml?rev=1762871&r1=1762870&r2=1762871&view=diff
==============================================================================
--- 
ofbiz/trunk/applications/product/minilang/product/product/ProductServices.xml 
(original)
+++ 
ofbiz/trunk/applications/product/minilang/product/product/ProductServices.xml 
Fri Sep 30 08:58:30 2016
@@ -642,7 +642,7 @@ under the License.
         call-simple-method, and the checkAction and callingMethodName 
attributes should be in the method context -->
     <simple-method method-name="checkProductRelatedPermission" 
short-description="Check Product Related Permission">
         <if-empty field="callingMethodName">
-            <set value="this operation" field="callingMethodName"/>
+            <property-to-field resource="CommonUiLabels" 
property="CommonPermissionThisOperation" field="callingMethodName"/>
         </if-empty>
         <if-empty field="checkAction">
             <set value="UPDATE" field="checkAction"/>

Modified: 
ofbiz/trunk/applications/product/minilang/product/store/ProductStoreServices.xml
URL: 
http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/minilang/product/store/ProductStoreServices.xml?rev=1762871&r1=1762870&r2=1762871&view=diff
==============================================================================
--- 
ofbiz/trunk/applications/product/minilang/product/store/ProductStoreServices.xml
 (original)
+++ 
ofbiz/trunk/applications/product/minilang/product/store/ProductStoreServices.xml
 Fri Sep 30 08:58:30 2016
@@ -436,7 +436,7 @@ under the License.
         call-simple-method, and the checkAction and callingMethodName 
attributes should be in the method context -->
     <simple-method method-name="checkProductStoreRelatedPermission" 
short-description="Check ProductStore Related Permission">
         <if-empty field="callingMethodName">
-            <set field="callingMethodName" value="this operation"/>
+            <property-to-field resource="CommonUiLabels" 
property="CommonPermissionThisOperation" field="callingMethodName"/>
         </if-empty>
         <if-empty field="checkAction">
             <set field="checkAction" value="UPDATE"/>


Reply via email to