Improvement enable features enterprise
This commit is contained in:
@@ -5279,7 +5279,8 @@ class G
|
|||||||
$sflagAudit = $oServerConf->getAuditLogProperty( 'AL_OPTION', SYS_SYS );
|
$sflagAudit = $oServerConf->getAuditLogProperty( 'AL_OPTION', SYS_SYS );
|
||||||
$ipClient = G::getIpAddress();
|
$ipClient = G::getIpAddress();
|
||||||
|
|
||||||
if ($sflagAudit) {
|
$licensedFeatures = & PMLicensedFeatures::getSingleton();
|
||||||
|
if ($sflagAudit && $licensedFeatures->verifyfeature('vtSeHNhT0JnSmo1bTluUVlTYUxUbUFSVStEeXVqc1pEUG5EeXc0MGd2Q3ErYz0=')) {
|
||||||
$workspace = defined('SYS_SYS') ? SYS_SYS : 'Wokspace Undefined';
|
$workspace = defined('SYS_SYS') ? SYS_SYS : 'Wokspace Undefined';
|
||||||
$username = isset($_SESSION['USER_LOGGED']) && $_SESSION['USER_LOGGED'] != '' ? $_SESSION['USER_LOGGED'] : 'Unknow User';
|
$username = isset($_SESSION['USER_LOGGED']) && $_SESSION['USER_LOGGED'] != '' ? $_SESSION['USER_LOGGED'] : 'Unknow User';
|
||||||
$fullname = isset($_SESSION['USR_FULLNAME']) && $_SESSION['USR_FULLNAME'] != '' ? $_SESSION['USR_FULLNAME'] : '-';
|
$fullname = isset($_SESSION['USR_FULLNAME']) && $_SESSION['USR_FULLNAME'] != '' ? $_SESSION['USR_FULLNAME'] : '-';
|
||||||
|
|||||||
5
gulliver/thirdparty/propel/Propel.php
vendored
5
gulliver/thirdparty/propel/Propel.php
vendored
@@ -614,6 +614,11 @@ class Propel {
|
|||||||
*/
|
*/
|
||||||
public static function getDbConnection($name)
|
public static function getDbConnection($name)
|
||||||
{
|
{
|
||||||
|
$licensedFeatures = & PMLicensedFeatures::getSingleton();
|
||||||
|
if (! $licensedFeatures->verifyfeature('02YeEFKNnVoOWFKMzN4ZmpXT0V3MU9SVklnOXNCcE9zcXJKa0tpemNmQkJ5OTUvOWlLdFhibGp0MHVHUlV0VmNpNw==')) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
if (! empty(self::$configuration['datasources'][$name]['connection'])) {
|
if (! empty(self::$configuration['datasources'][$name]['connection'])) {
|
||||||
return self::getConnection($name);
|
return self::getConnection($name);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -118,7 +118,18 @@ function change_hash($command, $opts)
|
|||||||
$response = new stdclass();
|
$response = new stdclass();
|
||||||
$response->workspace = $workspace;
|
$response->workspace = $workspace;
|
||||||
$response->hash = $hash;
|
$response->hash = $hash;
|
||||||
$workspace->changeHashPassword($workspace->name, $response);
|
if (!defined("SYS_SYS")) {
|
||||||
|
define("SYS_SYS", $workspace->name);
|
||||||
|
}
|
||||||
|
if (!defined("PATH_DATA_SITE")) {
|
||||||
|
define("PATH_DATA_SITE", PATH_DATA . "sites/" . SYS_SYS . "/");
|
||||||
|
}
|
||||||
|
$_SESSION['__sw__'] = '';
|
||||||
|
if (!$workspace->changeHashPassword($workspace->name, $response)) {
|
||||||
|
CLI::logging(pakeColor::colorize("This command cannot be used because your license does not include it.", "ERROR") . "\n");
|
||||||
|
$workspace->close();
|
||||||
|
die;
|
||||||
|
}
|
||||||
$workspace->close();
|
$workspace->close();
|
||||||
CLI::logging(pakeColor::colorize("Changed...", "ERROR") . "\n");
|
CLI::logging(pakeColor::colorize("Changed...", "ERROR") . "\n");
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
|
|||||||
@@ -65,25 +65,19 @@ class PMLicensedFeatures
|
|||||||
|
|
||||||
public function verifyfeature ($featureName)
|
public function verifyfeature ($featureName)
|
||||||
{
|
{
|
||||||
|
if (!class_exists("pmLicenseManager")) {
|
||||||
|
require_once ("classes" . PATH_SEP . "class.pmLicenseManager.php");
|
||||||
|
}
|
||||||
$licenseManager = &pmLicenseManager::getSingleton();
|
$licenseManager = &pmLicenseManager::getSingleton();
|
||||||
|
|
||||||
$_SESSION['__sw__'] = true;
|
$_SESSION['__sw__'] = true;
|
||||||
$padl = new padl();
|
$padl = new padl();
|
||||||
|
$value = $padl->_decrypt($featureName);
|
||||||
|
|
||||||
$enable = in_array($padl->_decrypt($featureName), $licenseManager->features);
|
$enable = in_array($value[0], $licenseManager->licensedfeatures);
|
||||||
|
|
||||||
$this->featuresDetails[$padl->_decrypt($featureName)]->enabled = $enable;
|
$this->featuresDetails[$value[0]]->enabled = $enable;
|
||||||
return $enable;
|
return $enable;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function loadSingleton($file)
|
|
||||||
{
|
|
||||||
self::$instancefeature = unserialize(file_get_contents($file));
|
|
||||||
|
|
||||||
if (! is_object(self::$instancefeature) || get_class(self::$instancefeature) != "PMLicensedFeatures") {
|
|
||||||
throw new Exception("Can't load main PMLicensedFeatures object.");
|
|
||||||
}
|
|
||||||
|
|
||||||
return self::$instancefeature;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -920,7 +920,8 @@ class wsBase
|
|||||||
if (!class_exists('System')) {
|
if (!class_exists('System')) {
|
||||||
G::LoadClass('system');
|
G::LoadClass('system');
|
||||||
}
|
}
|
||||||
$aSetup = !empty($config) ? $config : System::getEmailConfiguration();
|
$licensedFeatures = & PMLicensedFeatures::getSingleton();
|
||||||
|
$aSetup = (!empty($config) && $licensedFeatures->verifyfeature('nKaNTNuT1MzK0RsMEtXTnYzR09ucHF2WGNuS0hRdDBBak42WXJhNVVOOG1INEVoaU1EaTllbjBBeEJNeG9wRVJ6NmxQelhyVTBvdThzPQ==') ) ? $config : System::getEmailConfiguration();
|
||||||
|
|
||||||
$oSpool = new spoolRun();
|
$oSpool = new spoolRun();
|
||||||
|
|
||||||
|
|||||||
@@ -1668,7 +1668,13 @@ class workspaceTools
|
|||||||
{
|
{
|
||||||
$this->initPropel( true );
|
$this->initPropel( true );
|
||||||
G::LoadClass("enterprise");
|
G::LoadClass("enterprise");
|
||||||
enterpriseClass::setHashPassword($response);
|
$licensedFeatures = & PMLicensedFeatures::getSingleton();
|
||||||
|
if ($licensedFeatures->verifyfeature('95OY24wcXpEMzIyRmlNSnF0STNFSHJzMG9wYTJKekpLNmY2ZmRCeGtuZk5oUDloaUNhUGVjTDJBPT0=')) {
|
||||||
|
enterpriseClass::setHashPassword($response);
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function verifyEnterprise ($workspace)
|
public function verifyEnterprise ($workspace)
|
||||||
|
|||||||
@@ -28,6 +28,7 @@ $partnerFlag = (defined('PARTNER_FLAG')) ? PARTNER_FLAG : false;
|
|||||||
|
|
||||||
$oServerConf = & serverConf::getSingleton();
|
$oServerConf = & serverConf::getSingleton();
|
||||||
$sAudit = $oServerConf->getAuditLogProperty( 'AL_OPTION', SYS_SYS );
|
$sAudit = $oServerConf->getAuditLogProperty( 'AL_OPTION', SYS_SYS );
|
||||||
|
$licensedFeatures = & PMLicensedFeatures::getSingleton();
|
||||||
|
|
||||||
if ($RBAC->userCanAccess('PM_SETUP') == 1 ) {
|
if ($RBAC->userCanAccess('PM_SETUP') == 1 ) {
|
||||||
//settings options
|
//settings options
|
||||||
@@ -98,7 +99,7 @@ if ($RBAC->userCanAccess('PM_SETUP') == 1) {
|
|||||||
$G_TMP_MENU->AddIdRawOption('LOG_CASE_SCHEDULER', '../cases/cases_Scheduler_Log', G::LoadTranslation('ID_CASE_SCHEDULER'), "icon-logs-list.png",'', 'logs');
|
$G_TMP_MENU->AddIdRawOption('LOG_CASE_SCHEDULER', '../cases/cases_Scheduler_Log', G::LoadTranslation('ID_CASE_SCHEDULER'), "icon-logs-list.png",'', 'logs');
|
||||||
$G_TMP_MENU->AddIdRawOption("CRON", "../setup/cron", G::LoadTranslation("ID_CRON_ACTIONS"), null, null, "logs");
|
$G_TMP_MENU->AddIdRawOption("CRON", "../setup/cron", G::LoadTranslation("ID_CRON_ACTIONS"), null, null, "logs");
|
||||||
$G_TMP_MENU->AddIdRawOption('EMAILS', '../mails/emailList', ucfirst (strtolower ( G::LoadTranslation('ID_EMAILS'))), '', '', 'logs');
|
$G_TMP_MENU->AddIdRawOption('EMAILS', '../mails/emailList', ucfirst (strtolower ( G::LoadTranslation('ID_EMAILS'))), '', '', 'logs');
|
||||||
if (isset($sAudit) && $sAudit != false) {
|
if (isset($sAudit) && $sAudit != false && $licensedFeatures->verifyfeature('vtSeHNhT0JnSmo1bTluUVlTYUxUbUFSVStEeXVqc1pEUG5EeXc0MGd2Q3ErYz0=')) {
|
||||||
$G_TMP_MENU->AddIdRawOption('AUDIT_LOG', '../setup/auditLog', ucfirst (G::LoadTranslation('ID_AUDITLOG_DISPLAY')), '', '', 'logs');
|
$G_TMP_MENU->AddIdRawOption('AUDIT_LOG', '../setup/auditLog', ucfirst (G::LoadTranslation('ID_AUDITLOG_DISPLAY')), '', '', 'logs');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -107,7 +108,9 @@ if ($RBAC->userCanAccess("PM_SETUP") == 1) {
|
|||||||
$G_TMP_MENU->AddIdRawOption("PM_REQUIREMENTS", "../setup/systemInfo", G::LoadTranslation("ID_PROCESSMAKER_REQUIREMENTS_CHECK"), "", "", "settings");
|
$G_TMP_MENU->AddIdRawOption("PM_REQUIREMENTS", "../setup/systemInfo", G::LoadTranslation("ID_PROCESSMAKER_REQUIREMENTS_CHECK"), "", "", "settings");
|
||||||
$G_TMP_MENU->AddIdRawOption("PHP_INFO", "../setup/systemInfo?option=php", G::LoadTranslation("ID_PHP_INFO"), "", "", "settings");
|
$G_TMP_MENU->AddIdRawOption("PHP_INFO", "../setup/systemInfo?option=php", G::LoadTranslation("ID_PHP_INFO"), "", "", "settings");
|
||||||
//$G_TMP_MENU->AddIdRawOption("PHP_MAINTENANCE", "../admin/maintenance", 'Maintenance', "", "", "settings");
|
//$G_TMP_MENU->AddIdRawOption("PHP_MAINTENANCE", "../admin/maintenance", 'Maintenance', "", "", "settings");
|
||||||
$G_TMP_MENU->AddIdRawOption("AUDIT_LOG", "auditLogConfig", G::LoadTranslation("ID_AUDITLOG_DISPLAY"), "", "", "settings");
|
if ($licensedFeatures->verifyfeature('vtSeHNhT0JnSmo1bTluUVlTYUxUbUFSVStEeXVqc1pEUG5EeXc0MGd2Q3ErYz0=')) {
|
||||||
|
$G_TMP_MENU->AddIdRawOption("AUDIT_LOG", "auditLogConfig", G::LoadTranslation("ID_AUDITLOG_DISPLAY"), "", "", "settings");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
require_once 'classes/class.pmLicenseManager.php';
|
require_once 'classes/class.pmLicenseManager.php';
|
||||||
|
|||||||
@@ -1709,7 +1709,7 @@ Ext.onReady(function() {
|
|||||||
title: _('ID_ENTERPRISE_PLUGINS'),
|
title: _('ID_ENTERPRISE_PLUGINS'),
|
||||||
items : addonsGrid
|
items : addonsGrid
|
||||||
},{
|
},{
|
||||||
title: _('ID_ENTERPRISE_FIXTURES'),
|
title: _('ID_ENTERPRISE_FEATURES'),
|
||||||
items : addonsFeatureGrid
|
items : addonsFeatureGrid
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
Reference in New Issue
Block a user