[jira] Created: (OFBIZ-53) Problem with adding item during modify order when there is no default price

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] Created: (OFBIZ-53) Problem with adding item during modify order when there is no default price

Nicolas Malin (Jira)
Problem with adding item during modify order when there is no default price
---------------------------------------------------------------------------

         Key: OFBIZ-53
         URL: http://issues.apache.org/jira/browse/OFBIZ-53
     Project: The Open For Business Project
        Type: Bug

  Components: order  
    Reporter: Si Chen


After an order has been created, when trying to modify an order in the order manager, we have problems adding a new item which may not have a "Default Price".  We get an error complaining that no price was found, even if there are prices and price rules which would calculate the price, or even if we specify the override price.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-53) Problem with adding item during modify order when there is no default price

Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-53?page=comments#action_12418489 ]

Si Chen commented on OFBIZ-53:
------------------------------

Part of the problem is probably this definition in applications/order/servicedef/services.xml where overridePrice is defined twice as a parameter

    <service name="appendOrderItem" engine="java" auth="true"
            location="org.ofbiz.order.order.OrderServices" invoke="addItemToApprovedOrder">
        <description>Append an itemto an existing order</description>
        <attribute name="orderId" type="String" mode="INOUT" optional="false"/>
        <attribute name="shipGroupSeqId" type="String" mode="IN" optional="false"/>
        <attribute name="productId" type="String" mode="IN" optional="false"/>
        <attribute name="overridePrice" type="String" mode="IN" optional="true"/>
        <attribute name="basePrice" type="Double" mode="IN" optional="true"/>
        <attribute name="quantity" type="Double" mode="IN" optional="false"/>
        <attribute name="amount" type="Double" mode="IN" optional="true"/>
        <attribute name="overridePrice" type="Boolean" mode="IN" optional="true"/>
        <attribute name="shoppingCart" type="org.ofbiz.order.shoppingcart.ShoppingCart" mode="OUT" optional="false"/>
    </service>

The other problem might be that this line in OrderServices.java is not initializing the cart item properly?

ShoppingCartItem item = ShoppingCartItem.makeItem(null, productId, 0.00, quantity.doubleValue(), null, null, null, dispatcher, cart);
           

> Problem with adding item during modify order when there is no default price
> ---------------------------------------------------------------------------
>
>          Key: OFBIZ-53
>          URL: http://issues.apache.org/jira/browse/OFBIZ-53
>      Project: The Open For Business Project
>         Type: Bug

>   Components: order
>     Reporter: Si Chen

>
> After an order has been created, when trying to modify an order in the order manager, we have problems adding a new item which may not have a "Default Price".  We get an error complaining that no price was found, even if there are prices and price rules which would calculate the price, or even if we specify the override price.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-53) Problem with adding item during modify order when there is no default price

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
     [ http://issues.apache.org/jira/browse/OFBIZ-53?page=all ]

Chris Howe updated OFBIZ-53:
----------------------------

    Attachment: OrderServices.patch

OrderServices.patch

This should fix your issue. the final parameter of makeItem and of setQuantity defaults to true to run updatePrice which checks the price rules.  I believe this does however need to validate whether the entered price is greater than the minimum price and less than the maximum price.

Although slightly off topic, the bulk screen (uri=LookupBulkAddProducts) uses amount instead of a price parameter.  Amount turns into the selectedAmount which has something to do with the manufacturing stuff I believe.

> Problem with adding item during modify order when there is no default price
> ---------------------------------------------------------------------------
>
>          Key: OFBIZ-53
>          URL: http://issues.apache.org/jira/browse/OFBIZ-53
>      Project: The Open For Business Project
>         Type: Bug

>   Components: order
>     Reporter: Si Chen
>  Attachments: OrderServices.patch
>
> After an order has been created, when trying to modify an order in the order manager, we have problems adding a new item which may not have a "Default Price".  We get an error complaining that no price was found, even if there are prices and price rules which would calculate the price, or even if we specify the override price.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-53) Problem with adding item during modify order when there is no default price

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-53?page=comments#action_12419619 ]

Leon Torres commented on OFBIZ-53:
----------------------------------

fixed in revision 419736.

> Problem with adding item during modify order when there is no default price
> ---------------------------------------------------------------------------
>
>          Key: OFBIZ-53
>          URL: http://issues.apache.org/jira/browse/OFBIZ-53
>      Project: The Open For Business Project
>         Type: Bug

>   Components: order
>     Reporter: Si Chen
>  Attachments: OrderServices.patch
>
> After an order has been created, when trying to modify an order in the order manager, we have problems adding a new item which may not have a "Default Price".  We get an error complaining that no price was found, even if there are prices and price rules which would calculate the price, or even if we specify the override price.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-53) Problem with adding item during modify order when there is no default price

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-53?page=comments#action_12419623 ]

Leon Torres commented on OFBIZ-53:
----------------------------------

And also in 419743

> Problem with adding item during modify order when there is no default price
> ---------------------------------------------------------------------------
>
>          Key: OFBIZ-53
>          URL: http://issues.apache.org/jira/browse/OFBIZ-53
>      Project: The Open For Business Project
>         Type: Bug

>   Components: order
>     Reporter: Si Chen
>  Attachments: OrderServices.patch
>
> After an order has been created, when trying to modify an order in the order manager, we have problems adding a new item which may not have a "Default Price".  We get an error complaining that no price was found, even if there are prices and price rules which would calculate the price, or even if we specify the override price.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply | Threaded
Open this post in threaded view
|

[jira] Closed: (OFBIZ-53) Problem with adding item during modify order when there is no default price

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
     [ http://issues.apache.org/jira/browse/OFBIZ-53?page=all ]
     
Si Chen closed OFBIZ-53:
------------------------

    Resolution: Fixed

> Problem with adding item during modify order when there is no default price
> ---------------------------------------------------------------------------
>
>          Key: OFBIZ-53
>          URL: http://issues.apache.org/jira/browse/OFBIZ-53
>      Project: The Open For Business Project
>         Type: Bug

>   Components: order
>     Reporter: Si Chen
>  Attachments: OrderServices.patch
>
> After an order has been created, when trying to modify an order in the order manager, we have problems adding a new item which may not have a "Default Price".  We get an error complaining that no price was found, even if there are prices and price rules which would calculate the price, or even if we specify the override price.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira