Author: ashish
Date: Wed Dec 17 10:49:41 2014 New Revision: 1646191 URL: http://svn.apache.org/r1646191 Log: Reverting r1646165. It seems that changes that we did for <property-to-field> are not needed. I will commit the new changes soon. Modified: ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/finaccount/FinAccountServices.xml ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/invoice/InvoiceServices.xml ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/payment/PaymentServices.xml ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/rate/RateServices.xml ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java ofbiz/trunk/applications/content/script/org/ofbiz/content/content/ContentServices.xml ofbiz/trunk/applications/content/script/org/ofbiz/content/data/DataServices.xml ofbiz/trunk/applications/order/script/org/ofbiz/order/order/OrderServices.xml ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/CategoryDetail.groovy ofbiz/trunk/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml ofbiz/trunk/applications/party/script/org/ofbiz/party/customer/CustomerEvents.xml ofbiz/trunk/applications/party/script/org/ofbiz/party/user/UserEvents.xml ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/FindLookUp.groovy ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml ofbiz/trunk/applications/product/script/org/ofbiz/product/cost/CostServices.xml ofbiz/trunk/applications/product/script/org/ofbiz/product/imagemanagement/ImageManagementServices.xml ofbiz/trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml ofbiz/trunk/applications/product/script/org/ofbiz/product/rental/RentalServices.xml ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/timesheet/TimesheetServices.xml ofbiz/trunk/framework/common/script/org/ofbiz/common/email/EmailServices.xml ofbiz/trunk/framework/common/src/org/ofbiz/common/email/EmailServices.java ofbiz/trunk/framework/entity/script/org/ofbiz/entity/test/EntityUtilPropertiesTests.xml ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtilProperties.java ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/LoginWorker.java ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/ServerHitBin.java ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/VisitHandler.java ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/actions/service/AvailableServices.groovy ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/CustomerEvents.xml ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/QuickAnonCustomerEvents.xml ofbiz/trunk/specialpurpose/googlebase/webapp/googlebase/WEB-INF/actions/autoUpdateConfig.groovy ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/PrepareXMLTemplate.xml ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/ShoppingCartServices.xml ofbiz/trunk/specialpurpose/ldap/src/org/ofbiz/ldap/LdapLoginWorker.java ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisInventoryServices.java ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisServices.java ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisShipmentServices.java ofbiz/trunk/specialpurpose/scrum/script/org/ofbiz/scrum/ScrumEvents.xml ofbiz/trunk/specialpurpose/scrum/script/org/ofbiz/scrum/ScrumServices.xml Modified: ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/finaccount/FinAccountServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/finaccount/FinAccountServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/finaccount/FinAccountServices.xml (original) +++ ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/finaccount/FinAccountServices.xml Wed Dec 17 10:49:41 2014 @@ -22,20 +22,8 @@ under the License. xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/simple-methods-v2.xsd"> <simple-method method-name="getArithmeticSettingsInline" short-description="getArithmeticSettingsInline"> - <call-class-method method-name="getPropertyValue" ret-field="roundingDecimals" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="arithmetic"/> - <string value="finaccount.decimals"/> - <string value="2"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="roundingMode" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="arithmetic"/> - <string value="finaccount.roundingSimpleMethod"/> - <string value="HalfUp"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="arithmetic" property="finaccount.decimals" field="roundingDecimals" default="2"/> + <property-to-field resource="arithmetic" property="finaccount.roundingSimpleMethod" field="roundingMode" default="HalfUp"/> <log level="verbose" message="Got settings from arithmetic.properties: roundingDecimals=${roundingDecimals}, roundingMode=${roundingMode}"/> </simple-method> @@ -59,12 +47,8 @@ under the License. <!-- set the currency if none is already set --> <if-empty field="newEntity.currencyUomId"> - <call-class-method method-name="getMessage" ret-field="defaultCurrency" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + + <property-to-field resource="general" property="currency.uom.id.default" field="defaultCurrency"/> <set field="newEntity.currencyUomId" from-field="defaultCurrency"/> </if-empty> @@ -710,13 +694,7 @@ under the License. </call-service> <set field="currencyUomId" from-field="partyAccountingPreference.baseCurrencyUomId"/> <if-empty field="currencyUomId"> - - <call-class-method method-name="getMessage" ret-field="currencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general" property="currency.uom.id.default" field="currencyUomId"/> </if-empty> <set field="finAccountTransRunningTotal" value="${groovy:org.ofbiz.base.util.UtilFormatOut.formatCurrency(runningTotal, currencyUomId, parameters.locale)}"/> <set field="endingBalance" value="${groovy:org.ofbiz.base.util.UtilFormatOut.formatCurrency(endingBalance, currencyUomId, parameters.locale)}"/> Modified: ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/invoice/InvoiceServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/invoice/InvoiceServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/invoice/InvoiceServices.xml (original) +++ ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/invoice/InvoiceServices.xml Wed Dec 17 10:49:41 2014 @@ -692,12 +692,7 @@ under the License. </call-service> <set field="currencyUomId" from-field="partyAccountingPreference.baseCurrencyUomId"/> <if-empty field="currencyUomId"> - <call-class-method method-name="getMessage" ret-field="currencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general" property="currency.uom.id.default" field="currencyUomId"/> </if-empty> <set field="invoiceRunningTotal" value="${groovy:org.ofbiz.base.util.UtilFormatOut.formatCurrency(runningTotal, currencyUomId, parameters.locale)}"/> <field-to-result field="invoiceRunningTotal"/> @@ -928,12 +923,7 @@ under the License. </entity-one> <set field="invoicePerShipment" from-field="orderHeader.invoicePerShipment"/> <if-empty field="invoicePerShipment"> - <call-class-method method-name="getMessage" ret-field="invoicePerShipment" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="AccountingConfig"/> - <string value="create.invoice.per.shipment"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="AccountingConfig" property="create.invoice.per.shipment" field="invoicePerShipment"/> </if-empty> <if-compare operator="equals" value="N" field="invoicePerShipment"> <entity-and list="orderItemBilling" entity-name="OrderItemBilling"> Modified: ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml (original) +++ ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml Wed Dec 17 10:49:41 2014 @@ -2849,20 +2849,8 @@ under the License. </simple-method> <simple-method method-name="getGlArithmeticSettingsInline" short-description="getGlArithmeticSettingsInline"> - <call-class-method method-name="getPropertyValue" ret-field="ledgerDecimals" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="arithmetic"/> - <string value="ledger.decimals"/> - <string value="4"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="roundingMode" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="arithmetic"/> - <string value="ledger.rounding"/> - <string value="HalfUp"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="arithmetic" property="ledger.decimals" field="ledgerDecimals" default="4"/> + <property-to-field resource="arithmetic" property="ledger.rounding" field="roundingMode" default="HalfUp"/> <log level="info" message="Got settings from arithmetic.properties: ledgerDecimals=${ledgerDecimals}, roundingMode=${roundingMode}"/> </simple-method> Modified: ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/payment/PaymentServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/payment/PaymentServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/payment/PaymentServices.xml (original) +++ ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/payment/PaymentServices.xml Wed Dec 17 10:49:41 2014 @@ -603,12 +603,7 @@ under the License. </call-service> <set field="currencyUomId" from-field="partyAccountingPreference.baseCurrencyUomId"/> <if-empty field="currencyUomId"> - <call-class-method method-name="getMessage" ret-field="currencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general" property="currency.uom.id.default" field="currencyUomId"/> </if-empty> <set field="paymentRunningTotal" value="${groovy:org.ofbiz.base.util.UtilFormatOut.formatCurrency(runningTotal, currencyUomId, parameters.locale)}"/> <field-to-result field="paymentRunningTotal"/> @@ -902,13 +897,7 @@ under the License. <entity-one value-field="orderHeader" entity-name="OrderHeader"/> <if-compare operator="equals" value="PURCHASE_ORDER" field="orderHeader.orderTypeId"> - <call-class-method method-name="getPropertyValue" ret-field="purchaseAutoCreate" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="AccountingConfig"/> - <string value="accounting.payment.purchaseorder.autocreate"/> - <string value="Y"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="AccountingConfig" property="accounting.payment.purchaseorder.autocreate" field="purchaseAutoCreate" default="Y"/> <if-compare operator="not-equals" value="Y" field="purchaseAutoCreate"> <log level="info" message="payment not created from approved order because config (accounting.payment.purchaseorder.autocreate) is not set to Y (AccountingConfig.properties)"/> <return/> @@ -916,13 +905,7 @@ under the License. </if-compare> <if-compare operator="equals" value="SALES_ORDER" field="orderHeader.orderTypeId"> - <call-class-method method-name="getPropertyValue" ret-field="salesAutoCreate" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="AccountingConfig"/> - <string value="accounting.payment.salesorder.autocreate"/> - <string value="Y"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="AccountingConfig" property="accounting.payment.salesorder.autocreate" field="salesAutoCreate" default="Y"/> <if-compare operator="not-equals" value="Y" field="salesAutoCreate"> <log level="info" message="payment not created from approved order because config (accounting.payment.salesorder.autocreate) is not set to Y (AccountingConfig.properties)"/> <return/> @@ -1056,13 +1039,7 @@ under the License. <simple-method method-name="createMatchingPaymentApplication" short-description="Create a payment application if either the invoice of payment could be found"> - <call-class-method method-name="getPropertyValue" ret-field="autoCreate" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="AccountingConfig"/> - <string value="accounting.payment.application.autocreate"/> - <string value="Y"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="AccountingConfig" property="accounting.payment.application.autocreate" field="autoCreate" default="Y"/> <if-compare operator="not-equals" value="Y" field="autoCreate"> <log level="info" message="payment application not automatically created because config is not set to Y"/> <return/> Modified: ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/rate/RateServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/rate/RateServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/rate/RateServices.xml (original) +++ ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/rate/RateServices.xml Wed Dec 17 10:49:41 2014 @@ -30,12 +30,7 @@ under the License. <!-- set defaults --> <if-empty field="parameters.rateCurrencyUomId"> - <call-class-method method-name="getMessage" ret-field="parameters.rateCurrencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general.properties"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general.properties" property="currency.uom.id.default" field="parameters.rateCurrencyUomId"/> </if-empty> <if-empty field="parameters.periodTypeId"> <set field="parameters.periodTypeId" value="RATE_HOUR"/> @@ -86,12 +81,7 @@ under the License. <!-- set defaults --> <if-empty field="parameters.rateCurrencyUomId"> - <call-class-method method-name="getMessage" ret-field="parameters.rateCurrencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general.properties"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general.properties" property="currency.uom.id.default" field="parameters.rateCurrencyUomId"/> </if-empty> <if-empty field="parameters.periodTypeId"> <set field="parameters.periodTypeId" value="RATE_HOUR"/> @@ -140,12 +130,7 @@ under the License. Then will be checked if the requested periodTypeId and currency can be found, if not isue an error message --> <if-empty field="parameters.rateCurrencyUomId"> - <call-class-method method-name="getMessage" ret-field="parameters.rateCurrencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general.properties"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general.properties" property="currency.uom.id.default" field="parameters.rateCurrencyUomId"/> </if-empty> <if-empty field="parameters.periodTypeId"> <set field="parameters.periodTypeId" value="RATE_HOUR"/> @@ -394,12 +379,7 @@ under the License. <set-nonpk-fields value-field="posRate" map="rateAmount"/> <set field="rateAmount.workeffortId" value="_NA_"/> <set field="rateAmount.partyId" value="_NA_"/> - <call-class-method method-name="getMessage" ret-field="rateAmount.rateCurrencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general.properties"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general.properties" property="currency.uom.id.default" field="rateAmount.rateCurrencyUomId"/> <create-value value-field="rateAmount"/> </iterate> <entity-condition entity-name="OldPartyRate" list="partyRates"/> Modified: ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java (original) +++ ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java Wed Dec 17 10:49:41 2014 @@ -865,7 +865,7 @@ public class CCPaymentServices { Element instructionsElement = UtilXml.addChildElement(engineDocElement, "Instructions", requestDocument); String pipeline = "PaymentNoFraud"; - if (EntityUtilProperties.propertyValueEqualsIgnoreCase(paymentConfig, "payment.clearcommerce.enableFraudShield", "Y", delegator)) { + if (UtilProperties.propertyValueEqualsIgnoreCase(paymentConfig, "payment.clearcommerce.enableFraudShield", "Y")) { pipeline = "Payment"; } UtilXml.addChildElementValue(instructionsElement, "Pipeline", pipeline, requestDocument); Modified: ofbiz/trunk/applications/content/script/org/ofbiz/content/content/ContentServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/content/script/org/ofbiz/content/content/ContentServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/content/script/org/ofbiz/content/content/ContentServices.xml (original) +++ ofbiz/trunk/applications/content/script/org/ofbiz/content/content/ContentServices.xml Wed Dec 17 10:49:41 2014 @@ -977,12 +977,7 @@ <set field="pubPtContentId" from-field="parameters.pubPtContentId"/> <call-object-method method-name="length" obj-field="parameters.textData" ret-field="textDataLen"/> <log level="info" message="textDataLen:${textDataLen}"/> - <call-class-method method-name="getMessage" ret-field="descriptLen" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="forum"/> - <string value="descriptLen"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="forum" property="descriptLen" field="descriptLen"/> <set field="descriptLen" from-field="descriptLen" type="Integer"/> <log level="info" message="descriptLen:${descriptLen}"/> <call-class-method method-name="min" class-name="java.lang.Math" ret-field="subStringLen"> Modified: ofbiz/trunk/applications/content/script/org/ofbiz/content/data/DataServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/content/script/org/ofbiz/content/data/DataServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/content/script/org/ofbiz/content/data/DataServices.xml (original) +++ ofbiz/trunk/applications/content/script/org/ofbiz/content/data/DataServices.xml Wed Dec 17 10:49:41 2014 @@ -561,12 +561,7 @@ under the License. <simple-method method-name="attachUploadToDataResource" short-description="Attach an uploaded file to a data resource"> <set field="isUpdate" value="false"/> - <call-class-method method-name="getMessage" ret-field="forceLocal" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="content.properties"/> - <string value="content.upload.always.local.file"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="content.properties" property="content.upload.always.local.file" field="forceLocal"/> <if> <condition> <!-- if (forceLocal && !("LOCAL_FILE".equals(parameters.dataResourceTypeId) || "OFBIZ_FILE".equals(parameters.dataResourceTypeId)) --> Modified: ofbiz/trunk/applications/order/script/org/ofbiz/order/order/OrderServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/script/org/ofbiz/order/order/OrderServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/order/script/org/ofbiz/order/order/OrderServices.xml (original) +++ ofbiz/trunk/applications/order/script/org/ofbiz/order/order/OrderServices.xml Wed Dec 17 10:49:41 2014 @@ -1392,12 +1392,7 @@ under the License. ]]></call-bsh> <set field="newAmount" from-field="parameters.amount" type="BigDecimal"/> <set field="shippingAmount" from-field="parameters.shippingAmount" type="BigDecimal"/> - <call-class-method method-name="getMessage" ret-field="percentAllowed" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="shipment"/> - <string value="shipment.default.cost_actual_over_estimated_percent_allowed"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field field="percentAllowed" resource="shipment" property="shipment.default.cost_actual_over_estimated_percent_allowed"/> <if-compare-field field="newAmount" operator="greater" to-field="shippingAmount" type="BigDecimal"> <set field="diffPercentage" value="${(newAmount - shippingAmount/shippingAmount)*100}" type="BigDecimal"/> <else> Modified: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/CategoryDetail.groovy URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/CategoryDetail.groovy?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/CategoryDetail.groovy (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/CategoryDetail.groovy Wed Dec 17 10:49:41 2014 @@ -39,7 +39,7 @@ viewIndex = parameters.VIEW_INDEX; currentCatalogId = CatalogWorker.getCurrentCatalogId(request); // set the default view size -defaultViewSize = request.getAttribute("defaultViewSize") ?: EntityUtilProperties.getPropertyValue("widget", "widget.form.defaultViewSize", "20", delegator); +defaultViewSize = request.getAttribute("defaultViewSize") ?: UtilProperties.getPropertyValue("widget", "widget.form.defaultViewSize", "20"); context.defaultViewSize = defaultViewSize; // set the limit view Modified: ofbiz/trunk/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml (original) +++ ofbiz/trunk/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml Wed Dec 17 10:49:41 2014 @@ -321,13 +321,7 @@ under the License. <set field="input.inputFields.infoString" from-field="parameters.address"/> <set field="caseInsensitive" from-field="parameters.caseInsensitive"/> <if-empty field="caseInsensitive"> - <call-class-method method-name="getPropertyValue" ret-field="caseInsensitive" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general.properties"/> - <string value="mail.address.caseInsensitive"/> - <string value="N"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general.properties" property="mail.address.caseInsensitive" field="caseInsensitive" default="N"/> </if-empty> <set field="input.inputFields.infoString_ic" from-field="caseInsensitive"/> <if-empty field="parameters.fromDate"> Modified: ofbiz/trunk/applications/party/script/org/ofbiz/party/customer/CustomerEvents.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/script/org/ofbiz/party/customer/CustomerEvents.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/party/script/org/ofbiz/party/customer/CustomerEvents.xml (original) +++ ofbiz/trunk/applications/party/script/org/ofbiz/party/customer/CustomerEvents.xml Wed Dec 17 10:49:41 2014 @@ -26,20 +26,9 @@ under the License. <set field="create_allow_password" value="false"/> <set field="default_customer_password" value="ungssblepsswd"/> - <call-class-method method-name="getPropertyValue" ret-field="username_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="username.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="password_lowercase" method-name="getPropertyValue" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="password.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="security" property="username.lowercase" default="false" field="username_lowercase"/> + <property-to-field resource="security" property="password.lowercase" default="false" field="password_lowercase"/> + <now-timestamp field="nowStamp"/> <set field="parameters.roleTypeId" value="CUSTOMER"/> Modified: ofbiz/trunk/applications/party/script/org/ofbiz/party/user/UserEvents.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/script/org/ofbiz/party/user/UserEvents.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/party/script/org/ofbiz/party/user/UserEvents.xml (original) +++ ofbiz/trunk/applications/party/script/org/ofbiz/party/user/UserEvents.xml Wed Dec 17 10:49:41 2014 @@ -35,20 +35,8 @@ under the License. <set field="require_login" value="false"/> <set field="create_allow_password" value="true"/> - <call-class-method method-name="getPropertyValue" ret-field="username_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="username.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="password_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="password.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="security" property="username.lowercase" default="false" field="username_lowercase"/> + <property-to-field resource="security" property="password.lowercase" default="false" field="password_lowercase"/> <now-timestamp field="nowStamp"/> <set field="parameters.roleTypeId" value="PROSPECT"/> @@ -61,20 +49,8 @@ under the License. <set field="require_login" value="true"/> <set field="create_allow_password" value="true"/> - <call-class-method method-name="getPropertyValue" ret-field="username_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="username.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="password_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="password.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="security" property="username.lowercase" default="false" field="username_lowercase"/> + <property-to-field resource="security" property="password.lowercase" default="false" field="password_lowercase"/> <now-timestamp field="nowStamp"/> <set field="parameters.roleTypeId" value="EMPLOYEE"/> @@ -82,20 +58,8 @@ under the License. </simple-method> <simple-method method-name="createUser" short-description="Create User" login-required="false"> - <call-class-method method-name="getPropertyValue" ret-field="username_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="username.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="password_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="password.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="security" property="username.lowercase" default="false" field="username_lowercase"/> + <property-to-field resource="security" property="password.lowercase" default="false" field="password_lowercase"/> <set field="default_user_password" value="ungssblepsswd"/> <now-timestamp field="nowStamp"/> @@ -359,11 +323,9 @@ under the License. <set-current-user-login value-field="newUserLogin"/> <!-- On successful user creation, create password history record if configured --> - <call-class-method method-name="getMessage" class-name="org.ofbiz.base.util.EntityUtilProperties" ret-field="autoPasswordChangeEnabled"> + <call-class-method method-name="getPropertyValue" class-name="org.ofbiz.base.util.UtilProperties" ret-field="autoPasswordChangeEnabled"> <string value="security"/> <string value="user.auto.change.password.enable"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> </call-class-method> <if-compare-field field="autoPasswordChangeEnabled" operator="equals" to-field="true"> <call-class-method method-name="createUserLoginPasswordHistory" class-name="org.ofbiz.common.login.LoginServices"> Modified: ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/FindLookUp.groovy URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/FindLookUp.groovy?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/FindLookUp.groovy (original) +++ ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/FindLookUp.groovy Wed Dec 17 10:49:41 2014 @@ -19,13 +19,12 @@ import org.ofbiz.base.util.*; import org.ofbiz.entity.condition.*; -import org.ofbiz.entity.util.EntityUtilProperties; if (context.noConditionFind == null) { context.noConditionFind = parameters.noConditionFind; } if (context.noConditionFind == null) { - context.noConditionFind = EntityUtilProperties.getPropertyValue("widget", "widget.defaultNoConditionFind", delegator); + context.noConditionFind = UtilProperties.getPropertyValue("widget", "widget.defaultNoConditionFind"); } if (context.filterByDate == null) { context.filterByDate = parameters.filterByDate; Modified: ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml (original) +++ ofbiz/trunk/applications/product/script/org/ofbiz/product/catalog/CatalogServices.xml Wed Dec 17 10:49:41 2014 @@ -25,12 +25,7 @@ under the License. <if-not-empty field="parameters.topCategory"> <set field="defaultTopCategoryId" from-field="parameters.topCategory"/> <else> - <call-class-method method-name="getMessage" ret-field="defaultTopCategoryId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="catalog"/> - <string value="top.category.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field property="top.category.default" field="defaultTopCategoryId" resource="catalog"/> </else> </if-not-empty> <!-- set field="productCategoryContext.productCategoryId" from-field="defaultTopCategoryId"/> Modified: ofbiz/trunk/applications/product/script/org/ofbiz/product/cost/CostServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/script/org/ofbiz/product/cost/CostServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/product/script/org/ofbiz/product/cost/CostServices.xml (original) +++ ofbiz/trunk/applications/product/script/org/ofbiz/product/cost/CostServices.xml Wed Dec 17 10:49:41 2014 @@ -555,20 +555,8 @@ under the License. <set field="oldProductQuantity" value="${quantityOnHandTotal - parameters.quantityAccepted}" type="BigDecimal"/> <set field="productAverageCostMap.averageCost" value="${((productAverageCost.averageCost * oldProductQuantity) + (inventoryItem.unitCost * parameters.quantityAccepted))/(quantityOnHandTotal)}" type="BigDecimal"/> - <call-class-method method-name="getPropertyValue" ret-field="roundingDecimals" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="arithmetic"/> - <string value="finaccount.decimals"/> - <string value="2"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="roundingMode" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="arithmetic"/> - <string value="finaccount.roundingSimpleMethod"/> - <string value="HalfUp"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="arithmetic" property="finaccount.decimals" field="roundingDecimals" default="2"/> + <property-to-field resource="arithmetic" property="finaccount.roundingSimpleMethod" field="roundingMode" default="HalfUp"/> <calculate field="productAverageCostMap.averageCost" type="BigDecimal" decimal-scale="${roundingDecimals}" rounding-mode="${roundingMode}"> <calcop operator="get" field="productAverageCostMap.averageCost"/> </calculate> Modified: ofbiz/trunk/applications/product/script/org/ofbiz/product/imagemanagement/ImageManagementServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/script/org/ofbiz/product/imagemanagement/ImageManagementServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/product/script/org/ofbiz/product/imagemanagement/ImageManagementServices.xml (original) +++ ofbiz/trunk/applications/product/script/org/ofbiz/product/imagemanagement/ImageManagementServices.xml Wed Dec 17 10:49:41 2014 @@ -251,19 +251,8 @@ under the License. if (statusId) return statusId[0]; }"/> - <call-class-method method-name="getMessage" ret-field="autoApproveImage" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="catalog.properties"/> - <string value="image.management.autoApproveImage"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getMessage" ret-field="multipleApproval" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="catalog.properties"/> - <string value="image.management.multipleApproval"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - + <property-to-field resource="catalog.properties" property="image.management.autoApproveImage" field="autoApproveImage"/> + <property-to-field resource="catalog.properties" property="image.management.multipleApproval" field="multipleApproval"/> <if-compare field="autoApproveImage" operator="equals" value="Y"> <entity-and entity-name="ContentApproval" list="contentApprovals"> <field-map field-name="contentId" from-field="parameters.contentId"/> Modified: ofbiz/trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml (original) +++ ofbiz/trunk/applications/product/script/org/ofbiz/product/inventory/InventoryServices.xml Wed Dec 17 10:49:41 2014 @@ -239,12 +239,7 @@ under the License. </call-service> <set field="inventoryItem.currencyUomId" from-field="accPref.baseCurrencyUomId"/> <if-empty field="inventoryItem.currencyUomId"> - <call-class-method method-name="getMessage" ret-field="inventoryItem.currencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general" property="currency.uom.id.default" field="inventoryItem.currencyUomId"/> </if-empty> <!-- if inventoryItem's currencyUomId is still empty, return an error message --> <if-empty field="inventoryItem.currencyUomId"> Modified: ofbiz/trunk/applications/product/script/org/ofbiz/product/rental/RentalServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/script/org/ofbiz/product/rental/RentalServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/product/script/org/ofbiz/product/rental/RentalServices.xml (original) +++ ofbiz/trunk/applications/product/script/org/ofbiz/product/rental/RentalServices.xml Wed Dec 17 10:49:41 2014 @@ -22,12 +22,7 @@ under the License. xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/simple-methods-v2.xsd"> <simple-method method-name="createFixedAssetAndLinkToProduct" short-description="Create an FixedAsset and link the asset to the product, used when a asset usage product is created"> - <call-class-method method-name="getMessage" ret-field="autoCreate" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="AccountingConfig"/> - <string value="accounting.fixedasset.autocreate"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field field="autoCreate" resource="AccountingConfig" property="accounting.fixedasset.autocreate" no-locale="true"/> <if-compare field="autoCreate" value="Y" operator="not-equals"> <return/> </if-compare> Modified: ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/timesheet/TimesheetServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/timesheet/TimesheetServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/timesheet/TimesheetServices.xml (original) +++ ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/timesheet/TimesheetServices.xml Wed Dec 17 10:49:41 2014 @@ -143,24 +143,13 @@ under the License. <field-map field-name="partyId" value="${invoice.partyId}"/> </entity-one> <if-empty field="party.preferredCurrencyUomId"> - <call-class-method method-name="getMessage" ret-field="party.preferredCurrencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general" property="currency.uom.id.default" field="party.preferredCurrencyUomId"/> </if-empty> <set field="updateInvoiceMap.invoiceId" from-field="parameters.invoiceId"/> <set field="updateInvoiceMap.currencyUomId" from-field="party.preferredCurrencyUomId"/> <now-timestamp field="updateInvoiceMap.invoiceDate"/> <if-empty field="updateInvoiceMap.currencyUomId"> - <call-class-method method-name="getPropertyValue" ret-field="invoice.currencyUomId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="currency.uom.id.default"/> - <string value="USD"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field field="invoice.currencyUomId" resource="general" property="currency.uom.id.default" default="USD"/> </if-empty> <call-service service-name="updateInvoice" in-map-name="updateInvoiceMap"/> <entity-one entity-name="Invoice" value-field="invoice"/> Modified: ofbiz/trunk/framework/common/script/org/ofbiz/common/email/EmailServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/script/org/ofbiz/common/email/EmailServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/common/script/org/ofbiz/common/email/EmailServices.xml (original) +++ ofbiz/trunk/framework/common/script/org/ofbiz/common/email/EmailServices.xml Wed Dec 17 10:49:41 2014 @@ -51,13 +51,7 @@ under the License. <if-not-empty field="emailTemplateSetting.fromAddress"> <set field="emailParams.sendFrom" from-field="emailTemplateSetting.fromAddress"/> <else> - <call-class-method method-name="getPropertyValue" ret-field="emailParams.sendFrom" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="defaultFromEmailAddress"/> - <string value="[hidden email]"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general" property="defaultFromEmailAddress" field="emailParams.sendFrom" default="[hidden email]"/> </else> </if-not-empty> <set field="emailParams.sendCc" from-field="emailTemplateSetting.ccAddress"/> Modified: ofbiz/trunk/framework/common/src/org/ofbiz/common/email/EmailServices.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/src/org/ofbiz/common/email/EmailServices.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/common/src/org/ofbiz/common/email/EmailServices.java (original) +++ ofbiz/trunk/framework/common/src/org/ofbiz/common/email/EmailServices.java Wed Dec 17 10:49:41 2014 @@ -238,7 +238,7 @@ public class EmailServices { } session = Session.getInstance(props); - boolean debug = EntityUtilProperties.propertyValueEqualsIgnoreCase("general.properties", "mail.debug.on", "Y", delegator); + boolean debug = UtilProperties.propertyValueEqualsIgnoreCase("general.properties", "mail.debug.on", "Y"); session.setDebug(debug); mail = new MimeMessage(session); Modified: ofbiz/trunk/framework/entity/script/org/ofbiz/entity/test/EntityUtilPropertiesTests.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/entity/script/org/ofbiz/entity/test/EntityUtilPropertiesTests.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/entity/script/org/ofbiz/entity/test/EntityUtilPropertiesTests.xml (original) +++ ofbiz/trunk/framework/entity/script/org/ofbiz/entity/test/EntityUtilPropertiesTests.xml Wed Dec 17 10:49:41 2014 @@ -36,20 +36,10 @@ under the License. </call-class-method> <assert><if-compare field="defaultFromEmailAddress" operator="equals" value="[hidden email]"></if-compare></assert> - <call-class-method method-name="getMessage" ret-field="currencyUomIdDefault" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="currency.uom.id.default"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general" property="currency.uom.id.default" field="currencyUomIdDefault"/> <assert><if-compare field="currencyUomIdDefault" operator="equals" value="THB"></if-compare></assert> - <call-class-method method-name="getMessage" ret-field="defaultFromEmailAddress" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="general"/> - <string value="defaultFromEmailAddress"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="general" property="defaultFromEmailAddress" field="defaultFromEmailAddress"/> <assert><if-compare field="defaultFromEmailAddress" operator="equals" value="[hidden email]"></if-compare></assert> </simple-method> </simple-methods> Modified: ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtilProperties.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtilProperties.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtilProperties.java (original) +++ ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtilProperties.java Wed Dec 17 10:49:41 2014 @@ -88,19 +88,6 @@ public class EntityUtilProperties implem } return value; } - - public static String getPropertyValue(String resource, String name, String defaultValue, Locale locale, Delegator delegator) { - String value = getSystemPropertyValue(resource, name, delegator); - if (UtilValidate.isEmpty(value)) { - if (UtilValidate.isNotEmpty(locale)) { - value = UtilProperties.getMessage(resource, name, locale); - } - if (UtilValidate.isEmpty(value)) { - value = UtilProperties.getPropertyValue(resource, name, defaultValue); - } - } - return value; - } public static double getPropertyNumber(String resource, String name, double defaultValue) { return UtilProperties.getPropertyNumber(resource, name, defaultValue); Modified: ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/LoginWorker.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/LoginWorker.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/LoginWorker.java (original) +++ ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/LoginWorker.java Wed Dec 17 10:49:41 2014 @@ -237,7 +237,7 @@ public class LoginWorker { // check if they have permission for this login attempt; if not log them out if (userLogin != null) { List<Object> errorMessageList = UtilGenerics.checkList(request.getAttribute("_ERROR_MESSAGE_LIST")); - if (!hasBasePermission(userLogin, request) || isFlaggedLoggedOut(userLogin, userLogin.getDelegator())) { + if (!hasBasePermission(userLogin, request) || isFlaggedLoggedOut(userLogin)) { if (errorMessageList == null) { errorMessageList = new LinkedList<Object>(); request.setAttribute("_ERROR_MESSAGE_LIST", errorMessageList); @@ -1066,8 +1066,8 @@ public class LoginWorker { return "success"; } - public static boolean isFlaggedLoggedOut(GenericValue userLogin, Delegator delegator) { - if ("true".equalsIgnoreCase(EntityUtilProperties.getPropertyValue("security.properties", "login.disable.global.logout", delegator))) { + public static boolean isFlaggedLoggedOut(GenericValue userLogin) { + if ("true".equalsIgnoreCase(UtilProperties.getPropertyValue("security.properties", "login.disable.global.logout"))) { return false; } if (userLogin == null || userLogin.get("userLoginId") == null) { Modified: ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java (original) +++ ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java Wed Dec 17 10:49:41 2014 @@ -71,6 +71,8 @@ import org.python.modules.re; public class RequestHandler { public static final String module = RequestHandler.class.getName(); + private static final boolean throwRequestHandlerExceptionOnMissingLocalRequest = UtilProperties.propertyValueEqualsIgnoreCase( + "requestHandler.properties", "throwRequestHandlerExceptionOnMissingLocalRequest", "Y"); private final String defaultStatusCodeString = UtilProperties.getPropertyValue("requestHandler.properties", "status-code", "302"); private final ViewFactory viewFactory; private final EventFactory eventFactory; @@ -129,8 +131,6 @@ public class RequestHandler { public void doRequest(HttpServletRequest request, HttpServletResponse response, String chain, GenericValue userLogin, Delegator delegator) throws RequestHandlerException, RequestHandlerExceptionAllowExternalRequests { - final boolean throwRequestHandlerExceptionOnMissingLocalRequest = EntityUtilProperties.propertyValueEqualsIgnoreCase( - "requestHandler.properties", "throwRequestHandlerExceptionOnMissingLocalRequest", "Y", delegator); long startTime = System.currentTimeMillis(); HttpSession session = request.getSession(); @@ -280,7 +280,7 @@ public class RequestHandler { } } if (enableHttps == null) { - enableHttps = EntityUtilProperties.propertyValueEqualsIgnoreCase("url.properties", "port.https.enabled", "Y", delegator); + enableHttps = UtilProperties.propertyValueEqualsIgnoreCase("url.properties", "port.https.enabled", "Y"); } if (Boolean.FALSE.equals(enableHttps)) { @@ -1024,11 +1024,11 @@ public class RequestHandler { @Deprecated public static String getDefaultServerRootUrl(HttpServletRequest request, boolean secure) { Delegator delegator = (Delegator) request.getAttribute("delegator"); - String httpsPort = EntityUtilProperties.getPropertyValue("url.properties", "port.https", "443", delegator); - String httpsServer = EntityUtilProperties.getPropertyValue("url.properties", "force.https.host", delegator); - String httpPort = EntityUtilProperties.getPropertyValue("url.properties", "port.http", "80", delegator); - String httpServer = EntityUtilProperties.getPropertyValue("url.properties", "force.http.host", delegator); - boolean useHttps = EntityUtilProperties.propertyValueEqualsIgnoreCase("url.properties", "port.https.enabled", "Y", delegator); + String httpsPort = UtilProperties.getPropertyValue("url.properties", "port.https", "443"); + String httpsServer = UtilProperties.getPropertyValue("url.properties", "force.https.host"); + String httpPort = UtilProperties.getPropertyValue("url.properties", "port.http", "80"); + String httpServer = UtilProperties.getPropertyValue("url.properties", "force.http.host"); + boolean useHttps = UtilProperties.propertyValueEqualsIgnoreCase("url.properties", "port.https.enabled", "Y"); if (Start.getInstance().getConfig().portOffset != 0) { Integer httpPortValue = Integer.valueOf(httpPort); Modified: ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/ServerHitBin.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/ServerHitBin.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/ServerHitBin.java (original) +++ ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/ServerHitBin.java Wed Dec 17 10:49:41 2014 @@ -37,7 +37,6 @@ import org.ofbiz.entity.GenericEntityExc import org.ofbiz.entity.GenericValue; import org.ofbiz.entity.model.ModelEntity; import org.ofbiz.entity.util.EntityQuery; -import org.ofbiz.entity.util.EntityUtilProperties; import com.ibm.icu.util.Calendar; @@ -214,7 +213,7 @@ public class ServerHitBin { // put the copy at the first of the list, then put this object back on if (bin.getNumberHits() > 0) { // persist each bin when time ends if option turned on - if (EntityUtilProperties.propertyValueEqualsIgnoreCase("serverstats", "stats.persist." + ServerHitBin.typeIds[type] + ".bin", "true", delegator)) { + if (UtilProperties.propertyValueEqualsIgnoreCase("serverstats", "stats.persist." + ServerHitBin.typeIds[type] + ".bin", "true")) { GenericValue serverHitBin = delegator.makeValue("ServerHitBin"); serverHitBin.set("contentId", bin.id); serverHitBin.set("hitTypeId", ServerHitBin.typeIds[bin.type]); @@ -466,8 +465,7 @@ public class ServerHitBin { private void saveHit(HttpServletRequest request, long startTime, long runningTime, GenericValue userLogin) throws GenericEntityException { // persist record of hit in ServerHit entity if option turned on - Delegator delegator = (Delegator) request.getAttribute("delegator"); - if (EntityUtilProperties.propertyValueEqualsIgnoreCase("serverstats", "stats.persist." + ServerHitBin.typeIds[type] + ".hit", "true", delegator)) { + if (UtilProperties.propertyValueEqualsIgnoreCase("serverstats", "stats.persist." + ServerHitBin.typeIds[type] + ".hit", "true")) { // if the hit type is ENTITY and the name contains "ServerHit" don't // persist; avoids the infinite loop and a bunch of annoying data if (this.type == ENTITY && this.id.indexOf("ServerHit") > 0) { Modified: ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/VisitHandler.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/VisitHandler.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/VisitHandler.java (original) +++ ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/stats/VisitHandler.java Wed Dec 17 10:49:41 2014 @@ -36,7 +36,6 @@ import org.ofbiz.entity.GenericEntityExc import org.ofbiz.entity.GenericValue; import org.ofbiz.entity.model.ModelEntity; import org.ofbiz.entity.util.EntityQuery; -import org.ofbiz.entity.util.EntityUtilProperties; /** * Handles saving and maintaining visit information @@ -205,8 +204,7 @@ public class VisitHandler { public static GenericValue getVisitor(HttpServletRequest request, HttpServletResponse response) { // this defaults to true: ie if anything but "false" it will be true - Delegator delegator = (Delegator) request.getAttribute("delegator"); - if (!EntityUtilProperties.propertyValueEqualsIgnoreCase("serverstats", "stats.persist.visitor", "false", delegator)) { + if (!UtilProperties.propertyValueEqualsIgnoreCase("serverstats", "stats.persist.visitor", "false")) { HttpSession session = request.getSession(); GenericValue visitor = (GenericValue) session.getAttribute("visitor"); @@ -214,6 +212,7 @@ public class VisitHandler { synchronized (session) { visitor = (GenericValue) session.getAttribute("visitor"); if (visitor == null) { + Delegator delegator = (Delegator) request.getAttribute("delegator"); String delegatorName = (String) session.getAttribute("delegatorName"); if (delegator == null && UtilValidate.isNotEmpty(delegatorName)) { Modified: ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/actions/service/AvailableServices.groovy URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/actions/service/AvailableServices.groovy?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/actions/service/AvailableServices.groovy (original) +++ ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/actions/service/AvailableServices.groovy Wed Dec 17 10:49:41 2014 @@ -28,7 +28,6 @@ import org.ofbiz.service.ModelPermission import org.ofbiz.service.ServiceContainer; import org.ofbiz.base.util.UtilHttp; import org.ofbiz.base.util.UtilProperties; -import org.ofbiz.entity.util.EntityUtilProperties; List getEcaListForService(String selectedService) { ecaMap = org.ofbiz.service.eca.ServiceEcaUtil.getServiceEventMap(selectedService); @@ -477,7 +476,7 @@ if (selectedService) { if (showWsdl?.equals("true")) { try { - wsdl = curServiceModel.toWSDL("http://${request.getServerName()}:${EntityUtilProperties.getPropertyValue("url.properties", "port.http", "80", delegator)}${parameters._CONTROL_PATH_}/SOAPService"); + wsdl = curServiceModel.toWSDL("http://${request.getServerName()}:${UtilProperties.getPropertyValue("url.properties", "port.http", "80")}${parameters._CONTROL_PATH_}/SOAPService"); curServiceMap.wsdl = UtilXml.writeXmlDocument(wsdl); } catch (WSDLException ex) { curServiceMap.wsdl = ex.getLocalizedMessage(); Modified: ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/CustomerEvents.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/CustomerEvents.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/CustomerEvents.xml (original) +++ ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/CustomerEvents.xml Wed Dec 17 10:49:41 2014 @@ -35,20 +35,9 @@ under the License. <set field="defaultPassword" value="ungssblepswd"/> </if-empty> - <call-class-method method-name="getPropertyValue" ret-field="username_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="username.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="password_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="password.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="security" property="username.lowercase" default="false" field="username_lowercase"/> + <property-to-field resource="security" property="password.lowercase" default="false" field="password_lowercase"/> + <now-timestamp field="nowStamp"/> <set value="CUSTOMER" field="parameters.roleTypeId"/> Modified: ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/QuickAnonCustomerEvents.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/QuickAnonCustomerEvents.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/QuickAnonCustomerEvents.xml (original) +++ ofbiz/trunk/specialpurpose/ecommerce/script/org/ofbiz/ecommerce/customer/QuickAnonCustomerEvents.xml Wed Dec 17 10:49:41 2014 @@ -36,19 +36,8 @@ under the License. <set field="parameters.roleTypeId" value="CUSTOMER"/> - <call-class-method method-name="getPropertyValue" ret-field="username_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="username.lowercase"/> - <string value="false"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getPropertyValue" ret-field="password_lowercase" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="security"/> - <string value="password.lowercase"/> - <string value="false"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="security" property="username.lowercase" default="false" field="username_lowercase"/> + <property-to-field resource="security" property="password.lowercase" default="false" field="password_lowercase"/> <set field="default_user_password" value="ungssblepsswd"/> <now-timestamp field="nowStamp"/> @@ -356,12 +345,11 @@ under the License. <set field="faxPhoneContext.partyId" from-field="partyId"/> <set field="mobilePhoneContext.partyId" from-field="partyId"/> <set field="emailContext.partyId" from-field="partyId"/> - <set field="delegator" type="org.ofbiz.entity.Delegator"/> <if-not-empty field="newUserLogin"> <!-- If password encryption is enabled, encrpyt it now --> <call-bsh><![CDATA[ - boolean useEncryption = "true".equals(org.ofbiz.entity.util.EntityUtilProperties.getPropertyValue("security", "password.encrypt", delegator)); + boolean useEncryption = "true".equals(org.ofbiz.base.util.UtilProperties.getPropertyValue("security", "password.encrypt")); if (useEncryption) { newUserLogin.set("currentPassword", org.ofbiz.base.crypto.HashCrypt.getDigestHash((String) newUserLogin.get("currentPassword"))); } ]]></call-bsh> <!-- create the UserLogin manually to get around ordering and security constraints in the service --> Modified: ofbiz/trunk/specialpurpose/googlebase/webapp/googlebase/WEB-INF/actions/autoUpdateConfig.groovy URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/googlebase/webapp/googlebase/WEB-INF/actions/autoUpdateConfig.groovy?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/googlebase/webapp/googlebase/WEB-INF/actions/autoUpdateConfig.groovy (original) +++ ofbiz/trunk/specialpurpose/googlebase/webapp/googlebase/WEB-INF/actions/autoUpdateConfig.groovy Wed Dec 17 10:49:41 2014 @@ -17,30 +17,30 @@ * under the License. */ import javolution.util.FastList -import org.ofbiz.entity.util.EntityUtilProperties +import org.ofbiz.base.util.UtilProperties configList = [] -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStoreId", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStoreId") productStoreIds = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.option.outOfStock", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.option.outOfStock") outOfStock = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.option.backInStock", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.option.backInStock") backInStock = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.webSiteUrl", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.webSiteUrl") webSiteUrl = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.actionType", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.actionType") actionType = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.statusId", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.statusId") statusId = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.testMode", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.testMode") testMode = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.webSiteMountPoint", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.webSiteMountPoint") webSiteMountPoint = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.countryCode", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.countryCode") countryCode = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.trackingCodeId", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.trackingCodeId") trackingCodeId = str.split(",") -str = EntityUtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.allowRecommended", delegator) +str = UtilProperties.getPropertyValue("autoUpdateToGoogleBase.properties", "autoUpdateGoogleBase.productStore.allowRecommended") allowRecommended = str.split(",") productStoreIds.eachWithIndex{ productStoreId, i -> Modified: ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/PrepareXMLTemplate.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/PrepareXMLTemplate.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/PrepareXMLTemplate.xml (original) +++ ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/PrepareXMLTemplate.xml Wed Dec 17 10:49:41 2014 @@ -66,42 +66,17 @@ </simple-method> <simple-method method-name="createRequestUrl" short-description="" login-required="false"> <!-- Setup Url spec --> - <call-class-method method-name="getMessage" ret-field="basePostUrl" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="basePostUrl"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getMessage" ret-field="merchantId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="merchantId"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getMessage" ret-field="request" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="request"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="googleCheckout" property="basePostUrl" field="basePostUrl"/> + <property-to-field resource="googleCheckout" property="merchantId" field="merchantId"/> + <property-to-field resource="googleCheckout" property="request" field="request"/> <set field="urlSpec" value="${basePostUrl}${merchantId}"/> <create-object class-name="java.net.URL" field="url"> <field field="urlSpec"/> </create-object> </simple-method> <simple-method method-name="getHttpAuth" short-description="" login-required="false"> - <call-class-method method-name="getMessage" ret-field="merchantId" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="merchantId"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getMessage" ret-field="merchantKey" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="merchantKey"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="googleCheckout" property="merchantId" field="merchantId"/> + <property-to-field resource="googleCheckout" property="merchantKey" field="merchantKey"/> <set field="userNameAndPass" value="${merchantId}:${merchantKey}"/> <call-class-method method-name="base64Encode" class-name="org.ofbiz.base.util.Base64" ret-field="encodedValue"> <field field="userNameAndPass"/> @@ -141,12 +116,7 @@ <field field="xhtmlStringRenderer" type="org.ofbiz.widget.screen.ScreenStringRenderer"/> </create-object> <!-- get uri --> - <call-class-method method-name="getMessage" ret-field="screenUri" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="xmlTemplateUri"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="googleCheckout" property="xmlTemplateUri" field="screenUri"/> <call-object-method method-name="render" obj-field="xscreens"> <field field="screenUri" type="String"/> </call-object-method> Modified: ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/ShoppingCartServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/ShoppingCartServices.xml?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/ShoppingCartServices.xml (original) +++ ofbiz/trunk/specialpurpose/googlecheckout/script/org/ofbiz/googleCheckout/ShoppingCartServices.xml Wed Dec 17 10:49:41 2014 @@ -45,24 +45,9 @@ </simple-method> <simple-method method-name="createCheckoutFlowSupport" short-description="" login-required="false"> - <call-class-method method-name="getMessage" ret-field="flowSupport.editCartUrl" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="editCartUrl"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getMessage" ret-field="flowSupport.continueShoppingUrl" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="continueShoppingUrl"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> - <call-class-method method-name="getMessage" ret-field="flowSupport.requestPhone" class-name="org.ofbiz.entity.util.EntityUtilProperties"> - <string value="googleCheckout"/> - <string value="requestPhone"/> - <field field="locale" type="java.util.Locale"/> - <field field="delegator" type="org.ofbiz.entity.Delegator"/> - </call-class-method> + <property-to-field resource="googleCheckout" property="editCartUrl" field="flowSupport.editCartUrl"/> + <property-to-field resource="googleCheckout" property="continueShoppingUrl" field="flowSupport.continueShoppingUrl"/> + <property-to-field resource="googleCheckout" property="requestPhone" field="flowSupport.requestPhone"/> <call-simple-method method-name="getTaxTables"/> <set field="flowSupport.taxTables" from-field="taxTables"/> Modified: ofbiz/trunk/specialpurpose/ldap/src/org/ofbiz/ldap/LdapLoginWorker.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ldap/src/org/ofbiz/ldap/LdapLoginWorker.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/ldap/src/org/ofbiz/ldap/LdapLoginWorker.java (original) +++ ofbiz/trunk/specialpurpose/ldap/src/org/ofbiz/ldap/LdapLoginWorker.java Wed Dec 17 10:49:41 2014 @@ -94,7 +94,7 @@ public class LdapLoginWorker extends Log } } - if (!hasBasePermission(userLogin, request) || isFlaggedLoggedOut(userLogin, userLogin.getDelegator()) || hasLdapLoggedOut) { + if (!hasBasePermission(userLogin, request) || isFlaggedLoggedOut(userLogin) || hasLdapLoggedOut) { Debug.logInfo("User does not have permission or is flagged as logged out", module); doBasicLogout(userLogin, request, response); userLogin = null; Modified: ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisInventoryServices.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisInventoryServices.java?rev=1646191&r1=1646190&r2=1646191&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisInventoryServices.java (original) +++ ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisInventoryServices.java Wed Dec 17 10:49:41 2014 @@ -59,7 +59,7 @@ public class OagisInventoryServices { public static final String resource = "OagisUiLabels"; public static final Double doubleZero = new Double(0.0); public static final Double doubleOne = new Double(1.0); - + public static final String syncInventoryFacilityId = UtilProperties.getPropertyValue("oagis.properties", "Oagis.Warehouse.SyncInventoryFacilityId"); public static Map<String, Object> oagisReceiveSyncInventory(DispatchContext ctx, Map<String, Object> context) { Document doc = (Document) context.get("document"); @@ -69,7 +69,7 @@ public class OagisInventoryServices { Locale locale = (Locale) context.get("locale"); List<Map<String, String>> errorMapList = FastList.newInstance(); List<Map<String, Object>> inventoryMapList = FastList.newInstance(); - final String syncInventoryFacilityId = EntityUtilProperties.getPropertyValue("oagis.properties", "Oagis.Warehouse.SyncInventoryFacilityId", delegator); + GenericValue userLogin = null; try { userLogin = EntityQuery.use(delegator).from("UserLogin").where("userLoginId", "system").queryOne(); |
Free forum by Nabble | Edit this page |