1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
version.php
См. документацию.
1<?php
2namespace Bitrix\Landing\Site;
3
4class Version
5{
6 private const VERSIONS = [
7 0 => null,
8 1 => \Bitrix\Landing\Site\Update\ChatSales::class,
9 2 => \Bitrix\Landing\Site\Update\ChatSalesOrder::class,
10 3 => \Bitrix\Landing\Site\Update\DomainUa::class,
11 4 => \Bitrix\Landing\Site\Update\DomainBy::class,
12 5 => \Bitrix\Landing\Site\Update\DomainByUpdate::class,
13 ];
14
15 protected static $process = false;
16
23 public static function update(int $siteId, ?int $version = 0): void
24 {
25 if (self::$process)
26 {
27 return;
28 }
29 self::$process = true;
30
31 $version = intval($version);
32
33 if ($version >= count(self::VERSIONS) - 1)
34 {
35 return;
36 }
37
39
40 foreach (self::VERSIONS as $updateVersion => $updateClass)
41 {
42 if ($updateVersion <= $version)
43 {
44 continue;
45 }
46
47 if (!$updateClass || !class_exists($updateClass))
48 {
49 continue;
50 }
51
52 if ($updateClass::update($siteId))
53 {
54 $version = $updateVersion;
55 }
56 else
57 {
58 break;
59 }
60 }
61
62 \Bitrix\Landing\Internals\SiteTable::update($siteId, [
63 'VERSION' => $version
64 ]);
65
67 self::$process = false;
68 }
69}
static setGlobalOn()
Определения rights.php:116
static setGlobalOff()
Определения rights.php:107
static update(int $siteId, ?int $version=0)
Определения version.php:23
static $process
Определения version.php:15
$siteId
Определения ajax.php:8
</p ></td >< td valign=top style='border-top:none;border-left:none;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0cm 2.0pt 0cm 2.0pt;height:9.0pt'>< p class=Normal align=center style='margin:0cm;margin-bottom:.0001pt;text-align:center;line-height:normal'>< a name=ТекстовоеПоле54 ></a ><?=($taxRate > count( $arTaxList) > 0) ? $taxRate."%"
Определения waybill.php:936