[ 
https://issues.apache.org/jira/browse/OFBIZ-1203?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12520934
 ] 

Jacopo Cappellato commented on OFBIZ-1203:
------------------------------------------

Yes, this feature is currently not implemented.
The trick to implement this is to probably create a new service that starting 
from a List of invoiceIds iterates over them, then retrieves the OrderItems 
associated and if the order item is still not COMPLETED and with the new 
invoices it is completely invoiced then complete it (calling the 
updateOrderItem service). There should be no need to complete the OrderHeader 
because there are ECAs attached to the updateOrderItem service that should 
already do this for us.
This new service can then be attached with a new ECA to the 
"createInvoicesFromShipment" service (the output List returned by this service, 
"invoicesCreated", will be the input of our new service.

PS: the new service could be named "checkCompleteInvoicedOrderItems" and can be 
defined and implemented in the order component.


> Drop Ship sales and purchase orders, move items to completed when items are 
> shipped and received.
> -------------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1203
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1203
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: accounting, order
>         Environment: All systems, all enviornments
>            Reporter: Karl Pieleck
>
> Setup: When a product that is marked drop ship is sold, and the product's 
> vendor is marked as "will drop ship".
> Result: The purchase order and sales order never close, even when the items 
> are shipped, received, and the purchase order is paid. This activity is 
> different than a regular sales order for items sold from stock, where the 
> order is completed once the items are paid and the order is shipped.
> Action to Correct: Add code and services to close "Drop Ship Type PO's and 
> Sales Orders" when they are actually completed.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to