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 86b0a4e Improved: Refactor simple methods names as per naming
convention best practices. (#137)
86b0a4e is described below
commit 86b0a4e592cbf087f5266d5e1347e963031b1c34
Author: Suraj Khurana <[email protected]>
AuthorDate: Sat May 23 10:33:46 2020 +0530
Improved: Refactor simple methods names as per naming convention best
practices. (#137)
(OFBIZ-11700)
---
.../accounting/minilang/invoice/InvoiceServices.xml | 18 +++++++++---------
.../minilang/test/AutoAcctgTransTestsPurchase.xml | 8 ++++----
.../minilang/test/AutoAcctgTransTestsSales.xml | 8 ++++----
applications/order/minilang/order/OrderServices.xml | 2 +-
applications/order/minilang/test/ShoppingCartTests.xml | 2 +-
applications/order/servicedef/services.xml | 4 ++--
.../imagemanagement/ImageManagementServices.xml | 2 +-
applications/product/servicedef/services.xml | 2 +-
8 files changed, 23 insertions(+), 23 deletions(-)
diff --git a/applications/accounting/minilang/invoice/InvoiceServices.xml
b/applications/accounting/minilang/invoice/InvoiceServices.xml
index 4629f1e..166b166 100644
--- a/applications/accounting/minilang/invoice/InvoiceServices.xml
+++ b/applications/accounting/minilang/invoice/InvoiceServices.xml
@@ -102,7 +102,7 @@ under the License.
</simple-method>
<simple-method method-name="updateInvoice" short-description="Update the
header of an existing Invoice">
- <call-simple-method method-name="InvoiceStatusInProgress"/>
+ <call-simple-method method-name="checkInvoiceStatusInProgress"/>
<!-- find the current record -->
<make-value entity-name="Invoice" value-field="lookupPKMap"/>
<set-pk-fields map="parameters" value-field="lookupPKMap"/>
@@ -150,7 +150,7 @@ under the License.
<simple-method method-name="createInvoiceItem" short-description="Create a
new Invoice Item">
<set field="invoiceId" from-field="parameters.invoiceId"/>
- <call-simple-method method-name="InvoiceStatusInProgress"/>
+ <call-simple-method method-name="checkInvoiceStatusInProgress"/>
<make-value entity-name="InvoiceItem" value-field="newEntity"/>
<set-pk-fields map="parameters" value-field="newEntity"/>
<set-nonpk-fields map="parameters" value-field="newEntity"/>
@@ -184,7 +184,7 @@ under the License.
</simple-method>
<simple-method method-name="updateInvoiceItem"
short-description="Update an existing Invoice Item">
- <call-simple-method method-name="InvoiceStatusInProgress"/>
+ <call-simple-method method-name="checkInvoiceStatusInProgress"/>
<make-value entity-name="InvoiceItem" value-field="lookupPKMap"/>
<set-pk-fields map="parameters" value-field="lookupPKMap"/>
@@ -218,9 +218,9 @@ under the License.
<field-to-result field="lookedUpValue.invoiceId"
result-name="invoiceId"/>
</simple-method>
<simple-method method-name="removeInvoiceItem" short-description="Remove
an existing Invoice Item">
- <call-simple-method method-name="InvoiceStatusInProgress"/>
+ <call-simple-method method-name="checkInvoiceStatusInProgress"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
- <call-simple-method method-name="InvoiceStatusInProgress"/>
+ <call-simple-method method-name="checkInvoiceStatusInProgress"/>
<set field="paymentApplicationMap.invoiceId"
from-field="parameters.invoiceId"/>
<set field="paymentApplicationMap.invoiceItemSeqId"
from-field="parameters.invoiceItemSeqId"/>
@@ -328,7 +328,7 @@ under the License.
</simple-method>
<simple-method method-name="createInvoiceRole" short-description="Create a
Invoice Role">
- <call-simple-method method-name="InvoiceStatusInProgress"/>
+ <call-simple-method method-name="checkInvoiceStatusInProgress"/>
<make-value entity-name="InvoiceRole" value-field="newEntity"/>
<set-nonpk-fields map="parameters" value-field="newEntity"/>
<set-pk-fields map="parameters" value-field="newEntity"/>
@@ -337,7 +337,7 @@ under the License.
</simple-method>
<simple-method method-name="removeInvoiceRole" short-description="Remove
existing Invoice Role">
- <call-simple-method method-name="InvoiceStatusInProgress"/>
+ <call-simple-method method-name="checkInvoiceStatusInProgress"/>
<entity-one entity-name="InvoiceRole" value-field="lookedUpValue"/>
<remove-value value-field="lookedUpValue"/>
</simple-method>
@@ -433,7 +433,7 @@ under the License.
</simple-method>
<simple-method method-name="createInvoiceTerm" short-description="Create a
Invoice Term">
- <call-simple-method method-name="InvoiceStatusInProgress"/>
+ <call-simple-method method-name="checkInvoiceStatusInProgress"/>
<make-value entity-name="InvoiceTerm" value-field="newEntity"/>
<set-nonpk-fields map="parameters" value-field="newEntity"/>
@@ -456,7 +456,7 @@ under the License.
</simple-method>
<!-- ===============subroutine services =================-->
- <simple-method method-name="InvoiceStatusInProgress"
short-description="Check if the invoiceStatus is in progress">
+ <simple-method method-name="checkInvoiceStatusInProgress"
short-description="Check if the invoiceStatus is in progress">
<!-- find the current header record -->
<entity-one entity-name="Invoice" value-field="headerValue"/>
<if-empty field="headerValue">
diff --git
a/applications/accounting/minilang/test/AutoAcctgTransTestsPurchase.xml
b/applications/accounting/minilang/test/AutoAcctgTransTestsPurchase.xml
index 7174d54..f6523a3 100644
--- a/applications/accounting/minilang/test/AutoAcctgTransTestsPurchase.xml
+++ b/applications/accounting/minilang/test/AutoAcctgTransTestsPurchase.xml
@@ -67,7 +67,7 @@ under the License.
<assert><not><if-empty field="acctgTransEntryList"/></not></assert>
- <call-simple-method method-name="UtilCheckEntriesBalance"/>
+ <call-simple-method method-name="checkEntriesBalance"/>
<iterate list="acctgTransEntryList" entry="acctgTransEntry">
<if-compare field="acctgTransEntry.debitCreditFlag"
operator="equals" value="C">
@@ -133,7 +133,7 @@ under the License.
<assert><not><if-empty field="acctgTransEntryList"/></not></assert>
- <call-simple-method method-name="UtilCheckEntriesBalance"/>
+ <call-simple-method method-name="checkEntriesBalance"/>
<iterate list="acctgTransEntryList" entry="acctgTransEntry">
<if-compare field="acctgTransEntry.debitCreditFlag"
operator="equals" value="C">
@@ -177,7 +177,7 @@ under the License.
<assert><not><if-empty field="acctgTransEntryList"/></not></assert>
- <call-simple-method method-name="UtilCheckEntriesBalance"/>
+ <call-simple-method method-name="checkEntriesBalance"/>
<iterate list="acctgTransEntryList" entry="acctgTransEntry">
<if-compare field="acctgTransEntry.debitCreditFlag"
operator="equals" value="C">
@@ -198,7 +198,7 @@ under the License.
</simple-method>
- <simple-method method-name="UtilCheckEntriesBalance" login-required="false"
+ <simple-method method-name="checkEntriesBalance" login-required="false"
short-description="Short util method that takes a list of
AcctgTransEntry values (acctgTransEntryList) and checks that the debit and
credit totals balance.">
<set field="debitTotal" type="BigDecimal" value="0.0"/>
<set field="creditTotal" type="BigDecimal" value="0.0"/>
diff --git a/applications/accounting/minilang/test/AutoAcctgTransTestsSales.xml
b/applications/accounting/minilang/test/AutoAcctgTransTestsSales.xml
index e1095bd..b826d7e 100644
--- a/applications/accounting/minilang/test/AutoAcctgTransTestsSales.xml
+++ b/applications/accounting/minilang/test/AutoAcctgTransTestsSales.xml
@@ -68,7 +68,7 @@ under the License.
<get-related list="acctgTransEntryList"
relation-name="AcctgTransEntry" value-field="acctgTrans"/>
<assert><not><if-empty field="acctgTransEntryList"/></not></assert>
- <call-simple-method method-name="UtilCheckEntriesBalance"
xml-resource="component://accounting/minilang/test/AutoAcctgTransTestsPurchase.xml"/>
+ <call-simple-method method-name="checkEntriesBalance"
xml-resource="component://accounting/minilang/test/AutoAcctgTransTestsPurchase.xml"/>
<iterate list="acctgTransEntryList" entry="acctgTransEntry">
<if-compare field="acctgTransEntry.debitCreditFlag"
operator="equals" value="C">
@@ -144,7 +144,7 @@ under the License.
<assert><not><if-empty field="acctgTransEntryList"/></not></assert>
- <call-simple-method method-name="UtilCheckEntriesBalance"
xml-resource="component://accounting/minilang/test/AutoAcctgTransTestsPurchase.xml"/>
+ <call-simple-method method-name="checkEntriesBalance"
xml-resource="component://accounting/minilang/test/AutoAcctgTransTestsPurchase.xml"/>
<set field="acctgTransEntryFilter.glAccountTypeId"
value="ACCOUNTS_RECEIVABLE"/>
<set field="acctgTransEntryFilter.glAccountId" value="120000"/>
@@ -168,7 +168,7 @@ under the License.
<assert><not><if-empty field="acctgTransEntryList"/></not></assert>
- <call-simple-method method-name="UtilCheckEntriesBalance"
xml-resource="component://accounting/minilang/test/AutoAcctgTransTestsPurchase.xml"/>
+ <call-simple-method method-name="checkEntriesBalance"
xml-resource="component://accounting/minilang/test/AutoAcctgTransTestsPurchase.xml"/>
<set field="acctgTransEntryFilter.glAccountTypeId"
value="ACCOUNTS_RECEIVABLE"/>
<set field="acctgTransEntryFilter.glAccountId" value="120000"/>
@@ -226,7 +226,7 @@ under the License.
<assert><not><if-empty field="acctgTransEntryList"/></not></assert>
- <call-simple-method method-name="UtilCheckEntriesBalance"
xml-resource="component://accounting/minilang/test/AutoAcctgTransTestsPurchase.xml"/>
+ <call-simple-method method-name="checkEntriesBalance"
xml-resource="component://accounting/minilang/test/AutoAcctgTransTestsPurchase.xml"/>
<iterate list="acctgTransEntryList" entry="acctgTransEntry">
<if-compare field="acctgTransEntry.debitCreditFlag"
operator="equals" value="C">
diff --git a/applications/order/minilang/order/OrderServices.xml
b/applications/order/minilang/order/OrderServices.xml
index a0c7eb1..f318825 100644
--- a/applications/order/minilang/order/OrderServices.xml
+++ b/applications/order/minilang/order/OrderServices.xml
@@ -1269,7 +1269,7 @@ under the License.
</if-not-empty>
</simple-method>
- <simple-method method-name="MoveItemBetweenShipGroups"
short-description="Move order items between ship groups">
+ <simple-method method-name="moveItemBetweenShipGroups"
short-description="Move order items between ship groups">
<entity-one entity-name="OrderItemShipGroupAssoc"
value-field="orderItemShipGroupAssoc">
<field-map field-name="orderId" from-field="parameters.orderId"/>
<field-map field-name="orderItemSeqId"
from-field="parameters.orderItemSeqId"/>
diff --git a/applications/order/minilang/test/ShoppingCartTests.xml
b/applications/order/minilang/test/ShoppingCartTests.xml
index a881b14..0e4e08a 100644
--- a/applications/order/minilang/test/ShoppingCartTests.xml
+++ b/applications/order/minilang/test/ShoppingCartTests.xml
@@ -720,7 +720,7 @@ under the License.
<set field="map.fromGroupIndex" value="00001"/>
<set field="map.toGroupIndex" value="00002"/>
<set field="map.quantity" value="2" type="BigDecimal"/>
- <call-service service-name="MoveItemBetweenShipGroups"
in-map-name="map"/>
+ <call-service service-name="moveItemBetweenShipGroups"
in-map-name="map"/>
<entity-one entity-name="OrderItemShipGroupAssoc"
value-field="orderItemShipGroupAssoc1">
<field-map field-name="orderId" from-field="orderMap.orderId"/>
diff --git a/applications/order/servicedef/services.xml
b/applications/order/servicedef/services.xml
index 3ad4c59..76d5eb0 100644
--- a/applications/order/servicedef/services.xml
+++ b/applications/order/servicedef/services.xml
@@ -1567,8 +1567,8 @@ under the License.
</attribute>
</service>
- <service name="MoveItemBetweenShipGroups" engine="simple"
- location="component://order/minilang/order/OrderServices.xml"
invoke="MoveItemBetweenShipGroups">
+ <service name="moveItemBetweenShipGroups" engine="simple"
+ location="component://order/minilang/order/OrderServices.xml"
invoke="moveItemBetweenShipGroups">
<description>Move order items between ship groups</description>
<attribute name="orderId" type="String" mode="IN"/>
<attribute name="orderItemSeqId" type="String" mode="IN"/>
diff --git
a/applications/product/minilang/product/imagemanagement/ImageManagementServices.xml
b/applications/product/minilang/product/imagemanagement/ImageManagementServices.xml
index 5cf0d23..436c64d 100644
---
a/applications/product/minilang/product/imagemanagement/ImageManagementServices.xml
+++
b/applications/product/minilang/product/imagemanagement/ImageManagementServices.xml
@@ -21,7 +21,7 @@ under the License.
<simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://ofbiz.apache.org/Simple-Method"
xsi:schemaLocation="http://ofbiz.apache.org/Simple-Method
http://ofbiz.apache.org/dtds/simple-methods.xsd">
- <simple-method method-name="UploadProductImages" short-description="Method
to upload multiple images for product">
+ <simple-method method-name="uploadProductImages" short-description="Method
to upload multiple images for product">
<set-service-fields service-name="addMultipleuploadForProduct"
map="parameters" to-map="addAdditionalViewForProductMap"/>
<if-not-empty field="parameters._additionalImageOne_fileName">
<set field="addAdditionalViewForProductMap.productId"
from-field="parameters.productId"/>
diff --git a/applications/product/servicedef/services.xml
b/applications/product/servicedef/services.xml
index 203a971..ac7f217 100644
--- a/applications/product/servicedef/services.xml
+++ b/applications/product/servicedef/services.xml
@@ -1388,7 +1388,7 @@ under the License.
</service>
<service name="multipleUploadProductImages" engine="simple"
-
location="component://product/minilang/product/imagemanagement/ImageManagementServices.xml"
invoke="UploadProductImages" auth="true">
+
location="component://product/minilang/product/imagemanagement/ImageManagementServices.xml"
invoke="uploadProductImages" auth="true">
<description>Multiple upload Images For Product</description>
<permission-service service-name="genericContentPermission"
main-action="CREATE"/>
<attribute name="productId" type="String" mode="INOUT"
optional="false"/>