Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Shipping.php
Go to the documentation of this file.
1 <?php
8 
12 class Shipping
13 {
17  protected $_scopeConfig;
18 
22  public function __construct(\Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig)
23  {
24  $this->_scopeConfig = $scopeConfig;
25  }
26 
33  public function afterIsStateActive(\Magento\Checkout\Block\Cart\LayoutProcessor $subject, $result)
34  {
35  return (bool)$result || (bool)$this->_scopeConfig->getValue(
36  'carriers/dhl/active',
38  );
39  }
40 
47  public function afterIsCityActive(\Magento\Checkout\Block\Cart\LayoutProcessor $subject, $result)
48  {
49  return (bool)$result || (bool)$this->_scopeConfig->getValue(
50  'carriers/dhl/active',
52  );
53  }
54 }
afterIsCityActive(\Magento\Checkout\Block\Cart\LayoutProcessor $subject, $result)
Definition: Shipping.php:47
__construct(\Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig)
Definition: Shipping.php:22
afterIsStateActive(\Magento\Checkout\Block\Cart\LayoutProcessor $subject, $result)
Definition: Shipping.php:33