fix(utils,core-flows): subtotal calculation and returns location (#13497)

* fix(utils,core-flows): subtotal calculation and returns location

* changeset

* fix test

* var

* rm extra field from test

* fix original total

* fix partial refunds and pending difference

* fix test

* fix test

* test

* extract to util

* original total and update payment when receive return

* original_subtotal

* default fields

* test

* calculate pending difference

* revert claims test

* pending difference

* creadit line fix

* if
This commit is contained in:
Carlos R. L. Rodrigues
2025-09-18 12:50:40 -03:00
committed by GitHub
parent 4736c58da5
commit 9563ee446f
37 changed files with 746 additions and 204 deletions

View File

@@ -358,6 +358,7 @@ export default class OrderModuleService
"discount_tax_total",
"original_total",
"original_tax_total",
"pending_difference",
"item_total",
"item_subtotal",
"item_tax_total",
@@ -370,9 +371,13 @@ export default class OrderModuleService
"original_shipping_tax_total",
"original_shipping_subtotal",
"original_shipping_total",
"original_total",
"original_subtotal",
"original_tax_total",
"credit_line_total",
"credit_line_tax_total",
"credit_line_subtotal",
"refundable_amount",
]
const includeTotals = (config?.select ?? []).some((field) =>