You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ofbiz.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2026/10/07 19:48:00 UTC
[jira] [Commented] (OFBIZ-13655) Converted Groovy scripts read configuration with UtilProperties, ignoring SystemProperty overrides the original mini-lang honoured
[ https://issues.apache.org/jira/browse/OFBIZ-13655?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18124698#comment-18124698 ]
ASF subversion and git services commented on OFBIZ-13655:
---------------------------------------------------------
Commit 617066ac564076a0074f4e17f390e7aa183e57d1 in ofbiz-framework's branch refs/heads/trunk from Mridul Pathak
[ https://gitbox.apache.org/repos/asf?p=ofbiz-framework.git;h=617066ac56 ]
Fixed: Converted Groovy scripts read configuration with UtilProperties, ignoring SystemProperty overrides the original mini-lang honoured (OFBIZ-13655)
The mini-lang <property-to-field> resolved properties through EntityUtilProperties, which checks the SystemProperty table before the .properties file. The converted scripts called UtilProperties directly, so a SystemProperty value was silently ignored. Read through EntityUtilProperties.getPropertyValue(..., delegator) instead:
- DataServicesScript: content.upload.always.local.file
- ImageManagementServicesScript: image.management.autoApproveImage and image.management.multipleApproval
- EmailServicesScript: defaultFromEmailAddress
- CostServices: finaccount.decimals and finaccount.roundingGroovyMethod
- PaymentServices, RateServices, InventoryServicesScript: currency.uom.id.default
- OrderServicesScript: shipment.default.cost_actual_over_estimated_percent_allowed
> Converted Groovy scripts read configuration with UtilProperties, ignoring SystemProperty overrides the original mini-lang honoured
> ----------------------------------------------------------------------------------------------------------------------------------
>
> Key: OFBIZ-13655
> URL: https://issues.apache.org/jira/browse/OFBIZ-13655
> Project: OFBiz
> Issue Type: Bug
> Components: accounting, content, framework/common, order, product
> Affects Versions: Upcoming Branch, 24.09.07
> Reporter: Mridul Pathak
> Assignee: Mridul Pathak
> Priority: Major
>
> The mini-lang {{<property-to-field>}} resolved properties through {{EntityUtilProperties}}, which checks the {{SystemProperty}} table before the {{.properties}} file. The converted scripts call {{UtilProperties}} directly, so a SystemProperty value is silently ignored. Resolve by reading via {{EntityUtilProperties.getPropertyValue(resource, name, default, delegator)}}, converting types by hand (the typed {{EntityUtilProperties.getPropertyAs*}} variants take no delegator and would not help).
> *Properties with seed rows loaded by default*
> * {{DataServicesScript}}: {{content.upload.always.local.file}}
> * {{ImageManagementServicesScript}}: {{image.management.autoApproveImage}}, {{image.management.multipleApproval}}
> *Other affected reads*
> * {{EmailServicesScript}}: {{general#defaultFromEmailAddress}}
> * {{CostServices}}: {{arithmetic#finaccount.decimals}}, {{finaccount.roundingGroovyMethod}}
> * {{PaymentServices}}, {{RateServices}}, {{InventoryServicesScript}}: {{general#currency.uom.id.default}}
> * {{OrderServicesScript}} (trunk only): {{shipment.default.cost_actual_over_estimated_percent_allowed}}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)