forked from andreyryabin/sprint.migration
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathoptions.php
27 lines (20 loc) · 852 Bytes
/
options.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php
$module_id = "sprint.migration";
global $APPLICATION;
$MODULE_RIGHT = $APPLICATION->GetGroupRight($module_id);
if (!($MODULE_RIGHT >= "R")){
$APPLICATION->AuthForm("ACCESS_DENIED");
}
CModule::IncludeModule($module_id);
$upgradeManager = new \Sprint\Migration\UpgradeManager(true);
if ($_SERVER['REQUEST_METHOD'] == "POST" && check_bitrix_sessid()){
if (!empty($_REQUEST["upgrade_reload"])){
$upgradeManager->upgradeReload();
}
}
?>
<form method="post" action="<? echo $APPLICATION->GetCurPage() ?>?mid=<?=urlencode($module_id)?>&lang=<?=LANGUAGE_ID?>">
<p><?=GetMessage('SPRINT_MIGRATION_UPGRADE_VERSION')?>: <?= $upgradeManager->getUpgradeVersion() ?> </p>
<p><input type="submit" name="upgrade_reload" value="<?=GetMessage('SPRINT_MIGRATION_UPGRADE_RELOAD')?>"></p>
<?=bitrix_sessid_post();?>
</form>