From e7042bbc455548bee530fdbde1f5011d00c4b53f Mon Sep 17 00:00:00 2001 From: jm-extend Date: Mon, 23 Mar 2026 13:33:34 -0500 Subject: [PATCH] provide support for special prices in admin orders if your item has special prices, the offer will display accordingly. --- view/adminhtml/templates/order/create/items/warranty.phtml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/view/adminhtml/templates/order/create/items/warranty.phtml b/view/adminhtml/templates/order/create/items/warranty.phtml index 8aea300f..cdc1b29b 100644 --- a/view/adminhtml/templates/order/create/items/warranty.phtml +++ b/view/adminhtml/templates/order/create/items/warranty.phtml @@ -11,6 +11,8 @@ if ($_item = $block->getItem()): /** @var Extend\Warranty\ViewModel\Warranty $inCartViewModel */ $inCartViewModel = $block->getData('viewModel'); $productType = $_product->getTypeId(); + $rawPrice = (float)$_item->getPrice(); + $priceInCents = (float)number_format($rawPrice, 2, '', ''); ?> @@ -30,7 +32,7 @@ if ($_item = $block->getItem()): $scriptString = <<getId()}', { - referenceId: '{$inCartViewModel->getProductSkuByQuoteItem($_item)}', + referenceId: '{$inCartViewModel->getProductSkuByQuoteItem($_item)}', price: {$priceInCents}, onAddToCart: function (opts) { const plan = opts.plan;