26 lines
685 B
PHP
26 lines
685 B
PHP
<?php
|
|
|
|
namespace SoundPress\WHIOrders\Helper;
|
|
|
|
use Magento\Framework\App\Config\ScopeConfigInterface;
|
|
use \Magento\Framework\App\Helper\AbstractHelper;
|
|
|
|
class ConfigHelper extends AbstractHelper
|
|
{
|
|
protected $scopeConfig;
|
|
|
|
public function __construct(ScopeConfigInterface $scopeConfig)
|
|
{
|
|
$this->scopeConfig = $scopeConfig;
|
|
}
|
|
|
|
public function getApiToken()
|
|
{
|
|
return $this->scopeConfig->getValue('whiorders/api/api_token', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
|
|
}
|
|
|
|
public function getBaseUrl()
|
|
{
|
|
return $this->scopeConfig->getValue('whiorders/api/base_url', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
|
|
}
|
|
} |