I need some advice with the following issue. Can somebody help me, please?
I’m trying to generate a Purchase Order in USD currency from requirements
generated by a store using BRL:
- A customer Buys in BRL in a Brazilian store (facility 1), through Sales
Order.
- The Brazilian Store generates requirements for US store (facility 2).
So far so good.
But when I try to create a Purchase Order based on the requirements, the system
gives me a message “SupplierProduct” not found.
After check everything out, prices, facilities, range dates, having no success,
I decided to debug it.
And for my surprise, I realized that the Shopping Cart’s currency is being
defined based on HTTP locale and not on the parties currencyUomId.
Is this right?
package org.ofbiz.order.shoppingcart;
public class ShoppingCartEvents {
public static String quickInitPurchaseOrder(HttpServletRequest request,
HttpServletResponse response) {
Delegator delegator = (Delegator) request.getAttribute("delegator");
LocalDispatcher dispatcher = (LocalDispatcher)
request.getAttribute("dispatcher");
HttpSession session = request.getSession();
Locale locale = UtilHttp.getLocale(request);
ShoppingCart cart = new WebShoppingCart(request);
// TODO: the code below here needs some cleanups
……
I tried with 9.04 version and now with the recently lauched 10.04.x.
What else can I try?
Thank you!