private function deactivateSections($arIDs = array(), $IBLOCK_ID = 0) { if (!$IBLOCK_ID) { $IBLOCK_ID = $this->CATALOG_ID; } $arIDs = array_values($arIDs); $params = array( 'select' => array('ID'), 'filter' => array( '=IBLOCK_ID' => $IBLOCK_ID, '!=ID' => $arIDs, '=ACTIVE' => 'Y' ) ); $result = SectionTable::getList($params); while ($arSect = $result->fetch()) { SectionTable::update($arSect['ID'], array( 'ACTIVE' => 'N', 'TIMESTAMP_X' => new DateTime )); Report::deactivate('section'); } }