Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Public Member Functions | Data Fields | Protected Attributes
Config Class Reference

Public Member Functions

 __construct (\Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig, \Magento\Tax\Helper\Data $taxData)
 
 getPriceDisplayType ($store=null)
 
 getListPriceDisplayType ($store=null)
 
 getSalesPriceDisplayType ($store=null)
 
 getEmailPriceDisplayType ($store=null)
 
 includeInSubtotal ($store=null)
 
 isTaxable ($store=null)
 
 isEnabled ($store=null)
 

Data Fields

const XML_PATH_FPT_ENABLED = 'tax/weee/enable'
 
const XML_PATH_FPT_DISPLAY_PRODUCT_VIEW = 'tax/weee/display'
 
const XML_PATH_FPT_DISPLAY_PRODUCT_LIST = 'tax/weee/display_list'
 
const XML_PATH_FPT_DISPLAY_SALES = 'tax/weee/display_sales'
 
const XML_PATH_FPT_DISPLAY_EMAIL = 'tax/weee/display_email'
 
const XML_PATH_FPT_INCLUDE_IN_SUBTOTAL = 'tax/weee/include_in_subtotal'
 
const XML_PATH_FPT_TAXABLE = 'tax/weee/apply_vat'
 

Protected Attributes

 $scopeConfig
 

Detailed Description

WEEE config model

Definition at line 13 of file Config.php.

Constructor & Destructor Documentation

◆ __construct()

__construct ( \Magento\Framework\App\Config\ScopeConfigInterface  $scopeConfig,
\Magento\Tax\Helper\Data  $taxData 
)
Parameters
\Magento\Tax\Helper\Data$taxData
\Magento\Framework\App\Config\ScopeConfigInterface$scopeConfig

Definition at line 45 of file Config.php.

48  {
49  $this->taxHelper = $taxData;
50  $this->scopeConfig = $scopeConfig;
51  }

Member Function Documentation

◆ getEmailPriceDisplayType()

getEmailPriceDisplayType (   $store = null)

Get weee amount display type in email templates

Parameters
null | string | bool | int | Store$store
Returns
int

Definition at line 104 of file Config.php.

105  {
106  return $this->scopeConfig->getValue(
107  self::XML_PATH_FPT_DISPLAY_EMAIL,
109  $store
110  );
111  }

◆ getListPriceDisplayType()

getListPriceDisplayType (   $store = null)

Get weee amount display type on product list page

Parameters
null | string | bool | int | Store$store
Returns
int

Definition at line 74 of file Config.php.

75  {
76  return $this->scopeConfig->getValue(
77  self::XML_PATH_FPT_DISPLAY_PRODUCT_LIST,
79  $store
80  );
81  }

◆ getPriceDisplayType()

getPriceDisplayType (   $store = null)

Get weee amount display type on product view page

Parameters
null | string | bool | int | Store$store
Returns
int

Definition at line 59 of file Config.php.

60  {
61  return $this->scopeConfig->getValue(
62  self::XML_PATH_FPT_DISPLAY_PRODUCT_VIEW,
64  $store
65  );
66  }

◆ getSalesPriceDisplayType()

getSalesPriceDisplayType (   $store = null)

Get weee amount display type in sales modules

Parameters
null | string | bool | int | Store$store
Returns
int

Definition at line 89 of file Config.php.

90  {
91  return $this->scopeConfig->getValue(
92  self::XML_PATH_FPT_DISPLAY_SALES,
94  $store
95  );
96  }

◆ includeInSubtotal()

includeInSubtotal (   $store = null)

Check if weee tax amount should be included to subtotal

Parameters
null | string | bool | int | Store$store
Returns
bool

Definition at line 119 of file Config.php.

120  {
121  return $this->scopeConfig->isSetFlag(
122  self::XML_PATH_FPT_INCLUDE_IN_SUBTOTAL,
124  $store
125  );
126  }

◆ isEnabled()

isEnabled (   $store = null)

Check if fixed taxes are used in system

Parameters
null | string | bool | int | Store$store
Returns
bool

Definition at line 149 of file Config.php.

150  {
151  return $this->scopeConfig->getValue(
152  self::XML_PATH_FPT_ENABLED,
154  $store
155  );
156  }

◆ isTaxable()

isTaxable (   $store = null)

Check if weee tax amount should be taxable

Parameters
null | string | bool | int | Store$store
Returns
bool

Definition at line 134 of file Config.php.

135  {
136  return $this->scopeConfig->isSetFlag(
137  self::XML_PATH_FPT_TAXABLE,
139  $store
140  );
141  }

Field Documentation

◆ $scopeConfig

$scopeConfig
protected

Definition at line 39 of file Config.php.

◆ XML_PATH_FPT_DISPLAY_EMAIL

const XML_PATH_FPT_DISPLAY_EMAIL = 'tax/weee/display_email'

Definition at line 27 of file Config.php.

◆ XML_PATH_FPT_DISPLAY_PRODUCT_LIST

const XML_PATH_FPT_DISPLAY_PRODUCT_LIST = 'tax/weee/display_list'

Definition at line 23 of file Config.php.

◆ XML_PATH_FPT_DISPLAY_PRODUCT_VIEW

const XML_PATH_FPT_DISPLAY_PRODUCT_VIEW = 'tax/weee/display'

Definition at line 21 of file Config.php.

◆ XML_PATH_FPT_DISPLAY_SALES

const XML_PATH_FPT_DISPLAY_SALES = 'tax/weee/display_sales'

Definition at line 25 of file Config.php.

◆ XML_PATH_FPT_ENABLED

const XML_PATH_FPT_ENABLED = 'tax/weee/enable'

Enabled config path

Definition at line 18 of file Config.php.

◆ XML_PATH_FPT_INCLUDE_IN_SUBTOTAL

const XML_PATH_FPT_INCLUDE_IN_SUBTOTAL = 'tax/weee/include_in_subtotal'

Definition at line 30 of file Config.php.

◆ XML_PATH_FPT_TAXABLE

const XML_PATH_FPT_TAXABLE = 'tax/weee/apply_vat'

Definition at line 32 of file Config.php.


The documentation for this class was generated from the following file: