Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0049238Openbravo ERP07. Sales managementpublic2022-05-05 14:432022-10-06 14:48
kousalya_r 
Triage Omni OMS 
normalminoralways
newopen 
5
PR20Q3.2 
 
Core
No
0049238: Sales Order DeliveryStatus field shows 100% when it is not
In version PR20Q3.2, the Shipping Status field is rounding up to show that it is already 100% shipped, when it really is not.

I enclose an image with an example of an order, this order is sent at 99.671%, since there are 4 lines to send but it shows 100%.
Create sales order and deliver few quantities and check deliver status field is rounding up but it should not
Use DeliveryStatus column reference from 'Integer' to 'Amount'
and change SQL logic as below

(coalesce((select case when sum(abs(ol.qtyordered)) = 0 or iscancelled = 'Y' or cancelledorder_id is not null then 0 else
round(coalesce(sum(abs(ol.qtydelivered)), 0)/sum(abs(ol.qtyordered)) * 100, 2) end
from c_orderline ol where ol.c_order_id=c_order_id and ol.c_order_discount_id is null),0))
No tags attached.
jpg see100.jpg (250,113) 2022-05-05 14:43
https://issues.openbravo.com/file_download.php?file_id=16983&type=bug
jpg

diff 49238.diff (6,075) 2022-05-23 13:50
https://issues.openbravo.com/file_download.php?file_id=17052&type=bug
Issue History
2022-05-05 14:43kousalya_rNew Issue
2022-05-05 14:43kousalya_rAssigned To => Triage Omni OMS
2022-05-05 14:43kousalya_rFile Added: see100.jpg
2022-05-05 14:43kousalya_rModules => Core
2022-05-05 14:43kousalya_rTriggers an Emergency Pack => No
2022-05-05 14:53eugeniIssue Monitored: eugeni
2022-05-23 13:49aferrazNote Added: 0137612
2022-05-23 13:50aferrazSeveritymajor => minor
2022-05-23 13:50aferrazFile Added: 49238.diff
2022-10-06 14:48aferrazTypedefect => design defect

Notes
(0137612)
aferraz   
2022-05-23 13:49   
Severity changed to minor as delivery status is an informative field that shows the approximate delivered percentage.
Changing the reference of the column will create an API change.
Besides, delivered field already displays if the order has been fully delivered or not.

Attached a diff to change the rounding and the reference of Delivery Status, Invoice Status and Payment Status columns in case the customer wants to apply it.