This is an automated email from the ASF dual-hosted git repository.
mridulpathak 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 74b2fa1137 Fixed: Mini-lang to Groovy regressions in
ShoppingListServicesScript (OFBIZ-13579)
74b2fa1137 is described below
commit 74b2fa11375a112baa8a65a41c87929c48c520ba
Author: Mridul Pathak <[email protected]>
AuthorDate: Sun Sep 13 23:15:59 2026 +0530
Fixed: Mini-lang to Groovy regressions in ShoppingListServicesScript
(OFBIZ-13579)
- addSuggestionsToShoppingList: read shoppingListId from
createShoppingList's result instead of the nonexistent serviceResult field, so
the newly created "Auto Suggestions" list is actually linked instead of always
resolving to null on first use.
- addSuggestionsToShoppingList: pass userLogin into the createShoppingList
call. The conversion replaced minilang's call-service, which auto-forwards
userLogin, with a raw dispatcher.runSync call that doesn't, so the permission
check always failed with "User login is missing" on first use for a given party.
---
.../ofbiz/order/shoppinglist/ShoppingListServicesScript.groovy | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git
a/applications/order/src/main/groovy/org/apache/ofbiz/order/shoppinglist/ShoppingListServicesScript.groovy
b/applications/order/src/main/groovy/org/apache/ofbiz/order/shoppinglist/ShoppingListServicesScript.groovy
index c1f67e116f..8979bce9e6 100644
---
a/applications/order/src/main/groovy/org/apache/ofbiz/order/shoppinglist/ShoppingListServicesScript.groovy
+++
b/applications/order/src/main/groovy/org/apache/ofbiz/order/shoppinglist/ShoppingListServicesScript.groovy
@@ -279,12 +279,13 @@ Map addSuggestionsToShoppingList() {
Map createShoppingListInMap = [partyId: orderRole.partyId,
listName: 'Auto Suggestions',
shoppingListTypeId: 'SLT_WISH_LIST',
- productStoreId:
parameters.productStoreId]
+ productStoreId:
parameters.productStoreId,
+ userLogin: parameters.userLogin]
Map serviceResultCSL = dispatcher.runSync('createShoppingList',
createShoppingListInMap, 7200, true)
if (!ServiceUtil.isSuccess(serviceResultCSL)) {
return error(serviceResultCSL.errorMessage)
}
- shoppingListId = serviceResultCSL.serviceResult
+ shoppingListId = serviceResultCSL.shoppingListId
}
List orderItemList = from ('OrderItem').where(orderId:
parameters.orderId).orderBy('orderItemSeqId').queryList()
for (GenericValue orderItem : orderItemList) {