mirror of
https://github.com/the-djmaze/snappymail.git
synced 2025-10-06 19:55:49 +08:00
Added Admin Panel About Tab
New update system for main code (About tab)
This commit is contained in:
parent
b6a06d74a9
commit
e63037d7e2
27 changed files with 978 additions and 625 deletions
|
@ -5,12 +5,72 @@
|
|||
*/
|
||||
function AdminAbout()
|
||||
{
|
||||
var oData = RL.data();
|
||||
|
||||
this.version = ko.observable(RL.settingsGet('Version'));
|
||||
this.access = ko.observable(!!RL.settingsGet('CoreAccess'));
|
||||
this.errorDesc = ko.observable('');
|
||||
|
||||
this.coreReal = oData.coreReal;
|
||||
this.coreUpdatable = oData.coreUpdatable;
|
||||
this.coreAccess = oData.coreAccess;
|
||||
this.coreChecking = oData.coreChecking;
|
||||
this.coreUpdating = oData.coreUpdating;
|
||||
this.coreRemoteVersion = oData.coreRemoteVersion;
|
||||
this.coreRemoteRelease = oData.coreRemoteRelease;
|
||||
this.coreVersionCompare = oData.coreVersionCompare;
|
||||
|
||||
this.statusType = ko.computed(function () {
|
||||
|
||||
var
|
||||
sType = '',
|
||||
iVersionCompare = this.coreVersionCompare(),
|
||||
bChecking = this.coreChecking(),
|
||||
bUpdating = this.coreUpdating(),
|
||||
bReal = this.coreReal()
|
||||
;
|
||||
|
||||
if (bChecking)
|
||||
{
|
||||
sType = 'checking';
|
||||
}
|
||||
else if (bUpdating)
|
||||
{
|
||||
sType = 'updating';
|
||||
}
|
||||
else if (bReal && 0 === iVersionCompare)
|
||||
{
|
||||
sType = 'up-to-date';
|
||||
}
|
||||
else if (bReal && -1 === iVersionCompare)
|
||||
{
|
||||
sType = 'available';
|
||||
}
|
||||
else if (!bReal)
|
||||
{
|
||||
sType = 'error';
|
||||
this.errorDesc('Cannot access the repository at the moment.');
|
||||
}
|
||||
|
||||
return sType;
|
||||
|
||||
}, this);
|
||||
}
|
||||
|
||||
Utils.addSettingsViewModel(AdminAbout, 'AdminSettingsAbout', 'About', 'about');
|
||||
|
||||
//AdminAbout.prototype.onBuild = function ()
|
||||
//{
|
||||
//
|
||||
//};
|
||||
AdminAbout.prototype.onBuild = function ()
|
||||
{
|
||||
if (this.access())
|
||||
{
|
||||
RL.reloadCoreData();
|
||||
}
|
||||
};
|
||||
|
||||
AdminAbout.prototype.updateCoreData = function ()
|
||||
{
|
||||
if (!this.coreUpdating())
|
||||
{
|
||||
RL.updateCoreData();
|
||||
}
|
||||
};
|
||||
|
|
|
@ -145,6 +145,61 @@ AdminApp.prototype.reloadPackagesList = function ()
|
|||
});
|
||||
};
|
||||
|
||||
AdminApp.prototype.updateCoreData = function ()
|
||||
{
|
||||
var oRainData = RL.data();
|
||||
|
||||
oRainData.coreUpdating(true);
|
||||
RL.remote().updateCoreData(function (sResult, oData) {
|
||||
|
||||
oRainData.coreUpdating(false);
|
||||
oRainData.coreRemoteVersion('');
|
||||
oRainData.coreRemoteRelease('');
|
||||
oRainData.coreVersionCompare(-2);
|
||||
|
||||
if (Enums.StorageResultType.Success === sResult && oData && oData.Result)
|
||||
{
|
||||
oRainData.coreReal(true);
|
||||
window.location.reload();
|
||||
}
|
||||
else
|
||||
{
|
||||
oRainData.coreReal(false);
|
||||
}
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
AdminApp.prototype.reloadCoreData = function ()
|
||||
{
|
||||
var oRainData = RL.data();
|
||||
|
||||
oRainData.coreChecking(true);
|
||||
oRainData.coreReal(true);
|
||||
|
||||
RL.remote().coreData(function (sResult, oData) {
|
||||
|
||||
oRainData.coreChecking(false);
|
||||
|
||||
if (Enums.StorageResultType.Success === sResult && oData && oData.Result)
|
||||
{
|
||||
oRainData.coreReal(!!oData.Result.Real);
|
||||
oRainData.coreUpdatable(!!oData.Result.Updatable);
|
||||
oRainData.coreAccess(!!oData.Result.Access);
|
||||
oRainData.coreRemoteVersion(oData.Result.RemoteVersion || '');
|
||||
oRainData.coreRemoteRelease(oData.Result.RemoteRelease || '');
|
||||
oRainData.coreVersionCompare(Utils.pInt(oData.Result.VersionCompare));
|
||||
}
|
||||
else
|
||||
{
|
||||
oRainData.coreReal(false);
|
||||
oRainData.coreRemoteVersion('');
|
||||
oRainData.coreRemoteRelease('');
|
||||
oRainData.coreVersionCompare(-2);
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
*
|
||||
* @param {boolean=} bForce = false
|
||||
|
@ -212,7 +267,7 @@ AdminApp.prototype.bootstart = function ()
|
|||
}
|
||||
else
|
||||
{
|
||||
Utils.removeSettingsViewModel(AdminAbout);
|
||||
// Utils.removeSettingsViewModel(AdminAbout);
|
||||
|
||||
if (!RL.capa(Enums.Capa.Prem))
|
||||
{
|
||||
|
|
|
@ -16,7 +16,5 @@ _.extend(AdminSettingsScreen.prototype, AbstractSettings.prototype);
|
|||
|
||||
AdminSettingsScreen.prototype.onShow = function ()
|
||||
{
|
||||
// AbstractSettings.prototype.onShow.call(this);
|
||||
|
||||
RL.setTitle('');
|
||||
};
|
|
@ -23,8 +23,6 @@ _.extend(SettingsScreen.prototype, AbstractSettings.prototype);
|
|||
|
||||
SettingsScreen.prototype.onShow = function ()
|
||||
{
|
||||
// AbstractSettings.prototype.onShow.call(this);
|
||||
|
||||
RL.setTitle(this.sSettingsTitle);
|
||||
RL.data().keyScope(Enums.KeyState.Settings);
|
||||
};
|
||||
|
|
|
@ -67,6 +67,22 @@ AdminAjaxRemoteStorage.prototype.packagesList = function (fCallback)
|
|||
this.defaultRequest(fCallback, 'AdminPackagesList');
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
*/
|
||||
AdminAjaxRemoteStorage.prototype.coreData = function (fCallback)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'AdminCoreData');
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
*/
|
||||
AdminAjaxRemoteStorage.prototype.updateCoreData = function (fCallback)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'AdminUpdateCoreData', {}, 90000);
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
* @param {Object} oPackage
|
||||
|
|
|
@ -19,6 +19,15 @@ function AdminDataStorage()
|
|||
this.packagesLoading = ko.observable(false).extend({'throttle': 100});
|
||||
this.packages = ko.observableArray([]);
|
||||
|
||||
this.coreReal = ko.observable(true);
|
||||
this.coreUpdatable = ko.observable(true);
|
||||
this.coreAccess = ko.observable(true);
|
||||
this.coreChecking = ko.observable(false).extend({'throttle': 100});
|
||||
this.coreUpdating = ko.observable(false).extend({'throttle': 100});
|
||||
this.coreRemoteVersion = ko.observable('');
|
||||
this.coreRemoteRelease = ko.observable('');
|
||||
this.coreVersionCompare = ko.observable(-2);
|
||||
|
||||
this.licensing = ko.observable(false);
|
||||
this.licensingProcess = ko.observable(false);
|
||||
this.licenseValid = ko.observable(false);
|
||||
|
|
|
@ -97,5 +97,6 @@
|
|||
|
||||
.b-settings-content {
|
||||
padding: 20px;
|
||||
padding-left: 30px;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4,7 +4,13 @@
|
|||
display: inline-block;
|
||||
width: 250px;
|
||||
height: 250px;
|
||||
margin-top: -10px;
|
||||
margin-bottom: -10px;
|
||||
background-image: url("images/rainloop-logo.png");
|
||||
}
|
||||
.rl-desc {
|
||||
margin-top: 20px;
|
||||
margin-left: -20px;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -95,5 +95,6 @@
|
|||
|
||||
.b-settings-content {
|
||||
padding: 20px;
|
||||
padding-left: 30px;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
{
|
||||
"name": "RainLoop",
|
||||
"title": "RainLoop Webmail",
|
||||
"version": "1.6.6",
|
||||
"release": "930",
|
||||
"version": "1.6.7",
|
||||
"release": "102",
|
||||
"description": "Simple, modern & fast web-based email client",
|
||||
"homepage": "http://rainloop.net",
|
||||
"main": "Gruntfile.js",
|
||||
|
|
|
@ -1171,6 +1171,7 @@ class Actions
|
|||
$aResult['SubscriptionEnabled'] = \MailSo\Base\Utils::ValidateDomain($aResult['AdminDomain']);
|
||||
|
||||
$aResult['WeakPassword'] = $oConfig->ValidatePassword('12345');
|
||||
$aResult['CoreAccess'] = $this->rainLoopCoreAccess();
|
||||
}
|
||||
|
||||
$aResult['Capa'] = $this->Capa(true);
|
||||
|
@ -2604,25 +2605,11 @@ class Actions
|
|||
}
|
||||
|
||||
/**
|
||||
* @param bool $bAdditionalOnly = false
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
private function rainloopRepo($bAdditionalOnly = false)
|
||||
private function rainloopRepo()
|
||||
{
|
||||
if ($bAdditionalOnly)
|
||||
{
|
||||
$sUrl = $this->Config()->Get('labs', 'additional_repo', '');
|
||||
}
|
||||
else
|
||||
{
|
||||
$sUrl = $this->Config()->Get('labs', 'custom_repo', '');
|
||||
if (0 === \strlen($sUrl))
|
||||
{
|
||||
$sUrl = APP_REP_PATH;
|
||||
}
|
||||
}
|
||||
|
||||
$sUrl = APP_REP_PATH;
|
||||
if ('' !== $sUrl)
|
||||
{
|
||||
$sUrl = rtrim($sUrl, '\\/').'/';
|
||||
|
@ -2635,15 +2622,17 @@ class Actions
|
|||
{
|
||||
return @file_exists(APP_INDEX_ROOT_PATH.'index.php') &&
|
||||
@is_writable(APP_INDEX_ROOT_PATH.'index.php') &&
|
||||
@is_writable(APP_INDEX_ROOT_PATH.'rainloop/');
|
||||
@is_writable(APP_INDEX_ROOT_PATH.'rainloop/') &&
|
||||
APP_VERSION !== APP_DEV_VERSION
|
||||
;
|
||||
}
|
||||
|
||||
private function rainLoopCoreAccess()
|
||||
{
|
||||
$sCoreAccess = \strtolower(\preg_replace('/[\s,;]+/', ' ',
|
||||
$this->Config()->Get('security', 'core_install_access_domains', '')));
|
||||
$this->Config()->Get('security', 'core_install_access_domain', '')));
|
||||
|
||||
return '' === $sCoreAccess || APP_SITE === $sCoreAccess;
|
||||
return '' === $sCoreAccess || '*' === $sCoreAccess || APP_SITE === $sCoreAccess;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -2661,22 +2650,6 @@ class Actions
|
|||
$sRepoFile = 'repository.json';
|
||||
$iRepTime = 0;
|
||||
|
||||
if ($bMain)
|
||||
{
|
||||
switch (\strtolower(\trim($this->Config()->Get('labs', 'repo_type', 'stable'))))
|
||||
{
|
||||
case 'dev':
|
||||
case 'nightly':
|
||||
case 'beta':
|
||||
$sRepoFile = 'beta.repository.json';
|
||||
break;
|
||||
case 'stable':
|
||||
default:
|
||||
$sRepoFile = 'repository.json';
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
$oHttp = \MailSo\Base\Http::SingletonInstance();
|
||||
|
||||
$sCacheKey = 'UPDATER/('.$sRepo.')/'.$sRepoFile;
|
||||
|
@ -2717,8 +2690,6 @@ class Actions
|
|||
$bReal = \is_array($aRep) && 0 < \count($aRep);
|
||||
}
|
||||
|
||||
$bCoreAccess = $this->rainLoopCoreAccess();
|
||||
|
||||
$aResult = array();
|
||||
if (\is_array($aRep))
|
||||
{
|
||||
|
@ -2737,24 +2708,7 @@ class Actions
|
|||
continue;
|
||||
}
|
||||
|
||||
if ('core' === $oItem->type)
|
||||
{
|
||||
if ($bCoreAccess)
|
||||
{
|
||||
$aResult[] = array(
|
||||
'type' => $oItem->type,
|
||||
'id' => $oItem->id,
|
||||
'name' => $oItem->name,
|
||||
'installed' => APP_VERSION,
|
||||
'version' => $oItem->version,
|
||||
'file' => $oItem->file,
|
||||
'release' => $oItem->release,
|
||||
'release_notes' => isset($oItem->{'release_notes'}) ? $oItem->{'release_notes'} : '',
|
||||
'desc' => $oItem->description
|
||||
);
|
||||
}
|
||||
}
|
||||
else if ('plugin' === $oItem->type)
|
||||
if ('plugin' === $oItem->type)
|
||||
{
|
||||
$aResult[] = array(
|
||||
'type' => $oItem->type,
|
||||
|
@ -2775,47 +2729,72 @@ class Actions
|
|||
return $aResult;
|
||||
}
|
||||
|
||||
private function getCoreData(&$bReal)
|
||||
{
|
||||
$bReal = false;
|
||||
$sRepo = APP_REPO_CORE_FILE;
|
||||
|
||||
$oHttp = \MailSo\Base\Http::SingletonInstance();
|
||||
|
||||
$sCacheKey = 'CORE-UPDATER/'.$sRepo;
|
||||
$sRep = $this->Cacher()->Get($sCacheKey);
|
||||
if ('' !== $sRep)
|
||||
{
|
||||
$iRepTime = $this->Cacher()->GetTimer($sCacheKey);
|
||||
}
|
||||
|
||||
if ('' === $sRep || 0 === $iRepTime || time() - 3600 > $iRepTime)
|
||||
{
|
||||
$iCode = 0;
|
||||
$sContentType = '';
|
||||
|
||||
$sRep = '' !== $sRepo ? $oHttp->GetUrlAsString($sRepo, 'RainLoop', $sContentType, $iCode, $this->Logger(), 10,
|
||||
$this->Config()->Get('labs', 'curl_proxy', ''), $this->Config()->Get('labs', 'curl_proxy_auth', '')) : false;
|
||||
|
||||
if (false !== $sRep)
|
||||
{
|
||||
$aRep = @\json_decode($sRep, true, 10);
|
||||
$bReal = \is_array($aRep) && 0 < \count($aRep) && isset($aRep['id']) && 'rainloop' === $aRep['id'];
|
||||
|
||||
if ($bReal)
|
||||
{
|
||||
$this->Cacher()->Set($sCacheKey, $sRep);
|
||||
$this->Cacher()->SetTimer($sCacheKey);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->Logger()->Write('Cannot read remote repository file: '.$sRepo, \MailSo\Log\Enumerations\Type::ERROR, 'INSTALLER');
|
||||
}
|
||||
}
|
||||
else if ('' !== $sRep)
|
||||
{
|
||||
$aRep = @\json_decode($sRep, true, 10);
|
||||
$bReal = \is_array($aRep) && 0 < \count($aRep) && isset($aRep['id']) && 'rainloop' === $aRep['id'];
|
||||
}
|
||||
|
||||
return $bReal ? $aRep : false;
|
||||
}
|
||||
|
||||
private function getRepositoryData(&$bReal, &$bRainLoopUpdatable)
|
||||
{
|
||||
$bRainLoopUpdatable = $this->rainLoopUpdatable();
|
||||
$bCoreAccess = $this->rainLoopCoreAccess();
|
||||
|
||||
$aResult = $this->getRepositoryDataByUrl($this->rainloopRepo(), $bReal);
|
||||
|
||||
$sAddRepo = $this->rainloopRepo(true);
|
||||
if (0 < \strlen($sAddRepo))
|
||||
$aSub = array();
|
||||
if (\is_array($aResult))
|
||||
{
|
||||
$bFakeReal = false;
|
||||
$aAddData = $this->getRepositoryDataByUrl($sAddRepo, $bFakeReal, false);
|
||||
if ($bFakeReal && \is_array($aAddData) && 0 < \count($aAddData))
|
||||
foreach ($aResult as $aItem)
|
||||
{
|
||||
$aResult = \array_merge($aResult, $aAddData);
|
||||
if ('plugin' === $aItem['type'])
|
||||
{
|
||||
$aSub[] = $aItem;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$bAddCore = false;
|
||||
foreach ($aResult as $aItem)
|
||||
{
|
||||
if ($aItem && 'core' === $aItem['type'])
|
||||
{
|
||||
$bAddCore = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if ($bCoreAccess && !$bAddCore)
|
||||
{
|
||||
\array_unshift($aResult, array(
|
||||
'type' => 'core',
|
||||
'id' => 'rainloop',
|
||||
'name' => 'RainLoop Webmail (core)',
|
||||
'installed' => APP_VERSION,
|
||||
'version' => '',
|
||||
'file' => '',
|
||||
'release' => '',
|
||||
'release_notes' => '',
|
||||
'desc' => ''
|
||||
));
|
||||
$aResult = $aSub;
|
||||
unset($aSub);
|
||||
}
|
||||
|
||||
$aInstalled = $this->Plugins()->InstalledPlugins();
|
||||
|
@ -2861,20 +2840,6 @@ class Actions
|
|||
$aItem['canBeDeleted'] = '' !== $aItem['installed'] && 'plugin' === $aItem['type'];
|
||||
$aItem['canBeUpdated'] = $aItem['compare'];
|
||||
$aItem['canBeInstalled'] = true;
|
||||
|
||||
if ('plugin' !== $aItem['type'])
|
||||
{
|
||||
if (!$bRainLoopUpdatable)
|
||||
{
|
||||
$aItem['canBeInstalled'] = false;
|
||||
$aItem['canBeUpdated'] = false;
|
||||
$aItem['compare'] = false;
|
||||
}
|
||||
else if (APP_VERSION === APP_DEV_VERSION)
|
||||
{
|
||||
$aItem['canBeUpdated'] = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $aResult;
|
||||
|
@ -2901,111 +2866,61 @@ class Actions
|
|||
/**
|
||||
* @return array
|
||||
*/
|
||||
public function DoAdminPackageDelete()
|
||||
public function DoAdminCoreData()
|
||||
{
|
||||
$this->IsAdminLoggined();
|
||||
|
||||
$sId = $this->GetActionParam('Id', '');
|
||||
|
||||
$bReal = false;
|
||||
$bRainLoopUpdatable = false;
|
||||
$aList = $this->getRepositoryData($bReal, $bRainLoopUpdatable);
|
||||
$aData = array();
|
||||
|
||||
$sResultId = '';
|
||||
foreach ($aList as $oItem)
|
||||
$bRainLoopUpdatable = $this->rainLoopUpdatable();
|
||||
$bRainLoopAccess = $this->rainLoopCoreAccess();
|
||||
|
||||
if ($bRainLoopAccess)
|
||||
{
|
||||
if ($oItem && 'plugin' === $oItem['type'] && $sId === $oItem['id'])
|
||||
{
|
||||
$sResultId = $sId;
|
||||
break;
|
||||
}
|
||||
$aData = $this->getCoreData($bReal);
|
||||
}
|
||||
|
||||
$bResult = false;
|
||||
if ('' !== $sResultId)
|
||||
{
|
||||
$bResult = \MailSo\Base\Utils::RecRmDir(APP_PLUGINS_PATH.$sResultId);
|
||||
if ($bResult)
|
||||
{
|
||||
$this->pluginEnable($sResultId, false);
|
||||
}
|
||||
}
|
||||
$sVersion = empty($aData['version']) ? '' : $aData['version'];
|
||||
|
||||
return $this->DefaultResponse(__FUNCTION__, $bResult);
|
||||
return $this->DefaultResponse(__FUNCTION__, array(
|
||||
'Real' => $bReal,
|
||||
'Access' => $bRainLoopAccess,
|
||||
'Updatable' => $bRainLoopUpdatable,
|
||||
'Version' => APP_VERSION,
|
||||
'RemoteVersion' => $sVersion,
|
||||
'RemoteRelease' => empty($aData['release']) ? '' : $aData['release'],
|
||||
'VersionCompare' => \version_compare(APP_VERSION, $sVersion)
|
||||
));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
public function DoAdminPackageInstall()
|
||||
public function DoAdminUpdateCoreData()
|
||||
{
|
||||
$this->IsAdminLoggined();
|
||||
|
||||
$sType = $this->GetActionParam('Type', '');
|
||||
$sId = $this->GetActionParam('Id', '');
|
||||
$sFile = $this->GetActionParam('File', '');
|
||||
|
||||
$this->Logger()->Write('Start package install: '.$sFile.' ('.$sType.')', \MailSo\Log\Enumerations\Type::INFO, 'INSTALLER');
|
||||
|
||||
$sRealFile = '';
|
||||
|
||||
$bReal = false;
|
||||
$bRainLoopUpdatable = false;
|
||||
$aList = $this->getRepositoryData($bReal, $bRainLoopUpdatable);
|
||||
|
||||
if (('plugin' !== $sType && $bRainLoopUpdatable) || 'plugin' === $sType)
|
||||
$bRainLoopUpdatable = $this->rainLoopUpdatable();
|
||||
$bRainLoopAccess = $this->rainLoopCoreAccess();
|
||||
|
||||
$aData = array();
|
||||
if ($bRainLoopUpdatable && $bRainLoopAccess)
|
||||
{
|
||||
foreach ($aList as $oItem)
|
||||
{
|
||||
if ($oItem && $sFile === $oItem['file'] && $sId === $oItem['id'])
|
||||
{
|
||||
$sRealFile = $sFile;
|
||||
break;
|
||||
}
|
||||
}
|
||||
$aData = $this->getCoreData($bReal);
|
||||
}
|
||||
|
||||
$sTmp = '';
|
||||
$bResult = false;
|
||||
if ('' !== $sRealFile)
|
||||
if ($bReal && !empty($aData['file']))
|
||||
{
|
||||
$sUrl = $this->rainloopRepo().$sRealFile;
|
||||
$sTmp = APP_PRIVATE_DATA.md5(microtime(true).$sRealFile).'.zip';
|
||||
$pDest = @fopen($sTmp, 'w+b');
|
||||
if ($pDest)
|
||||
$sTmp = $this->downloadRemotePackageByUrl($aData['file']);
|
||||
if (!empty($sTmp))
|
||||
{
|
||||
$iCode = 0;
|
||||
$sContentType = '';
|
||||
|
||||
@\set_time_limit(60);
|
||||
|
||||
$oHttp = \MailSo\Base\Http::SingletonInstance();
|
||||
$bResult = $oHttp->SaveUrlToFile($sUrl, $pDest, $sTmp, $sContentType, $iCode, $this->Logger(), 60,
|
||||
$this->Config()->Get('labs', 'curl_proxy', ''), $this->Config()->Get('labs', 'curl_proxy_auth', ''));
|
||||
|
||||
if (!$bResult)
|
||||
{
|
||||
$this->Logger()->Write('Cannot save url to temp file: ', \MailSo\Log\Enumerations\Type::ERROR, 'INSTALLER');
|
||||
$this->Logger()->Write($sUrl.' -> '.$sTmp, \MailSo\Log\Enumerations\Type::ERROR, 'INSTALLER');
|
||||
}
|
||||
|
||||
@\fclose($pDest);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->Logger()->Write('Cannot create temp file: '.$sTmp, \MailSo\Log\Enumerations\Type::ERROR, 'INSTALLER');
|
||||
}
|
||||
}
|
||||
|
||||
if ($bResult && '' !== $sTmp)
|
||||
{
|
||||
include_once APP_VERSION_ROOT_PATH.'app/libraries/pclzip/pclzip.lib.php';
|
||||
|
||||
$oArchive = new \PclZip($sTmp);
|
||||
if ('plugin' !== $sType)
|
||||
{
|
||||
$bResult = false;
|
||||
include_once APP_VERSION_ROOT_PATH.'app/libraries/pclzip/pclzip.lib.php';
|
||||
|
||||
$oArchive = new \PclZip($sTmp);
|
||||
$sTmpFolder = APP_PRIVATE_DATA.\md5($sTmp);
|
||||
|
||||
\mkdir($sTmpFolder);
|
||||
|
@ -3059,8 +2974,132 @@ class Actions
|
|||
{
|
||||
$this->Logger()->Write('Cannot create tmp folder: '.$sTmpFolder, \MailSo\Log\Enumerations\Type::ERROR, 'INSTALLER');
|
||||
}
|
||||
|
||||
@\unlink($sTmp);
|
||||
}
|
||||
else
|
||||
}
|
||||
|
||||
return $this->DefaultResponse(__FUNCTION__, $bResult);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
public function DoAdminPackageDelete()
|
||||
{
|
||||
$this->IsAdminLoggined();
|
||||
|
||||
$sId = $this->GetActionParam('Id', '');
|
||||
|
||||
$bReal = false;
|
||||
$bRainLoopUpdatable = false;
|
||||
$aList = $this->getRepositoryData($bReal, $bRainLoopUpdatable);
|
||||
|
||||
$sResultId = '';
|
||||
foreach ($aList as $oItem)
|
||||
{
|
||||
if ($oItem && 'plugin' === $oItem['type'] && $sId === $oItem['id'])
|
||||
{
|
||||
$sResultId = $sId;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
$bResult = false;
|
||||
if ('' !== $sResultId)
|
||||
{
|
||||
$bResult = \MailSo\Base\Utils::RecRmDir(APP_PLUGINS_PATH.$sResultId);
|
||||
if ($bResult)
|
||||
{
|
||||
$this->pluginEnable($sResultId, false);
|
||||
}
|
||||
}
|
||||
|
||||
return $this->DefaultResponse(__FUNCTION__, $bResult);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $sUrl
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
private function downloadRemotePackageByUrl($sUrl)
|
||||
{
|
||||
$bResult = false;
|
||||
$sTmp = APP_PRIVATE_DATA.\md5(\microtime(true).$sUrl).'.zip';
|
||||
$pDest = @\fopen($sTmp, 'w+b');
|
||||
if ($pDest)
|
||||
{
|
||||
$iCode = 0;
|
||||
$sContentType = '';
|
||||
|
||||
@\set_time_limit(90);
|
||||
|
||||
$oHttp = \MailSo\Base\Http::SingletonInstance();
|
||||
$bResult = $oHttp->SaveUrlToFile($sUrl, $pDest, $sTmp, $sContentType, $iCode, $this->Logger(), 60,
|
||||
$this->Config()->Get('labs', 'curl_proxy', ''), $this->Config()->Get('labs', 'curl_proxy_auth', ''));
|
||||
|
||||
if (!$bResult)
|
||||
{
|
||||
$this->Logger()->Write('Cannot save url to temp file: ', \MailSo\Log\Enumerations\Type::ERROR, 'INSTALLER');
|
||||
$this->Logger()->Write($sUrl.' -> '.$sTmp, \MailSo\Log\Enumerations\Type::ERROR, 'INSTALLER');
|
||||
}
|
||||
|
||||
@\fclose($pDest);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->Logger()->Write('Cannot create temp file: '.$sTmp, \MailSo\Log\Enumerations\Type::ERROR, 'INSTALLER');
|
||||
}
|
||||
|
||||
return $bResult ? $sTmp : '';
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
public function DoAdminPackageInstall()
|
||||
{
|
||||
$this->IsAdminLoggined();
|
||||
|
||||
$sType = $this->GetActionParam('Type', '');
|
||||
$sId = $this->GetActionParam('Id', '');
|
||||
$sFile = $this->GetActionParam('File', '');
|
||||
|
||||
$this->Logger()->Write('Start package install: '.$sFile.' ('.$sType.')', \MailSo\Log\Enumerations\Type::INFO, 'INSTALLER');
|
||||
|
||||
$sRealFile = '';
|
||||
|
||||
$bReal = false;
|
||||
$bRainLoopUpdatable = false;
|
||||
$aList = $this->getRepositoryData($bReal, $bRainLoopUpdatable);
|
||||
|
||||
if ('plugin' === $sType)
|
||||
{
|
||||
foreach ($aList as $oItem)
|
||||
{
|
||||
if ($oItem && $sFile === $oItem['file'] && $sId === $oItem['id'])
|
||||
{
|
||||
$sRealFile = $sFile;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$sTmp = '';
|
||||
$bResult = false;
|
||||
if ('' !== $sRealFile)
|
||||
{
|
||||
$sUrl = $this->rainloopRepo().$sRealFile;
|
||||
$sTmp = $this->downloadRemotePackageByUrl($sUrl);
|
||||
}
|
||||
|
||||
if ('' !== $sTmp)
|
||||
{
|
||||
include_once APP_VERSION_ROOT_PATH.'app/libraries/pclzip/pclzip.lib.php';
|
||||
|
||||
$oArchive = new \PclZip($sTmp);
|
||||
if ('plugin' === $sType)
|
||||
{
|
||||
$bResult = true;
|
||||
if (\is_dir(APP_PLUGINS_PATH.$sId))
|
||||
|
|
|
@ -107,7 +107,7 @@ class Application extends \RainLoop\Config\AbstractConfig
|
|||
'allow_admin_panel' => array(true, 'Access settings'),
|
||||
'allow_two_factor_auth' => array(false),
|
||||
'admin_panel_host' => array(''),
|
||||
'core_install_access_domains' => array('')
|
||||
'core_install_access_domain' => array('')
|
||||
),
|
||||
|
||||
'login' => array(
|
||||
|
@ -236,9 +236,6 @@ Enables caching in the system'),
|
|||
'imap_forwarded_flag' => array('$Forwarded'),
|
||||
'imap_read_receipt_flag' => array('$ReadReceipt'),
|
||||
'smtp_show_server_errors' => array(false),
|
||||
'repo_type' => array('stable'),
|
||||
'custom_repo' => array(''),
|
||||
'additional_repo' => array(''),
|
||||
'curl_proxy' => array(''),
|
||||
'curl_proxy_auth' => array(''),
|
||||
'in_iframe' => array(false),
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
Admin Panel
|
||||
|
||||
(<span data-bind="text: adminDomain"></span> – <span data-bind="text: version"></span>)
|
||||
(<span data-bind="text: adminDomain"></span>)
|
||||
</h4>
|
||||
<div class="btn-group pull-right">
|
||||
<a class="btn btn-narrow" data-bind="click: logoutClick">
|
||||
|
|
|
@ -3,20 +3,60 @@
|
|||
<div class="legend">
|
||||
About
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<div class="raw">
|
||||
<div class="span4">
|
||||
<div class="rl-logo"></div>
|
||||
</div>
|
||||
<div class="span4">
|
||||
RainLoop Webmail
|
||||
<div class="row" style="min-width: 800px;">
|
||||
<div class="span4">
|
||||
<div class="rl-logo"></div>
|
||||
<div style="margin-left: 45px;">
|
||||
2014 © All Rights Reserved.
|
||||
<br />
|
||||
v<span data-bind="text: version"></span>
|
||||
<a class="g-ui-link" href="http://rainloop.net/" target="_blank">http://rainloop.net/</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
|
||||
<div class="span6 rl-desc">
|
||||
<h1 style="margin-bottom: 0;">RainLoop</h1>
|
||||
<h4 style="margin-top: 0;"><span data-bind="text: version"></span></h4>
|
||||
<h4 style="color: #aaa; font-weight: normal;">Simple, modern & fast web-based email client</h4>
|
||||
<h5 style="color: #aaa; font-weight: normal; margin-top: 40px;">
|
||||
<div data-bind="visible: 'error' === statusType()">
|
||||
<i class="icon-warning" style="color: red"></i>
|
||||
|
||||
<span data-bind="text: errorDesc">Error</span>
|
||||
</div>
|
||||
<div data-bind="visible: 'available' === statusType()">
|
||||
<i class="icon-warning" style="color: blue"></i>
|
||||
|
||||
New <b data-bind="text: coreRemoteVersion"></b> version is available.
|
||||
<span data-bind="visible: '' !== coreRemoteRelease()">
|
||||
(<span data-bind="text: coreRemoteRelease"></span>)
|
||||
</span>
|
||||
<br />
|
||||
<span data-bind="visible: coreUpdatable() && coreAccess()">
|
||||
<span class="g-ui-link" data-bind="click: updateCoreData">Update</span>
|
||||
|
||||
</span>
|
||||
<span data-bind="visible: coreAccess()">
|
||||
<a class="g-ui-link" href="http://rainloop.net/downloads/" target="_blank">Download</a>
|
||||
|
||||
<a class="g-ui-link" href="http://rainloop.net/changelog/" target="_blank">Changelog</a>
|
||||
</span>
|
||||
</div>
|
||||
<div data-bind="visible: 'up-to-date' === statusType()">
|
||||
<i class="icon-ok" style="color: green"></i>
|
||||
|
||||
RainLoop is up to date.
|
||||
</div>
|
||||
<div data-bind="visible: 'updating' === statusType()">
|
||||
<i class="icon-spinner animated"></i>
|
||||
|
||||
Updating…
|
||||
</div>
|
||||
<div data-bind="visible: 'checking' === statusType()">
|
||||
<i class="icon-spinner animated"></i>
|
||||
|
||||
Checking for updates…
|
||||
</div>
|
||||
</h5>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
|
@ -1,6 +1,6 @@
|
|||
<div class="b-admin-general">
|
||||
<div class="row" data-bind="visible: !contactsSupported">
|
||||
<div class="alert span8">
|
||||
<div class="alert span8" style="margin-top: 10px;">
|
||||
<h4>Notice!</h4>
|
||||
<br />
|
||||
Your system doesn't support contacts.
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
<div class="b-admin-general">
|
||||
<div class="row" data-bind="visible: weakPassword">
|
||||
<div class="alert alert-error span8">
|
||||
<h4>Warning!</h4>
|
||||
<br />
|
||||
You are using the default admin password.
|
||||
<br />
|
||||
For security reasons please <strong><a href="#/security">change</a></strong>
|
||||
password to something else now.
|
||||
<div class="alert alert-error span8" style="margin-top: 10px;">
|
||||
<h4>Warning!</h4>
|
||||
<br />
|
||||
You are using the default admin password.
|
||||
<br />
|
||||
For security reasons please <strong><a href="#/security">change</a></strong>
|
||||
password to something else now.
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-horizontal">
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<div class="b-admin-licensing" >
|
||||
<div class="row">
|
||||
<div class="alert alert-info span10">
|
||||
<div class="alert alert-info span10" style="margin-top: 10px;">
|
||||
RainLoop Webmail is licensed under <strong>Creative Commons
|
||||
<br />
|
||||
Attribution-NonCommercial-ShareAlike 3.0 Unported (CC BY-NC-SA 3.0)</strong> license.
|
||||
|
|
|
@ -1,20 +1,14 @@
|
|||
<div class="b-admin-packages">
|
||||
|
||||
<div class="alert" data-bind="visible: !packagesReal() && !packagesLoading()">
|
||||
<div class="alert" style="margin-top: 10px;" data-bind="visible: !packagesReal() && !packagesLoading()">
|
||||
Cannot access the repository at the moment.
|
||||
</div>
|
||||
|
||||
<div class="alert" data-bind="visible: '' !== packagesError()">
|
||||
<div class="alert" style="margin-top: 10px;" data-bind="visible: '' !== packagesError()">
|
||||
<button type="button" class="close" data-bind="click: function () { packagesError('') }">×</button>
|
||||
<span data-bind="text: packagesError"></span>
|
||||
</div>
|
||||
|
||||
<!-- <div class="process-place" data-bind="style: {'visibility': visibility }">
|
||||
<i class="icon-spinner animated"></i>
|
||||
|
||||
loading...
|
||||
</div>
|
||||
-->
|
||||
<div data-bind="visible: 0 < packagesAvailableForUpdate().length">
|
||||
<div class="legend">
|
||||
Available for Update (<span data-bind="text: packagesAvailableForUpdate().length"></span>)
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<tr class="e-item">
|
||||
<td class="package-name-parent">
|
||||
<i class="package-img" data-bind="css: 'core' === type ? 'icon-fire' : 'icon-bolt'"></i>
|
||||
<span class="package-name" data-bind="text: name, css: {'core': 'core' === type}"></span>
|
||||
<i class="package-img icon-bolt"></i>
|
||||
<span class="package-name" data-bind="text: name"></span>
|
||||
<span class="package-installed pull-right" data-bind="text: installed"></span>
|
||||
<div class="package-desc" data-bind="text: desc"></div>
|
||||
</td>
|
||||
|
|
|
@ -1,18 +1,12 @@
|
|||
<div class="b-admin-plugins g-ui-user-select-none">
|
||||
|
||||
<div class="row">
|
||||
<div class="alert span8" data-bind="visible: '' !== pluginsError()">
|
||||
<div class="alert span8" style="margin-top: 10px;" data-bind="visible: '' !== pluginsError()">
|
||||
<button type="button" class="close" data-bind="click: function () { pluginsError('') }">×</button>
|
||||
<span data-bind="text: pluginsError"></span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <div class="process-place" data-bind="style: {'visibility': visibility }">
|
||||
<i class="icon-spinner animated"></i>
|
||||
|
||||
loading...
|
||||
</div>-->
|
||||
|
||||
<div class="legend">
|
||||
Plugins
|
||||
</div>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<div class="adminSecurity">
|
||||
<div class="row">
|
||||
<div class="alert alert-info span10">
|
||||
<div class="alert alert-info span10" style="margin-top: 10px;">
|
||||
Detailed information on social integration is found at
|
||||
<a href="http://rainloop.net/docs/social/" target="_blank">http://rainloop.net/docs/social/</a>
|
||||
</div>
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
define('APP_DEV_VERSION', '0.0.0');
|
||||
define('APP_API_PATH', 'http://api.rainloop.net/');
|
||||
define('APP_REP_PATH', 'http://repository.rainloop.net/v1/');
|
||||
define('APP_REPO_CORE_FILE', 'http://repository.rainloop.net/v2/core.json');
|
||||
define('APP_WEB_PATH', 'rainloop/v/'.APP_VERSION.'/');
|
||||
define('APP_WEB_STATIC_PATH', APP_WEB_PATH.'static/');
|
||||
define('APP_DATA_FOLDER_PATH_UNIX', str_replace('\\', '/', APP_DATA_FOLDER_PATH));
|
||||
|
|
|
@ -9011,6 +9011,7 @@ html.rl-message-fullscreen .messageView .b-content .buttonFull {
|
|||
}
|
||||
.b-admin-right .b-settings-content {
|
||||
padding: 20px;
|
||||
padding-left: 30px;
|
||||
}
|
||||
.b-admin-general .flag-selector {
|
||||
padding-top: 5px;
|
||||
|
@ -9182,8 +9183,14 @@ html.rl-message-fullscreen .messageView .b-content .buttonFull {
|
|||
display: inline-block;
|
||||
width: 250px;
|
||||
height: 250px;
|
||||
margin-top: -10px;
|
||||
margin-bottom: -10px;
|
||||
background-image: url("images/rainloop-logo.png");
|
||||
}
|
||||
.b-admin-about .rl-desc {
|
||||
margin-top: 20px;
|
||||
margin-left: -20px;
|
||||
}
|
||||
.popups .b-activate-content {
|
||||
width: 700px;
|
||||
}
|
||||
|
@ -9270,6 +9277,7 @@ html.rl-message-fullscreen .messageView .b-content .buttonFull {
|
|||
}
|
||||
.b-settins-right .b-settings-content {
|
||||
padding: 20px;
|
||||
padding-left: 30px;
|
||||
}
|
||||
.b-settings-general .notification-desc-denied {
|
||||
color: #999;
|
||||
|
|
2
rainloop/v/0.0.0/static/css/app.min.css
vendored
2
rainloop/v/0.0.0/static/css/app.min.css
vendored
File diff suppressed because one or more lines are too long
|
@ -6920,15 +6920,75 @@ AdminLicensing.prototype.licenseExpiredMomentValue = function ()
|
|||
*/
|
||||
function AdminAbout()
|
||||
{
|
||||
var oData = RL.data();
|
||||
|
||||
this.version = ko.observable(RL.settingsGet('Version'));
|
||||
this.access = ko.observable(!!RL.settingsGet('CoreAccess'));
|
||||
this.errorDesc = ko.observable('');
|
||||
|
||||
this.coreReal = oData.coreReal;
|
||||
this.coreUpdatable = oData.coreUpdatable;
|
||||
this.coreAccess = oData.coreAccess;
|
||||
this.coreChecking = oData.coreChecking;
|
||||
this.coreUpdating = oData.coreUpdating;
|
||||
this.coreRemoteVersion = oData.coreRemoteVersion;
|
||||
this.coreRemoteRelease = oData.coreRemoteRelease;
|
||||
this.coreVersionCompare = oData.coreVersionCompare;
|
||||
|
||||
this.statusType = ko.computed(function () {
|
||||
|
||||
var
|
||||
sType = '',
|
||||
iVersionCompare = this.coreVersionCompare(),
|
||||
bChecking = this.coreChecking(),
|
||||
bUpdating = this.coreUpdating(),
|
||||
bReal = this.coreReal()
|
||||
;
|
||||
|
||||
if (bChecking)
|
||||
{
|
||||
sType = 'checking';
|
||||
}
|
||||
else if (bUpdating)
|
||||
{
|
||||
sType = 'updating';
|
||||
}
|
||||
else if (bReal && 0 === iVersionCompare)
|
||||
{
|
||||
sType = 'up-to-date';
|
||||
}
|
||||
else if (bReal && -1 === iVersionCompare)
|
||||
{
|
||||
sType = 'available';
|
||||
}
|
||||
else if (!bReal)
|
||||
{
|
||||
sType = 'error';
|
||||
this.errorDesc('Cannot access the repository at the moment.');
|
||||
}
|
||||
|
||||
return sType;
|
||||
|
||||
}, this);
|
||||
}
|
||||
|
||||
Utils.addSettingsViewModel(AdminAbout, 'AdminSettingsAbout', 'About', 'about');
|
||||
|
||||
//AdminAbout.prototype.onBuild = function ()
|
||||
//{
|
||||
//
|
||||
//};
|
||||
AdminAbout.prototype.onBuild = function ()
|
||||
{
|
||||
if (this.access())
|
||||
{
|
||||
RL.reloadCoreData();
|
||||
}
|
||||
};
|
||||
|
||||
AdminAbout.prototype.updateCoreData = function ()
|
||||
{
|
||||
if (!this.coreUpdating())
|
||||
{
|
||||
RL.updateCoreData();
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
|
@ -7080,6 +7140,15 @@ function AdminDataStorage()
|
|||
this.packagesLoading = ko.observable(false).extend({'throttle': 100});
|
||||
this.packages = ko.observableArray([]);
|
||||
|
||||
this.coreReal = ko.observable(true);
|
||||
this.coreUpdatable = ko.observable(true);
|
||||
this.coreAccess = ko.observable(true);
|
||||
this.coreChecking = ko.observable(false).extend({'throttle': 100});
|
||||
this.coreUpdating = ko.observable(false).extend({'throttle': 100});
|
||||
this.coreRemoteVersion = ko.observable('');
|
||||
this.coreRemoteRelease = ko.observable('');
|
||||
this.coreVersionCompare = ko.observable(-2);
|
||||
|
||||
this.licensing = ko.observable(false);
|
||||
this.licensingProcess = ko.observable(false);
|
||||
this.licenseValid = ko.observable(false);
|
||||
|
@ -7444,6 +7513,22 @@ AdminAjaxRemoteStorage.prototype.packagesList = function (fCallback)
|
|||
this.defaultRequest(fCallback, 'AdminPackagesList');
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
*/
|
||||
AdminAjaxRemoteStorage.prototype.coreData = function (fCallback)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'AdminCoreData');
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
*/
|
||||
AdminAjaxRemoteStorage.prototype.updateCoreData = function (fCallback)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'AdminUpdateCoreData', {}, 90000);
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
* @param {Object} oPackage
|
||||
|
@ -7925,8 +8010,6 @@ _.extend(AdminSettingsScreen.prototype, AbstractSettings.prototype);
|
|||
|
||||
AdminSettingsScreen.prototype.onShow = function ()
|
||||
{
|
||||
// AbstractSettings.prototype.onShow.call(this);
|
||||
|
||||
RL.setTitle('');
|
||||
};
|
||||
/**
|
||||
|
@ -8432,6 +8515,61 @@ AdminApp.prototype.reloadPackagesList = function ()
|
|||
});
|
||||
};
|
||||
|
||||
AdminApp.prototype.updateCoreData = function ()
|
||||
{
|
||||
var oRainData = RL.data();
|
||||
|
||||
oRainData.coreUpdating(true);
|
||||
RL.remote().updateCoreData(function (sResult, oData) {
|
||||
|
||||
oRainData.coreUpdating(false);
|
||||
oRainData.coreRemoteVersion('');
|
||||
oRainData.coreRemoteRelease('');
|
||||
oRainData.coreVersionCompare(-2);
|
||||
|
||||
if (Enums.StorageResultType.Success === sResult && oData && oData.Result)
|
||||
{
|
||||
oRainData.coreReal(true);
|
||||
window.location.reload();
|
||||
}
|
||||
else
|
||||
{
|
||||
oRainData.coreReal(false);
|
||||
}
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
AdminApp.prototype.reloadCoreData = function ()
|
||||
{
|
||||
var oRainData = RL.data();
|
||||
|
||||
oRainData.coreChecking(true);
|
||||
oRainData.coreReal(true);
|
||||
|
||||
RL.remote().coreData(function (sResult, oData) {
|
||||
|
||||
oRainData.coreChecking(false);
|
||||
|
||||
if (Enums.StorageResultType.Success === sResult && oData && oData.Result)
|
||||
{
|
||||
oRainData.coreReal(!!oData.Result.Real);
|
||||
oRainData.coreUpdatable(!!oData.Result.Updatable);
|
||||
oRainData.coreAccess(!!oData.Result.Access);
|
||||
oRainData.coreRemoteVersion(oData.Result.RemoteVersion || '');
|
||||
oRainData.coreRemoteRelease(oData.Result.RemoteRelease || '');
|
||||
oRainData.coreVersionCompare(Utils.pInt(oData.Result.VersionCompare));
|
||||
}
|
||||
else
|
||||
{
|
||||
oRainData.coreReal(false);
|
||||
oRainData.coreRemoteVersion('');
|
||||
oRainData.coreRemoteRelease('');
|
||||
oRainData.coreVersionCompare(-2);
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
*
|
||||
* @param {boolean=} bForce = false
|
||||
|
@ -8499,7 +8637,7 @@ AdminApp.prototype.bootstart = function ()
|
|||
}
|
||||
else
|
||||
{
|
||||
Utils.removeSettingsViewModel(AdminAbout);
|
||||
// Utils.removeSettingsViewModel(AdminAbout);
|
||||
|
||||
if (!RL.capa(Enums.Capa.Prem))
|
||||
{
|
||||
|
|
8
rainloop/v/0.0.0/static/js/admin.min.js
vendored
8
rainloop/v/0.0.0/static/js/admin.min.js
vendored
File diff suppressed because one or more lines are too long
|
@ -18501,8 +18501,6 @@ _.extend(SettingsScreen.prototype, AbstractSettings.prototype);
|
|||
|
||||
SettingsScreen.prototype.onShow = function ()
|
||||
{
|
||||
// AbstractSettings.prototype.onShow.call(this);
|
||||
|
||||
RL.setTitle(this.sSettingsTitle);
|
||||
RL.data().keyScope(Enums.KeyState.Settings);
|
||||
};
|
||||
|
|
Loading…
Add table
Reference in a new issue