1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
Step.php
См. документацию.
1<?php
3
4class Step
5{
6 public const STEP_INIT = 'init';
7 public const STEP_FILES = 'files';
8 public const STEP_IBLOCK_INDEX = 'iblock_index';
9 public const STEP_IBLOCK = 'iblock';
10 public const STEP_FORUM_INDEX = 'forum_index';
11 public const STEP_FORUM = 'forum';
12 public const STEP_INDEX = 'index';
13
14 public const STEPS = [
15 self::STEP_INIT => 0,
16 self::STEP_FILES => 10,
17 self::STEP_IBLOCK_INDEX => 20,
18 self::STEP_IBLOCK => 40,
19 self::STEP_FORUM_INDEX => 50,
20 self::STEP_FORUM => 70,
21 self::STEP_INDEX => 100,
22 ];
23
28 public static function getFirstStep(): int
29 {
30 $stepValues = array_values(self::STEPS);
31
32 return array_shift($stepValues);
33 }
34
39 public static function getFirstStepName(): string
40 {
41 $stepValues = array_keys(self::STEPS);
42
43 return array_shift($stepValues);
44 }
45
50 public static function getLastStep(): int
51 {
52 $stepValues = array_values(self::STEPS);
53
54 return array_pop($stepValues);
55 }
56
61 public static function getLastStepName(): string
62 {
63 $stepValues = array_keys(self::STEPS);
64
65 return array_pop($stepValues);
66 }
67}
const STEP_FILES
Определения Step.php:7
const STEP_IBLOCK
Определения Step.php:9
const STEPS
Определения Step.php:14
const STEP_IBLOCK_INDEX
Определения Step.php:8
const STEP_FORUM
Определения Step.php:11
static getLastStepName()
Определения Step.php:61
static getFirstStepName()
Определения Step.php:39
static getLastStep()
Определения Step.php:50
const STEP_INIT
Определения Step.php:6
static getFirstStep()
Определения Step.php:28
const STEP_INDEX
Определения Step.php:12
const STEP_FORUM_INDEX
Определения Step.php:10
Определения Step.php:2