History::saveStep

  1. Bitrix24 API (v. 23.675.0)
  2. landing
  3. History
  4. saveStep
  • Модуль: landing
  • Путь к файлу: ~/bitrix/modules/landing/lib/history.php
  • Класс: BitrixLandingHistory
  • Вызов: History::saveStep
protected function saveStep(int $step): bool
{
	$this->step = $step;

	if ($this->stepRowId)
	{
		$res = HistoryStepTable::update($this->stepRowId, ['STEP' => $step]);
	}
	else
	{
		$res = HistoryStepTable::add([
			'ENTITY_ID' => $this->entityId,
			'ENTITY_TYPE' => $this->entityType,
			'STEP' => $step,
		]);
	}

	if ($res->isSuccess())
	{
		$this->stepRowId = $res->getId();
		$this->step = $step;

		return true;
	}

	return false;
}

Добавить комментарий