3namespace Bitrix\Iblock\Grid\Row\Actions\Item;
5use Bitrix\Main\AccessDeniedException;
7use Bitrix\Main\HttpRequest;
8use Bitrix\Main\Localization\Loc;
15 public static function getId(): ?string
17 return 'clear_counter';
22 return Loc::getMessage(
'IBLOCK_GRID_ROW_ACTIONS_CLEAR_COUNTER_NAME');
27 $id = (int)($rawFields[
'ID'] ?? 0);
34 $data = CUtil::PhpToJSObject([
38 $this->onclick =
"IblockGridInstance.sendRowAction('{$actionId}', {$data})";
40 return parent::getControl($rawFields);
46 if (empty($id) || !is_numeric($id))
60 $updateResult =
$entity->Update($id, [
61 'SHOW_COUNTER' =>
false,
62 'SHOW_COUNTER_START' =>
false,
if(!Loader::includeModule('catalog')) if(!AccessController::getCurrent() ->check(ActionDictionary::ACTION_PRICE_EDIT)) if(!check_bitrix_sessid()) $request
getControl(array $rawFields)
processRequest(HttpRequest $request)
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)