Merge branch 'master' of bitbucket.org:colosa/processmaker into PM-2754
This commit is contained in:
@@ -5353,12 +5353,14 @@ class G
|
||||
$sflagAudit = $oServerConf->getAuditLogProperty( 'AL_OPTION', $workspace );
|
||||
$ipClient = G::getIpAddress();
|
||||
|
||||
$licensedFeatures = PMLicensedFeatures::getSingleton();
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$licensedFeatures = PMLicensedFeatures::getSingleton();
|
||||
if ($sflagAudit && $licensedFeatures->verifyfeature('vtSeHNhT0JnSmo1bTluUVlTYUxUbUFSVStEeXVqc1pEUG5EeXc0MGd2Q3ErYz0=')) {
|
||||
$username = isset($_SESSION['USER_LOGGED']) && $_SESSION['USER_LOGGED'] != '' ? $_SESSION['USER_LOGGED'] : 'Unknow User';
|
||||
$fullname = isset($_SESSION['USR_FULLNAME']) && $_SESSION['USR_FULLNAME'] != '' ? $_SESSION['USR_FULLNAME'] : '-';
|
||||
G::log("|". $workspace ."|". $ipClient ."|". $username . "|" . $fullname ."|" . $actionToLog . "|" . $valueToLog, PATH_DATA, "audit.log");
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -327,6 +327,7 @@ function database_upgrade($command, $args) {
|
||||
print_r("Checking database in ".pakeColor::colorize($workspace->name, "INFO")."\n");
|
||||
else
|
||||
print_r("Upgrading database in ".pakeColor::colorize($workspace->name, "INFO")."\n");
|
||||
|
||||
try {
|
||||
$changes = $workspace->upgradeDatabase($checkOnly);
|
||||
if ($changes != false) {
|
||||
@@ -346,51 +347,6 @@ function database_upgrade($command, $args) {
|
||||
echo "> Error: ".CLI::error($e->getMessage()) . "\n";
|
||||
}
|
||||
}
|
||||
|
||||
//There records in table "EMAIL_SERVER"
|
||||
$criteria = new Criteria("workflow");
|
||||
|
||||
$criteria->addSelectColumn(EmailServerPeer::MESS_UID);
|
||||
$criteria->setOffset(0);
|
||||
$criteria->setLimit(1);
|
||||
|
||||
$rsCriteria = EmailServerPeer::doSelectRS($criteria);
|
||||
|
||||
if (!$rsCriteria->next()) {
|
||||
//Insert the first record
|
||||
$emailSever = new \ProcessMaker\BusinessModel\EmailServer();
|
||||
|
||||
$emailConfiguration = System::getEmailConfiguration();
|
||||
|
||||
if (count($emailConfiguration) > 0) {
|
||||
$arrayData = array();
|
||||
|
||||
$arrayData["MESS_ENGINE"] = $emailConfiguration["MESS_ENGINE"];
|
||||
$arrayData["MESS_SERVER"] = $emailConfiguration["MESS_SERVER"];
|
||||
$arrayData["MESS_PORT"] = (int)($emailConfiguration["MESS_PORT"]);
|
||||
$arrayData["MESS_RAUTH"] = (int)($emailConfiguration["MESS_RAUTH"]);
|
||||
$arrayData["MESS_ACCOUNT"] = $emailConfiguration["MESS_ACCOUNT"];
|
||||
$arrayData["MESS_PASSWORD"] = $emailConfiguration["MESS_PASSWORD"];
|
||||
$arrayData["MESS_FROM_MAIL"] = isset($emailConfiguration["MESS_FROM_MAIL"]) ? $emailConfiguration["MESS_FROM_MAIL"] : "";
|
||||
$arrayData["MESS_FROM_NAME"] = isset($emailConfiguration["MESS_FROM_NAME"]) ? $emailConfiguration["MESS_FROM_NAME"] : "";
|
||||
$arrayData["SMTPSECURE"] = $emailConfiguration["SMTPSecure"];
|
||||
$arrayData["MESS_TRY_SEND_INMEDIATLY"] = (int)($emailConfiguration["MESS_TRY_SEND_INMEDIATLY"]);
|
||||
$arrayData["MAIL_TO"] = $emailConfiguration["MAIL_TO"];
|
||||
$arrayData["MESS_DEFAULT"] = (isset($emailConfiguration["MESS_ENABLED"]) && $emailConfiguration["MESS_ENABLED"] . "" == "1")? 1 : 0;
|
||||
|
||||
$arrayData = $emailSever->create($arrayData);
|
||||
} else {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (true) {
|
||||
//
|
||||
} else {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$arrayData = $emailSever->create2(array("MESS_ENGINE" => "MAIL"));
|
||||
/*----------------------------------********---------------------------------*/
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function delete_app_from_table($con, $tableName, $appUid, $col="APP_UID") {
|
||||
@@ -680,7 +636,7 @@ function run_check_workspace_disabled_code($args, $opts)
|
||||
}
|
||||
}
|
||||
|
||||
function migrate_new_cases_lists($command, $args) {
|
||||
function migrate_new_cases_lists($command, $args) {
|
||||
$workspaces = get_workspaces_from_args($args);
|
||||
$checkOnly = (strcmp($command, "migrate") == 0);
|
||||
foreach ($workspaces as $workspace) {
|
||||
@@ -701,11 +657,11 @@ function migrate_new_cases_lists($command, $args) {
|
||||
$changes = $workspace->listFirstExecution('check');
|
||||
if ($workspace->onedb && $changes != true) {
|
||||
$workspace->migrateList($workspace->name);
|
||||
}
|
||||
}
|
||||
if ($changes) {
|
||||
if ($checkOnly) {
|
||||
echo "-> List tables are done\n";
|
||||
}
|
||||
}
|
||||
} else {
|
||||
echo "> List tables are done\n";
|
||||
}
|
||||
|
||||
@@ -781,7 +781,75 @@ class workspaceTools
|
||||
$this->upgradeSchema( $systemSchema );
|
||||
$this->upgradeSchema( $systemSchemaRbac, false, true, $onedb ); // perform Upgrade to Rbac
|
||||
$this->upgradeData();
|
||||
|
||||
//There records in table "EMAIL_SERVER"
|
||||
$criteria = new Criteria("workflow");
|
||||
|
||||
$criteria->addSelectColumn(EmailServerPeer::MESS_UID);
|
||||
$criteria->setOffset(0);
|
||||
$criteria->setLimit(1);
|
||||
|
||||
$rsCriteria = EmailServerPeer::doSelectRS($criteria);
|
||||
|
||||
if (!$rsCriteria->next()) {
|
||||
//Insert the first record
|
||||
$arrayData = array();
|
||||
|
||||
$emailSever = new \ProcessMaker\BusinessModel\EmailServer();
|
||||
$emailConfiguration = System::getEmailConfiguration();
|
||||
|
||||
if (count($emailConfiguration) > 0) {
|
||||
$arrayData["MESS_ENGINE"] = $emailConfiguration["MESS_ENGINE"];
|
||||
|
||||
switch ($emailConfiguration["MESS_ENGINE"]) {
|
||||
case "PHPMAILER":
|
||||
$arrayData["MESS_SERVER"] = $emailConfiguration["MESS_SERVER"];
|
||||
$arrayData["MESS_PORT"] = (int)($emailConfiguration["MESS_PORT"]);
|
||||
$arrayData["MESS_RAUTH"] = (is_numeric($emailConfiguration["MESS_RAUTH"]))? (int)($emailConfiguration["MESS_RAUTH"]) : (($emailConfiguration["MESS_RAUTH"] . "" == "true")? 1 : 0);
|
||||
$arrayData["MESS_ACCOUNT"] = $emailConfiguration["MESS_ACCOUNT"];
|
||||
$arrayData["MESS_PASSWORD"] = $emailConfiguration["MESS_PASSWORD"];
|
||||
$arrayData["MESS_FROM_MAIL"] = (isset($emailConfiguration["MESS_FROM_MAIL"]))? $emailConfiguration["MESS_FROM_MAIL"] : "";
|
||||
$arrayData["MESS_FROM_NAME"] = (isset($emailConfiguration["MESS_FROM_NAME"]))? $emailConfiguration["MESS_FROM_NAME"] : "";
|
||||
$arrayData["SMTPSECURE"] = $emailConfiguration["SMTPSecure"];
|
||||
$arrayData["MESS_TRY_SEND_INMEDIATLY"] = (isset($emailConfiguration["MESS_TRY_SEND_INMEDIATLY"]) && ($emailConfiguration["MESS_TRY_SEND_INMEDIATLY"] . "" == "true" || $emailConfiguration["MESS_TRY_SEND_INMEDIATLY"] . "" == "1"))? 1 : 0;
|
||||
$arrayData["MAIL_TO"] = $emailConfiguration["MAIL_TO"];
|
||||
$arrayData["MESS_DEFAULT"] = (isset($emailConfiguration["MESS_ENABLED"]) && $emailConfiguration["MESS_ENABLED"] . "" == "1")? 1 : 0;
|
||||
break;
|
||||
case "MAIL":
|
||||
$arrayData["MESS_SERVER"] = "";
|
||||
$arrayData["MESS_FROM_MAIL"] = (isset($emailConfiguration["MESS_FROM_MAIL"]))? $emailConfiguration["MESS_FROM_MAIL"] : "";
|
||||
$arrayData["MESS_FROM_NAME"] = (isset($emailConfiguration["MESS_FROM_NAME"]))? $emailConfiguration["MESS_FROM_NAME"] : "";
|
||||
$arrayData["MESS_TRY_SEND_INMEDIATLY"] = (isset($emailConfiguration["MESS_TRY_SEND_INMEDIATLY"]) && ($emailConfiguration["MESS_TRY_SEND_INMEDIATLY"] . "" == "true" || $emailConfiguration["MESS_TRY_SEND_INMEDIATLY"] . "" == "1"))? 1 : 0;
|
||||
$arrayData["MESS_ACCOUNT"] = "";
|
||||
$arrayData["MESS_PASSWORD"] = "";
|
||||
$arrayData["MAIL_TO"] = (isset($emailConfiguration["MAIL_TO"]))? $emailConfiguration["MAIL_TO"] : "";
|
||||
$arrayData["MESS_DEFAULT"] = (isset($emailConfiguration["MESS_ENABLED"]) && $emailConfiguration["MESS_ENABLED"] . "" == "1")? 1 : 0;
|
||||
break;
|
||||
}
|
||||
|
||||
$arrayData = $emailSever->create($arrayData);
|
||||
} else {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (true) {
|
||||
//
|
||||
} else {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$arrayData["MESS_ENGINE"] = "MAIL";
|
||||
$arrayData["MESS_SERVER"] = "";
|
||||
$arrayData["MESS_ACCOUNT"] = "";
|
||||
$arrayData["MESS_PASSWORD"] = "";
|
||||
$arrayData["MAIL_TO"] = "";
|
||||
$arrayData["MESS_DEFAULT"] = 1;
|
||||
|
||||
$arrayData = $emailSever->create2($arrayData);
|
||||
/*----------------------------------********---------------------------------*/
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
}
|
||||
}
|
||||
|
||||
p11835::execute();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -1886,7 +1954,7 @@ class workspaceTools
|
||||
$users = new Users();
|
||||
G::LoadClass("case");
|
||||
$case = new Cases();
|
||||
|
||||
|
||||
//Select data CANCELLED
|
||||
$canCriteria = $appCache->getSelAllColumns();
|
||||
$canCriteria->add(AppCacheViewPeer::APP_STATUS, "CANCELLED", CRITERIA::EQUAL);
|
||||
@@ -1902,7 +1970,7 @@ class workspaceTools
|
||||
$listCanceled->create($row);
|
||||
}
|
||||
CLI::logging("> Completed table LIST_CANCELED\n");
|
||||
|
||||
|
||||
//Select data COMPLETED
|
||||
$comCriteria = $appCache->getSelAllColumns();
|
||||
$comCriteria->add(AppCacheViewPeer::APP_STATUS, "COMPLETED", CRITERIA::EQUAL);
|
||||
@@ -1918,7 +1986,7 @@ class workspaceTools
|
||||
$listCompleted->create($row);
|
||||
}
|
||||
CLI::logging("> Completed table LIST_COMPLETED\n");
|
||||
|
||||
|
||||
//Select data TO_DO OR DRAFT
|
||||
$inbCriteria = $appCache->getSelAllColumns();
|
||||
$rsCriteria = AppCacheViewPeer::doSelectRS($inbCriteria);
|
||||
@@ -1967,14 +2035,14 @@ class workspaceTools
|
||||
$listParticipatedLast = new ListParticipatedLast();
|
||||
$listParticipatedLast->refresh($row);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
CLI::logging("> Completed table LIST_INBOX\n");
|
||||
//With this List is populated the LIST_PARTICIPATED_HISTORY and LIST_PARTICIPATED_LAST
|
||||
CLI::logging("> Completed table LIST_PARTICIPATED_HISTORY\n");
|
||||
CLI::logging("> Completed table LIST_PARTICIPATED_LAST\n");
|
||||
|
||||
|
||||
//Select data TO_DO OR DRAFT CASES CREATED BY AN USER
|
||||
$myiCriteria = $appCache->getSelAllColumns();
|
||||
$myiCriteria->add(AppCacheViewPeer::DEL_INDEX, "1", CRITERIA::EQUAL);
|
||||
@@ -1982,14 +2050,14 @@ class workspaceTools
|
||||
$rsCriteria->setFetchmode(ResultSet::FETCHMODE_ASSOC);
|
||||
//Insert new data LIST_MY_INBOX
|
||||
while ($rsCriteria->next()) {
|
||||
$row = $rsCriteria->getRow();
|
||||
$row = $rsCriteria->getRow();
|
||||
$listMyInbox = new ListMyInbox();
|
||||
$listMyInbox ->remove($row["APP_UID"],$row["USR_UID"]);
|
||||
$listMyInbox->setDeleted(false);
|
||||
$listMyInbox->create($row);
|
||||
}
|
||||
CLI::logging("> Completed table LIST_MY_INBOX\n");
|
||||
|
||||
|
||||
//Select data PAUSED
|
||||
$delaycriteria = new Criteria("workflow");
|
||||
$delaycriteria->addSelectColumn(AppDelayPeer::APP_UID);
|
||||
@@ -2015,7 +2083,7 @@ class workspaceTools
|
||||
$listPaused->create($data);
|
||||
}
|
||||
CLI::logging("> Completed table LIST_PAUSED\n");
|
||||
|
||||
|
||||
//Select and Insert LIST_UNASSIGNED
|
||||
$unaCriteria = $appCache->getSelAllColumns();
|
||||
$unaCriteria->add(AppCacheViewPeer::USR_UID, "", CRITERIA::EQUAL);
|
||||
@@ -2024,12 +2092,12 @@ class workspaceTools
|
||||
$del = new ListUnassignedPeer();
|
||||
$del->doDeleteAll();
|
||||
$del = new ListUnassignedGroupPeer();
|
||||
$del->doDeleteAll();
|
||||
$del->doDeleteAll();
|
||||
while ($rsCriteria->next()) {
|
||||
$row = $rsCriteria->getRow();
|
||||
$listUnassigned = new ListUnassigned();
|
||||
$unaUid = $listUnassigned->generateData($row["APP_UID"],$row["PREVIOUS_USR_UID"]);
|
||||
}
|
||||
$unaUid = $listUnassigned->generateData($row["APP_UID"],$row["PREVIOUS_USR_UID"]);
|
||||
}
|
||||
CLI::logging("> Completed table LIST_UNASSIGNED\n");
|
||||
CLI::logging("> Completed table LIST_UNASSIGNED_GROUP\n");
|
||||
|
||||
@@ -2070,7 +2138,7 @@ class workspaceTools
|
||||
}
|
||||
|
||||
/**
|
||||
* This function checks if List tables are going to migrated
|
||||
* This function checks if List tables are going to migrated
|
||||
*
|
||||
* return boolean value
|
||||
*/
|
||||
@@ -2109,6 +2177,6 @@ class workspaceTools
|
||||
default:
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -110,6 +110,81 @@ try {
|
||||
|
||||
$message = G::loadTranslation( 'ID_ENTERPRISE_INSTALLED') . ' ' . G::loadTranslation( 'ID_LOG_AGAIN');
|
||||
G::SendMessageText($message, "INFO");
|
||||
$licenseManager = &pmLicenseManager::getSingleton();
|
||||
die('<script type="text/javascript">parent.parent.location = "../login/login";</script>');
|
||||
}
|
||||
}
|
||||
|
||||
//save the packages plugins
|
||||
if ($_FILES['form']['error']['PLUGIN_FILENAME'] == 0) {
|
||||
$filename = $_FILES['form']['name']['PLUGIN_FILENAME'];
|
||||
$path = PATH_DOCUMENT . 'input' . PATH_SEP;
|
||||
if (strpos($filename, 'plugins-') !== false) {
|
||||
|
||||
G::LoadThirdParty( 'pear/Archive', 'Tar' );
|
||||
$tar = new Archive_Tar( $path . $filename );
|
||||
$sFileName = substr( $filename, 0, strrpos( $filename, '.' ) );
|
||||
$sClassName = substr( $filename, 0, strpos( $filename, '-' ) );
|
||||
|
||||
$files = $tar->listContent();
|
||||
$licenseName = '';
|
||||
$listFiles = array();
|
||||
foreach ($files as $key => $val) {
|
||||
if (strpos(trim($val['filename']), 'plugins/') !== false) {
|
||||
$listFiles[] = trim($val['filename']);
|
||||
}
|
||||
if (strpos(trim($val['filename']), 'license_') !== false) {
|
||||
$licenseName = trim($val['filename']);
|
||||
}
|
||||
}
|
||||
$tar->extractList( $listFiles, PATH_PLUGINS . 'data');
|
||||
$tar->extractList( $licenseName, PATH_PLUGINS);
|
||||
|
||||
$pluginRegistry = &PMPluginRegistry::getSingleton();
|
||||
$autoPlugins = glob(PATH_PLUGINS . "data/plugins/*.tar");
|
||||
$autoPluginsA = array();
|
||||
|
||||
foreach ($autoPlugins as $filePath) {
|
||||
$plName = basename($filePath);
|
||||
//if (!(in_array($plName, $def))) {
|
||||
if (strpos($plName, 'enterprise') === false) {
|
||||
$autoPluginsA[]["sFilename"] = $plName;
|
||||
}
|
||||
}
|
||||
|
||||
$aPlugins = $autoPluginsA;
|
||||
foreach ($aPlugins as $key=>$aPlugin) {
|
||||
$sClassName = substr($aPlugin["sFilename"], 0, strpos($aPlugin["sFilename"], "-"));
|
||||
|
||||
$oTar = new Archive_Tar(PATH_PLUGINS . "data/plugins/" . $aPlugin["sFilename"]);
|
||||
$oTar->extract(PATH_PLUGINS);
|
||||
|
||||
if (!(class_exists($sClassName))) {
|
||||
require_once (PATH_PLUGINS . $sClassName . ".php");
|
||||
}
|
||||
|
||||
$pluginDetail = $pluginRegistry->getPluginDetails($sClassName . ".php");
|
||||
$pluginRegistry->installPlugin($pluginDetail->sNamespace); //error
|
||||
}
|
||||
|
||||
file_put_contents(PATH_DATA_SITE . "plugin.singleton", $pluginRegistry->serializeInstance());
|
||||
|
||||
$licfile = glob(PATH_PLUGINS . "*.dat");
|
||||
|
||||
if ((isset($licfile[0])) && ( is_file($licfile[0]) )) {
|
||||
$licfilename = basename($licfile[0]);
|
||||
@copy($licfile[0], PATH_DATA_SITE . $licfilename);
|
||||
@unlink($licfile[0]);
|
||||
}
|
||||
|
||||
require_once ('classes/model/AddonsStore.php');
|
||||
AddonsStore::checkLicenseStore();
|
||||
$licenseManager = &pmLicenseManager::getSingleton();
|
||||
AddonsStore::updateAll(false);
|
||||
|
||||
$message = G::loadTranslation( 'ID_ENTERPRISE_INSTALLED') . ' ' . G::loadTranslation( 'ID_LOG_AGAIN');
|
||||
G::SendMessageText($message, "INFO");
|
||||
$licenseManager = &pmLicenseManager::getSingleton();
|
||||
die('<script type="text/javascript">parent.parent.location = "../login/login";</script>');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -219,6 +219,10 @@ ul.x-tab-strip-bottom{
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.x-form-check-wrap {
|
||||
overflow: hidden !important;
|
||||
}
|
||||
|
||||
.x-editor .x-form-check-wrap {
|
||||
background-color:#fff;
|
||||
}
|
||||
@@ -304,6 +308,7 @@ ul.x-tab-strip-bottom{
|
||||
|
||||
.x-fieldset {
|
||||
border-color:#CCCCCC;
|
||||
margin-top: -5px;
|
||||
}
|
||||
|
||||
.x-fieldset legend {
|
||||
|
||||
@@ -362,6 +362,11 @@ textarea.x-form-field {
|
||||
border-bottom: 1px solid #dddddd;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.x-form-check-wrap {
|
||||
overflow: hidden !important;
|
||||
}
|
||||
|
||||
.x-editor .x-form-check-wrap {
|
||||
background-color: #fff;
|
||||
}
|
||||
@@ -431,6 +436,7 @@ textarea.x-form-inner-invalid {
|
||||
}
|
||||
.x-fieldset {
|
||||
border-color: #CCCCCC;
|
||||
margin-top: -5px;
|
||||
}
|
||||
.x-fieldset legend {
|
||||
font: bold 11px "Open Sans", Tahoma, sans-serif, MiscFixed;
|
||||
@@ -1465,6 +1471,7 @@ a.x-menu-item {
|
||||
}
|
||||
.x-panel-body .x-panel-body {
|
||||
border: #dddddd 1px solid;
|
||||
overflow: hidden !important;
|
||||
}
|
||||
.x-panel-bbar .x-toolbar,
|
||||
.x-panel-tbar .x-toolbar {
|
||||
|
||||
@@ -111,7 +111,7 @@ class Project extends Api
|
||||
|
||||
$outputDir = PATH_DATA . "sites" . PATH_SEP . SYS_SYS . PATH_SEP . "files" . PATH_SEP . "output" . PATH_SEP;
|
||||
$version = \ProcessMaker\Util\Common::getLastVersion($outputDir . $exporter->getProjectName() . "-*.pmx") + 1;
|
||||
$outputFilename = $outputDir . sprintf("%s-%s.%s", $exporter->getProjectName(), $version, "pmx");
|
||||
$outputFilename = $outputDir . sprintf("%s-%s.%s", str_replace(" ", "_", $exporter->getProjectName()), $version, "pmx");
|
||||
|
||||
$exporter->setMetadata("export_version", $version);
|
||||
$exporter->saveExport($outputFilename);
|
||||
|
||||
@@ -64,6 +64,7 @@ class System extends Api
|
||||
{
|
||||
try {
|
||||
$enabledFeatures = array();
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$keys = array ('zLhSk5TeEQrNFI2RXFEVktyUGpnczV1WEJNWVp6cjYxbTU3R29mVXVZNWhZQT0=');
|
||||
foreach ($keys as $key) {
|
||||
if (\PMLicensedFeatures
|
||||
@@ -72,6 +73,7 @@ class System extends Api
|
||||
$enabledFeatures[] = $key;
|
||||
}
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
return $enabledFeatures;
|
||||
} catch (\Exception $e) {
|
||||
throw (new RestException(Api::STAT_APP_EXCEPTION, $e->getMessage()));
|
||||
|
||||
@@ -190,8 +190,14 @@ class PmPdo implements \OAuth2\Storage\AuthorizationCodeInterface,
|
||||
/* OAuth2_Storage_UserCredentialsInterface */
|
||||
public function checkUserCredentials($username, $password)
|
||||
{
|
||||
if ($user = $this->getUser($username)) {
|
||||
return $this->checkPassword($user, $password);
|
||||
$RBAC = \RBAC::getSingleton();
|
||||
$RBAC->initRBAC();
|
||||
$uid = $RBAC->VerifyLogin($username , $password);
|
||||
if($uid < 0){
|
||||
return false;
|
||||
}
|
||||
if($uid != ''){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<rules>
|
||||
<rule name="ProcessMaker Rule" stopProcessing="true">
|
||||
<match url="^.*/(.*)$" ignoreCase="true" />
|
||||
<action type="Rewrite" url="sysGeneric.php" />
|
||||
<action type="Rewrite" url="app.php" />
|
||||
</rule>
|
||||
</rules>
|
||||
</rewrite>
|
||||
|
||||
Reference in New Issue
Block a user