Use loggeraware trait
This commit is contained in:
@@ -30,13 +30,15 @@ namespace EP\EpProducts\Service;
|
||||
use Doctrine\DBAL\Connection;
|
||||
use EP\EpProducts\Domain\Model\Contingent;
|
||||
use EP\EpProducts\Traits\DbConnectionTrait;
|
||||
use TYPO3\CMS\Core\Log\Logger;
|
||||
use Psr\Log\LoggerAwareInterface;
|
||||
use Psr\Log\LoggerAwareTrait;
|
||||
use TYPO3\CMS\Core\SingletonInterface;
|
||||
use TYPO3\CMS\Core\Utility\GeneralUtility;
|
||||
use TYPO3\CMS\Extbase\Configuration\ConfigurationManagerInterface;
|
||||
|
||||
class ContingentImportService implements SingletonInterface
|
||||
class ContingentImportService implements SingletonInterface, LoggerAwareInterface
|
||||
{
|
||||
use LoggerAwareTrait;
|
||||
use DbConnectionTrait;
|
||||
|
||||
const ROOMCODE_STATUS = 'BelKal';
|
||||
@@ -56,11 +58,6 @@ class ContingentImportService implements SingletonInterface
|
||||
*/
|
||||
protected $db;
|
||||
|
||||
/**
|
||||
* @var Logger
|
||||
*/
|
||||
protected $logger;
|
||||
|
||||
/**
|
||||
* @param ConfigurationManagerInterface $manager
|
||||
* @throws \Doctrine\DBAL\DBALException
|
||||
@@ -77,7 +74,6 @@ class ContingentImportService implements SingletonInterface
|
||||
$this->pid = $settings['module']['tx_epproducts']['persistence']['storagePid'];
|
||||
}
|
||||
$this->db = $this->getDbConnection();
|
||||
$this->logger = GeneralUtility::makeInstance(\TYPO3\CMS\Core\Log\LogManager::class)->getLogger(__CLASS__);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -30,14 +30,16 @@ namespace EP\EpProducts\Service;
|
||||
use Doctrine\DBAL\Connection;
|
||||
use EP\EpProducts\Domain\Model\Room;
|
||||
use EP\EpProducts\Traits\DbConnectionTrait;
|
||||
use TYPO3\CMS\Core\Log\Logger;
|
||||
use Psr\Log\LoggerAwareInterface;
|
||||
use Psr\Log\LoggerAwareTrait;
|
||||
use TYPO3\CMS\Core\SingletonInterface;
|
||||
use TYPO3\CMS\Core\Utility\GeneralUtility;
|
||||
use TYPO3\CMS\Extbase\Configuration\ConfigurationManagerInterface;
|
||||
use TYPO3\CMS\Extbase\Service\CacheService;
|
||||
|
||||
class DateImportService implements SingletonInterface
|
||||
class DateImportService implements SingletonInterface, LoggerAwareInterface
|
||||
{
|
||||
use LoggerAwareTrait;
|
||||
use DbConnectionTrait;
|
||||
|
||||
const CODE_PSEUDOPRICE = 'PDGS';
|
||||
@@ -78,11 +80,6 @@ class DateImportService implements SingletonInterface
|
||||
*/
|
||||
protected $db;
|
||||
|
||||
/**
|
||||
* @var Logger
|
||||
*/
|
||||
protected $logger;
|
||||
|
||||
/**
|
||||
* @var CacheService
|
||||
*/
|
||||
@@ -123,7 +120,6 @@ class DateImportService implements SingletonInterface
|
||||
public function import($path)
|
||||
{
|
||||
$this->db = $this->getDbConnection();
|
||||
$this->logger = GeneralUtility::makeInstance(\TYPO3\CMS\Core\Log\LogManager::class)->getLogger(__CLASS__);
|
||||
$this->getRoomMappings();
|
||||
$this->getHotelMappings();
|
||||
$this->importPickups();
|
||||
|
||||
Reference in New Issue
Block a user