21 $arguments =
$action->getArguments();
26 $fields = $arguments[
'fields'] ?? [];
29 $this->addError(
new Error(
'Incorrect fields format'));
36 $action->setArguments($arguments);
39 return parent::processBeforeAction(
$action);
44 $arguments =
$action->getArguments();
48 $view = $this->getViewManager()->getView($this);
49 return $view->isAllowedProductTypeByIBlockId(static::TYPE,
$fields[
'iblockId']);
54 $r = parent::processBeforeAdd(
$action);
58 $r = $this->isAllowedProductTypeByIBlockId(
$action);
66 $r = parent::processBeforeUpdate(
$action);
70 $r = $this->isAllowedProductTypeByIBlockId(
$action);
108 bool $__calculateTotalCount =
true
112 $view = $this->getViewManager()->getView($this);
113 $r = $view->isAllowedProductTypeByIBlockId(static::TYPE,
$filter[
'IBLOCK_ID']);
114 if (!$r->isSuccess())
116 $this->addErrors($r->getErrors());
135 protected function get($id)