Technologische Neuigkeiten, Bewertungen und Tipps!

So erhalten Sie ausgewählte Versandkosten auf der Magento 2-Checkout-Seite

So erhalten Sie ausgewählte Versandkosten auf der Magento 2-Checkout-Seite

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

Namespace Vendor\Magento\Block;

verwenden Sie Magento\Checkout\Model\Session;

Die Klasse ShippingRate implementiert ConfigProviderInterface

{

protected $checkoutSession;

protected $quote;

öffentliche Funktion __construct(

Sitzung $checkoutSession,

)

{

$this->checkoutSession = $checkoutSession;

$this->quote = $checkoutSession->getQuote();

}

öffentliche Funktion getShippingRate()

{

$shippingAmount = $this->quote->getShippingAddress()->getShippingAmount();

}

}

Your Header Sidebar area is currently empty. Hurry up and add some widgets.