Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
InstallStatus.php
1<?php
2
4
6
13{
14 private const OPTION_NAME = 'catalog_access_install_in_progress';
15
21 public static function inProgress(): bool
22 {
23 return Option::get('catalog', self::OPTION_NAME) === 'Y';
24 }
25
31 public static function start(): void
32 {
33 if (self::inProgress())
34 {
35 return;
36 }
37
38 Option::set('catalog', self::OPTION_NAME, 'Y');
39 }
40
46 public static function finish(): void
47 {
48 Option::delete('catalog', [
49 'name' => self::OPTION_NAME,
50 ]);
51 }
52}