29 $this->configCache = $configCacheType;
30 parent::__construct($context);
40 $this->
_init(
'store',
'store_id');
68 $this->_uniqueFields = [[
'field' =>
'code',
'title' =>
__(
'Store with the same code')]];
80 parent::_afterSave($object);
97 'scope_id = ?' =>
$model->getStoreId(),
101 $this->configCache->clean();
116 $bindValues = [
'group_id' => (int)
$groupId];
119 [
'count' =>
'COUNT(*)']
121 'group_id = :group_id' 126 $bind = [
'default_store_id' => (int)
$storeId];
127 $where = [
'group_id = ?' => (int)
$groupId];
142 if (
$model->getOriginalGroupId() &&
$model->getGroupId() !=
$model->getOriginalGroupId()) {
148 $connection->quoteInto(
'group_id=?', $model->getOriginalGroupId())
154 $where = [
'group_id = ?' =>
$model->getOriginalGroupId()];
_updateGroupDefaultStore($groupId, $storeId)
_afterDelete(\Magento\Framework\Model\AbstractModel $model)
_changeGroup(\Magento\Framework\Model\AbstractModel $model)
__construct(\Magento\Framework\Model\ResourceModel\Db\Context $context, \Magento\Framework\App\Cache\Type\Config $configCacheType)
_init($mainTable, $idFieldName)
_getLoadSelect($field, $value, $object)
_afterSave(\Magento\Framework\Model\AbstractModel $object)
countAll($countAdmin=false)