mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-03 20:29:09 +00:00
fix: qty calculation in SABB traceability
This commit is contained in:
@@ -268,7 +268,9 @@ class ReportData:
|
|||||||
(
|
(
|
||||||
(
|
(
|
||||||
stock_entry_detail.qty
|
stock_entry_detail.qty
|
||||||
/ Case().when(stock_entry.fg_completed_qty > 0, stock_entry.fg_completed_qty).else_(1)
|
/ Case()
|
||||||
|
.when(stock_entry.fg_completed_qty > 0, stock_entry.fg_completed_qty)
|
||||||
|
.else_(sabb_data.qty)
|
||||||
)
|
)
|
||||||
* sabb_data.qty
|
* sabb_data.qty
|
||||||
).as_("qty"),
|
).as_("qty"),
|
||||||
@@ -329,7 +331,7 @@ class ReportData:
|
|||||||
& (SABB.type_of_transaction == type_of_transaction)
|
& (SABB.type_of_transaction == type_of_transaction)
|
||||||
)
|
)
|
||||||
.orderby(SABB.posting_date)
|
.orderby(SABB.posting_date)
|
||||||
.orderby(SABE.posting_time)
|
.orderby(SABB.posting_time)
|
||||||
)
|
)
|
||||||
|
|
||||||
query = query.where((SABE.serial_no == value) | (SABE.batch_no == value))
|
query = query.where((SABE.serial_no == value) | (SABE.batch_no == value))
|
||||||
|
|||||||
Reference in New Issue
Block a user