Merge branch 'ent-12810-visualizacion-de-tipo-de-licencia' into 'develop'
Ent 12810 Visualizacion de tipo de licencia See merge request artica/pandorafms!6907
This commit is contained in:
commit
4b40a8e9c5
|
@ -483,7 +483,7 @@ class Diagnostics extends Wizard
|
|||
],
|
||||
'isEnterprise' => [
|
||||
'name' => __('Enterprise installed'),
|
||||
'value' => (enterprise_installed()) ? __('true') : __('false'),
|
||||
'value' => $this->getStatusLicense(),
|
||||
],
|
||||
'customerKey' => [
|
||||
'name' => __('Update Key'),
|
||||
|
@ -505,6 +505,29 @@ class Diagnostics extends Wizard
|
|||
}
|
||||
|
||||
|
||||
/**
|
||||
* Return status of license.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
private function getStatusLicense():string
|
||||
{
|
||||
global $config;
|
||||
|
||||
if (enterprise_installed() === true) {
|
||||
if (isset($config['license_mode'])
|
||||
&& (int) $config['license_mode'] === 1
|
||||
) {
|
||||
return __('FREE/TRIAL');
|
||||
} else {
|
||||
return __('LICENSED');
|
||||
}
|
||||
} else {
|
||||
return __('OpenSource');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* PHP Status.
|
||||
*
|
||||
|
|
|
@ -98,25 +98,6 @@ function update_manager_get_current_package()
|
|||
}
|
||||
|
||||
|
||||
/**
|
||||
* Check if a trial license is in use.
|
||||
*
|
||||
* @return boolean true if a trial license is in use, false otherwise.
|
||||
*/
|
||||
function update_manager_verify_trial()
|
||||
{
|
||||
global $config;
|
||||
|
||||
if (isset($config['license_licensed_to'])
|
||||
&& strstr($config['license_licensed_to'], 'info@pandorafms.com') !== false
|
||||
) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Checks if there are packages available to be installed.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue