Merge remote branch 'upstream/master' into PM-2647
This commit is contained in:
@@ -2736,7 +2736,7 @@ function run_check_plugin_disabled_code($task, $args)
|
||||
|
||||
$arrayFoundDisabledCode = array_merge($cs->checkDisabledCode("FILE", PATH_PLUGINS . $pluginName . ".php"), $cs->checkDisabledCode("PATH", PATH_PLUGINS . $pluginName));
|
||||
|
||||
if (count($arrayFoundDisabledCode) > 0) {
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
$strFoundDisabledCode .= (($strFoundDisabledCode != "")? "\n\n" : "") . "> " . $pluginName;
|
||||
|
||||
foreach ($arrayFoundDisabledCode as $key2 => $value2) {
|
||||
|
||||
@@ -67,10 +67,12 @@ function displayUploadForm()
|
||||
$html = "
|
||||
<div id=\"containerDataForm\">
|
||||
<form method=\"post\" enctype=\"multipart/form-data\" action=\"uploader.php?" . $_SERVER["QUERY_STRING"] . "&q=upload\" onsubmit=\"return validateForm();\">
|
||||
<br/>
|
||||
File:
|
||||
<input type=\"file\" id=\"File1\" name=\"upload_file\" /> (*.html, *.htm)
|
||||
<br/><br/>
|
||||
<br/>
|
||||
<input type=\"submit\" name=\"Upload File\" value=\"Upload File\" style=\"border: 1px solid #1ba385; float: right; margin-top: 30px; margin-right: -4px; font-size: 10px; display: inline-block; text-decoration: none; padding: 8px 24px; -moz-border-radius: 2px; -ms-border-radius: 2px; -o-border-radius: 2px; background-color: #1fbc99; color: white;\" />
|
||||
<input type=\"button\" onclick=\"tinyMCEPopup.close();\"name=\"Cancel\" value=\"Cancel\" style=\"border: 1px solid #e14333; float: right; margin-top: 30px; margin-right: 8px; font-size: 10px; display: inline-block; text-decoration: none; padding: 8px 24px; -moz-border-radius: 2px; -ms-border-radius: 2px; -o-border-radius: 2px; background-color: #e4655f; color: white;\" />
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -80,7 +80,7 @@ class CodeScanner
|
||||
public function existsDisabledCode()
|
||||
{
|
||||
try {
|
||||
return count($this->arrayDisabledCode) > 0;
|
||||
return !empty($this->arrayDisabledCode);
|
||||
} catch (Exception $e) {
|
||||
throw $e;
|
||||
}
|
||||
@@ -174,7 +174,7 @@ class CodeScanner
|
||||
|
||||
$arrayAux = $this->checkDisabledCodeInSource($source);
|
||||
|
||||
if (count($arrayAux) > 0) {
|
||||
if (!empty($arrayAux)) {
|
||||
$arrayFoundCode["source"] = $arrayAux;
|
||||
}
|
||||
break;
|
||||
@@ -202,7 +202,7 @@ class CodeScanner
|
||||
|
||||
$arrayAux = $this->checkDisabledCodeInSource($source);
|
||||
|
||||
if (count($arrayAux) > 0) {
|
||||
if (!empty($arrayAux)) {
|
||||
$arrayFoundCode[$path] = $arrayAux;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -967,7 +967,7 @@ function executeCaseSelfService()
|
||||
$dueDate = $calendar->calculateDate(
|
||||
$appcacheDelDelegateDate,
|
||||
$taskSelfServiceTime,
|
||||
$taskSelfServiceTimeUnit //HOURS|DAYS
|
||||
$taskSelfServiceTimeUnit //HOURS|DAYS|MINUTES
|
||||
//1
|
||||
);
|
||||
|
||||
|
||||
@@ -124,6 +124,14 @@ function run_upgrade($command, $args)
|
||||
$countWorkspace = 0;
|
||||
$buildCacheView = array_key_exists("buildACV", $args);
|
||||
foreach ($workspaces as $index => $workspace) {
|
||||
if (!defined("SYS_SYS")) {
|
||||
define("SYS_SYS", $workspace->name);
|
||||
}
|
||||
|
||||
if (!defined("PATH_DATA_SITE")) {
|
||||
define("PATH_DATA_SITE", PATH_DATA . "sites" . PATH_SEP . SYS_SYS . PATH_SEP);
|
||||
}
|
||||
|
||||
try {
|
||||
$countWorkspace++;
|
||||
CLI::logging("Upgrading workspaces ($countWorkspace/$count): " . CLI::info($workspace->name) . "\n");
|
||||
|
||||
@@ -324,6 +324,14 @@ function database_upgrade($command, $args) {
|
||||
$workspaces = get_workspaces_from_args($args);
|
||||
$checkOnly = (strcmp($command, "check") == 0);
|
||||
foreach ($workspaces as $workspace) {
|
||||
if (!defined("SYS_SYS")) {
|
||||
define("SYS_SYS", $workspace->name);
|
||||
}
|
||||
|
||||
if (!defined("PATH_DATA_SITE")) {
|
||||
define("PATH_DATA_SITE", PATH_DATA . "sites" . PATH_SEP . SYS_SYS . PATH_SEP);
|
||||
}
|
||||
|
||||
if ($checkOnly)
|
||||
print_r("Checking database in ".pakeColor::colorize($workspace->name, "INFO")."\n");
|
||||
else
|
||||
@@ -595,12 +603,24 @@ function run_check_workspace_disabled_code($args, $opts)
|
||||
foreach ($arrayWorkspace as $value) {
|
||||
$workspace = $value;
|
||||
|
||||
if (!defined("SYS_SYS")) {
|
||||
define("SYS_SYS", $workspace->name);
|
||||
}
|
||||
|
||||
if (!defined("PATH_DATA_SITE")) {
|
||||
define("PATH_DATA_SITE", PATH_DATA . "sites" . PATH_SEP . SYS_SYS . PATH_SEP);
|
||||
}
|
||||
|
||||
if (!$workspace->pmLicensedFeaturesVerifyFeature("B0oWlBLY3hHdWY0YUNpZEtFQm5CeTJhQlIwN3IxMEkwaG4=")) {
|
||||
throw new Exception("Error: This command cannot be used because your license does not include it.");
|
||||
}
|
||||
|
||||
echo "> Workspace: " . $workspace->name . "\n";
|
||||
|
||||
try {
|
||||
$arrayFoundDisabledCode = $workspace->getDisabledCode();
|
||||
|
||||
if (count($arrayFoundDisabledCode) > 0) {
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
$strFoundDisabledCode = "";
|
||||
|
||||
foreach ($arrayFoundDisabledCode as $value2) {
|
||||
@@ -630,6 +650,8 @@ function run_check_workspace_disabled_code($args, $opts)
|
||||
} catch (Exception $e) {
|
||||
echo "Errors to check disabled code: " . CLI::error($e->getMessage()) . "\n\n";
|
||||
}
|
||||
|
||||
$workspace->close();
|
||||
}
|
||||
|
||||
echo "Done!\n";
|
||||
|
||||
@@ -806,7 +806,9 @@ class calendar extends CalendarDefinition
|
||||
if ( G::toUpper($formatDuration) == 'DAYS' ) {
|
||||
$duration = $duration*$calendarData['HOURS_FOR_DAY'];
|
||||
}
|
||||
|
||||
if ( G::toUpper($formatDuration) == 'MINUTES' ) {
|
||||
$duration = $duration/60;
|
||||
}
|
||||
$hoursDuration = (float)$duration;
|
||||
$newDate = $iniDate;
|
||||
|
||||
|
||||
@@ -3373,15 +3373,17 @@ class Cases
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$cs = new CodeScanner((isset($arraySystemConfiguration["enable_blacklist"]) && (int)($arraySystemConfiguration["enable_blacklist"]) == 1)? "DISABLED_CODE" : "");
|
||||
|
||||
$strFoundDisabledCode = "";
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
foreach ($aTriggers as $aTrigger) {
|
||||
//Check disabled code
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (PMLicensedFeatures::getSingleton()->verifyfeature("B0oWlBLY3hHdWY0YUNpZEtFQm5CeTJhQlIwN3IxMEkwaG4=")) {
|
||||
//Check disabled code
|
||||
$arrayFoundDisabledCode = $cs->checkDisabledCode("SOURCE", $aTrigger["TRI_WEBBOT"]);
|
||||
|
||||
if (count($arrayFoundDisabledCode) > 0) {
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
$strCodeAndLine = "";
|
||||
|
||||
foreach ($arrayFoundDisabledCode["source"] as $key => $value) {
|
||||
@@ -3391,7 +3393,9 @@ class Cases
|
||||
$strFoundDisabledCode .= "<br />- " . $aTrigger["TRI_TITLE"] . ": " . $strCodeAndLine;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
//Execute
|
||||
$bExecute = true;
|
||||
|
||||
|
||||
@@ -335,7 +335,12 @@ class dbConnections
|
||||
);
|
||||
break;
|
||||
case 'oracle':
|
||||
$encodes = Array ();
|
||||
$encodes = array (
|
||||
array ("UTF8", "UTF8 - Unicode 3.0 UTF-8 Universal character set CESU-8 compliant"),
|
||||
array ("UTFE", "UTFE - EBCDIC form of Unicode 3.0 UTF-8 Universal character set"),
|
||||
array ("AL16UTF16", "AL16UTF16 - Unicode 3.1 UTF-16 Universal character set"),
|
||||
array ("AL32UTF8", "AL32UTF8 - Unicode 3.1 UTF-8 Universal character set")
|
||||
);
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -146,6 +146,57 @@ class PMLicensedFeatures
|
||||
"type" => "features",
|
||||
"url" => "",
|
||||
"version" => ""
|
||||
),
|
||||
7 => array(
|
||||
"description" => "Enables the code scanner feature.",
|
||||
"enabled" => false,
|
||||
"id" => "codeScanner",
|
||||
"latest_version" => "",
|
||||
"log" => null,
|
||||
"name" => "codeScanner",
|
||||
"nick" => "codeScanner",
|
||||
"progress" => 0,
|
||||
"publisher" => "Colosa",
|
||||
"release_type" => "localRegistry",
|
||||
"status" => "ready",
|
||||
"store" => "00000000000000000000000000010007",
|
||||
"type" => "features",
|
||||
"url" => "",
|
||||
"version" => ""
|
||||
),
|
||||
8 => array(
|
||||
"description" => "Enables the multiple email configuration feature.",
|
||||
"enabled" => false,
|
||||
"id" => "multipleEmailServers",
|
||||
"latest_version" => "",
|
||||
"log" => null,
|
||||
"name" => "multipleEmailServers",
|
||||
"nick" => "multipleEmailServers",
|
||||
"progress" => 0,
|
||||
"publisher" => "Colosa",
|
||||
"release_type" => "localRegistry",
|
||||
"status" => "ready",
|
||||
"store" => "00000000000000000000000000010009",
|
||||
"type" => "features",
|
||||
"url" => "",
|
||||
"version" => ""
|
||||
),
|
||||
9 => array(
|
||||
"description" => "Enables the mobile fields.",
|
||||
"enabled" => false,
|
||||
"id" => "mobileFields",
|
||||
"latest_version" => "",
|
||||
"log" => null,
|
||||
"name" => "mobileFields",
|
||||
"nick" => "mobileFields",
|
||||
"progress" => 0,
|
||||
"publisher" => "Colosa",
|
||||
"release_type" => "localRegistry",
|
||||
"status" => "ready",
|
||||
"store" => "00000000000000000000000000010008",
|
||||
"type" => "features",
|
||||
"url" => "",
|
||||
"version" => ""
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
@@ -206,7 +206,7 @@ class NET
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function tryConnectServer($pDbDriver, array $arrayServerData = array())
|
||||
public function tryConnectServer($pDbDriver, array $arrayServerData = array(), $dbsEncode = "")
|
||||
{
|
||||
G::LoadSystem('inputfilter');
|
||||
$filter = new InputFilter();
|
||||
@@ -291,9 +291,9 @@ class NET
|
||||
if ($flagTns == 0) {
|
||||
$this->db_port = ($this->db_port == "" || $this->db_port == 0)? "1521" : $this->db_port;
|
||||
|
||||
$cnn = @oci_connect($this->db_user, $this->db_passwd, "(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP) (HOST=$this->ip) (PORT=$this->db_port) )) (CONNECT_DATA=(SERVICE_NAME=$this->db_sourcename)))");
|
||||
$cnn = @oci_connect($this->db_user, $this->db_passwd, "(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP) (HOST=$this->ip) (PORT=$this->db_port) )) (CONNECT_DATA=(SERVICE_NAME=$this->db_sourcename)))", $dbsEncode);
|
||||
} else {
|
||||
$cnn = @oci_connect($this->db_user, $this->db_passwd, $arrayServerData["tns"]);
|
||||
$cnn = @oci_connect($this->db_user, $this->db_passwd, $arrayServerData["tns"], $dbsEncode);
|
||||
}
|
||||
|
||||
if ($cnn) {
|
||||
@@ -329,7 +329,7 @@ class NET
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function tryOpenDataBase($pDbDriver, array $arrayServerData = array())
|
||||
public function tryOpenDataBase($pDbDriver, array $arrayServerData = array(), $dbsEncode = "")
|
||||
{
|
||||
G::LoadSystem('inputfilter');
|
||||
$filter = new InputFilter();
|
||||
@@ -434,9 +434,9 @@ class NET
|
||||
if ($flagTns == 0) {
|
||||
$this->db_port = ($this->db_port == "" || $this->db_port == 0)? "1521" : $this->db_port;
|
||||
|
||||
$cnn = @oci_connect($this->db_user, $this->db_passwd, "(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP) (HOST=$this->ip) (PORT=$this->db_port) )) (CONNECT_DATA=(SERVICE_NAME=$this->db_sourcename)))");
|
||||
$cnn = @oci_connect($this->db_user, $this->db_passwd, "(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP) (HOST=$this->ip) (PORT=$this->db_port) )) (CONNECT_DATA=(SERVICE_NAME=$this->db_sourcename)))", $dbsEncode);
|
||||
} else {
|
||||
$cnn = @oci_connect($this->db_user, $this->db_passwd, $arrayServerData["tns"]);
|
||||
$cnn = @oci_connect($this->db_user, $this->db_passwd, $arrayServerData["tns"], $dbsEncode);
|
||||
}
|
||||
|
||||
if ($cnn) {
|
||||
@@ -592,4 +592,3 @@ class Stat
|
||||
$this->status = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -219,7 +219,7 @@ class pmDynaform
|
||||
$cells = array();
|
||||
foreach ($json->columns as $column) {
|
||||
//data
|
||||
if ($column->type === "text" || $column->type === "textarea" || $column->type === "dropdown" || $column->type === "suggest" || $column->type === "datetime" || $column->type === "checkbox" || $column->type === "file" || $column->type === "link" || $value === "hidden") {
|
||||
if ($column->type === "text" || $column->type === "textarea" || $column->type === "dropdown" || $column->type === "suggest" || $column->type === "datetime" || $column->type === "checkbox" || $column->type === "file" || $column->type === "link" || $column->type === "hidden") {
|
||||
array_push($cells, array(
|
||||
"value" => isset($row[$column->name]) ? $row[$column->name] : "",
|
||||
"label" => isset($row[$column->name . "_label"]) ? $row[$column->name . "_label"] : (isset($row[$column->name]) ? $row[$column->name] : "")
|
||||
|
||||
@@ -242,6 +242,7 @@ function executeQuery ($SqlStatement, $DBConnectionUID = 'workflow', $aParameter
|
||||
{
|
||||
$con = Propel::getConnection( $DBConnectionUID );
|
||||
$con->begin();
|
||||
|
||||
try {
|
||||
$statement = trim( $SqlStatement );
|
||||
$statement = str_replace( '(', '', $statement );
|
||||
@@ -277,9 +278,15 @@ function executeQuery ($SqlStatement, $DBConnectionUID = 'workflow', $aParameter
|
||||
$con->commit();
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
$dataEncode = $con->getDSN();
|
||||
|
||||
if (isset($dataEncode["encoding"]) && $dataEncode["encoding"] != "") {
|
||||
$result = executeQueryOci($SqlStatement, $con, $aParameter, $dataEncode["encoding"]);
|
||||
} else {
|
||||
$result = executeQueryOci($SqlStatement, $con, $aParameter);
|
||||
}
|
||||
}
|
||||
|
||||
return $result;
|
||||
} catch (SQLException $sqle) {
|
||||
|
||||
@@ -695,7 +695,7 @@ function getEngineDataBaseName ($connection)
|
||||
* @param type $sql
|
||||
* @param type $connection
|
||||
*/
|
||||
function executeQueryOci ($sql, $connection, $aParameter = array())
|
||||
function executeQueryOci ($sql, $connection, $aParameter = array(), $dbsEncode = "")
|
||||
{
|
||||
$aDNS = $connection->getDSN();
|
||||
|
||||
@@ -710,12 +710,12 @@ function executeQueryOci ($sql, $connection, $aParameter = array())
|
||||
|
||||
if ($flagTns == 0) {
|
||||
// if not default port
|
||||
$conn = oci_connect($sUsername, $sPassword, $sHostspec . ":" . $sPort . "/" . $sDatabse);
|
||||
$conn = oci_connect($sUsername, $sPassword, $sHostspec . ":" . $sPort . "/" . $sDatabse, $dbsEncode);
|
||||
} else {
|
||||
$conn = oci_connect($sUsername, $sPassword, $sHostspec);
|
||||
$conn = oci_connect($sUsername, $sPassword, $sHostspec, $dbsEncode);
|
||||
}
|
||||
} else {
|
||||
$conn = oci_connect( $sUsername, $sPassword, $sHostspec . "/" . $sDatabse );
|
||||
$conn = oci_connect( $sUsername, $sPassword, $sHostspec . "/" . $sDatabse, $dbsEncode);
|
||||
}
|
||||
|
||||
if (! $conn) {
|
||||
@@ -786,4 +786,3 @@ function executeQueryOci ($sql, $connection, $aParameter = array())
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5085,10 +5085,15 @@ class Processes
|
||||
|
||||
$arrayDisabledCode = array();
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (!PMLicensedFeatures::getSingleton()->verifyfeature("B0oWlBLY3hHdWY0YUNpZEtFQm5CeTJhQlIwN3IxMEkwaG4=")) {
|
||||
//Return
|
||||
return $arrayDisabledCode;
|
||||
}
|
||||
|
||||
//Set variables
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$cs = new CodeScanner("DISABLED_CODE");
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
$delimiter = DBAdapter::getStringDelimiter();
|
||||
|
||||
//Processes
|
||||
@@ -5144,7 +5149,7 @@ class Processes
|
||||
//Check disabled code
|
||||
$arrayFoundDisabledCode = $cs->checkDisabledCode("SOURCE", $triggerWebbot);
|
||||
|
||||
if (count($arrayFoundDisabledCode) > 0) {
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
if (!isset($arrayDisabledCode[$processUid])) {
|
||||
$arrayDisabledCode[$processUid] = array(
|
||||
"processUid" => $processUid,
|
||||
@@ -5161,6 +5166,7 @@ class Processes
|
||||
}
|
||||
}
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
//Return
|
||||
return $arrayDisabledCode;
|
||||
|
||||
@@ -920,22 +920,36 @@ class wsBase
|
||||
if (!class_exists('System')) {
|
||||
G::LoadClass('system');
|
||||
}
|
||||
$licensedFeatures = & PMLicensedFeatures::getSingleton();
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (!empty($config) && $licensedFeatures->verifyfeature('nKaNTNuT1MzK0RsMEtXTnYzR09ucHF2WGNuS0hRdDBBak42WXJhNVVOOG1INEVoaU1EaTllbjBBeEJNeG9wRVJ6NmxQelhyVTBvdThzPQ==')) {
|
||||
if(!is_array($config)){
|
||||
$emailServer = new EmailServer();
|
||||
$criteria = $emailServer->getSelAllColumns();
|
||||
$criteria->add(EmailServerPeer::MESS_UID, $config, CRITERIA::EQUAL);
|
||||
$criteria = EmailServerPeer::doSelectRS($criteria);
|
||||
$criteria->setFetchmode(ResultSet::FETCHMODE_ASSOC);
|
||||
while ($criteria->next()) {
|
||||
$row = $criteria->getRow();
|
||||
$config = $row;
|
||||
$config['SMTPSecure'] = $row['SMTPSECURE'];
|
||||
if (!empty($config)) {
|
||||
$arrayConfigAux = array();
|
||||
|
||||
if (is_array($config)) {
|
||||
if (PMLicensedFeatures::getSingleton()->verifyfeature("nKaNTNuT1MzK0RsMEtXTnYzR09ucHF2WGNuS0hRdDBBak42WXJhNVVOOG1INEVoaU1EaTllbjBBeEJNeG9wRVJ6NmxQelhyVTBvdThzPQ==")) {
|
||||
$arrayConfigAux = $config;
|
||||
}
|
||||
} else {
|
||||
if (PMLicensedFeatures::getSingleton()->verifyfeature("zIKRGpDM3pjcHFsWGplNDN0dTl5bGN3UTNiOWdQU0E5Q05QTksrU1ladWQ0VT0=")) {
|
||||
$emailServer = new \ProcessMaker\BusinessModel\EmailServer();
|
||||
|
||||
$criteria = $emailServer->getEmailServerCriteria();
|
||||
|
||||
$criteria->add(EmailServerPeer::MESS_UID, $config, Criteria::EQUAL);
|
||||
|
||||
$rsCriteria = EmailServerPeer::doSelectRS($criteria);
|
||||
$rsCriteria->setFetchmode(ResultSet::FETCHMODE_ASSOC);
|
||||
|
||||
if ($rsCriteria->next()) {
|
||||
$row = $rsCriteria->getRow();
|
||||
|
||||
$arrayConfigAux = $row;
|
||||
$arrayConfigAux["SMTPSecure"] = $row["SMTPSECURE"];
|
||||
}
|
||||
}
|
||||
$aSetup = $config;
|
||||
}
|
||||
|
||||
$aSetup = (!empty($arrayConfigAux))? $arrayConfigAux : System::getEmailConfiguration();
|
||||
} else {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$aSetup = System::getEmailConfiguration();
|
||||
|
||||
@@ -796,9 +796,10 @@ class workspaceTools
|
||||
$arrayData = array();
|
||||
|
||||
$emailSever = new \ProcessMaker\BusinessModel\EmailServer();
|
||||
|
||||
$emailConfiguration = System::getEmailConfiguration();
|
||||
|
||||
if (count($emailConfiguration) > 0) {
|
||||
if (!empty($emailConfiguration)) {
|
||||
$arrayData["MESS_ENGINE"] = $emailConfiguration["MESS_ENGINE"];
|
||||
|
||||
switch ($emailConfiguration["MESS_ENGINE"]) {
|
||||
@@ -830,9 +831,7 @@ class workspaceTools
|
||||
$arrayData = $emailSever->create($arrayData);
|
||||
} else {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (true) {
|
||||
//
|
||||
} else {
|
||||
if (!PMLicensedFeatures::getSingleton()->verifyfeature("zIKRGpDM3pjcHFsWGplNDN0dTl5bGN3UTNiOWdQU0E5Q05QTksrU1ladWQ0VT0=")) {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$arrayData["MESS_ENGINE"] = "MAIL";
|
||||
$arrayData["MESS_SERVER"] = "";
|
||||
@@ -1359,7 +1358,7 @@ class workspaceTools
|
||||
if ( !$flag && !is_null($flagFunction) ) {
|
||||
//Replace TYPE by ENGINE
|
||||
$script = file_get_contents($filename);
|
||||
$script = preg_replace('/\)TYPE\=|\)\sTYPE\=/', ')ENGINE=', $script);
|
||||
$script = preg_replace('/\)TYPE\=InnoDB|\)\sTYPE\=InnoDB/', ')ENGINE=InnoDB DEFAULT CHARSET=utf8', $script);
|
||||
file_put_contents($filename,$script);
|
||||
$aHost = explode(':',$parameters['dbHost']);
|
||||
$dbHost = $aHost[0];
|
||||
@@ -1390,7 +1389,7 @@ class workspaceTools
|
||||
$script = file_get_contents($filename);
|
||||
|
||||
//Replace TYPE by ENGINE
|
||||
$script = preg_replace('/\)TYPE\=|\)\sTYPE\=/', ')ENGINE=', $script);
|
||||
$script = preg_replace('/\)TYPE\=InnoDB|\)\sTYPE\=InnoDB/', ')ENGINE=InnoDB DEFAULT CHARSET=utf8', $script);
|
||||
$lines = explode("\n", $script);
|
||||
$previous = null;
|
||||
$insert = false;
|
||||
@@ -2202,5 +2201,28 @@ class workspaceTools
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Verify feature
|
||||
*
|
||||
* @param string $featureName Feature name
|
||||
*
|
||||
* return bool Return true if is valid the feature, false otherwise
|
||||
*/
|
||||
public function pmLicensedFeaturesVerifyFeature($featureName)
|
||||
{
|
||||
try {
|
||||
$this->initPropel(true);
|
||||
|
||||
$flag = PMLicensedFeatures::getSingleton()->verifyfeature($featureName);
|
||||
|
||||
$this->close();
|
||||
|
||||
//Return
|
||||
return $flag;
|
||||
} catch (Exception $e) {
|
||||
throw $e;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,27 +1,5 @@
|
||||
<?php
|
||||
class EmailServer extends BaseEmailServer
|
||||
{
|
||||
/**
|
||||
* Get all columns by EMAIL_SERVER
|
||||
*
|
||||
* @return object criteria
|
||||
*/
|
||||
public function getSelAllColumns(){
|
||||
$criteria = new Criteria("workflow");
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_UID);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_ENGINE);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_SERVER);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_PORT);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_RAUTH);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_ACCOUNT);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_PASSWORD);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_FROM_MAIL);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_FROM_NAME);
|
||||
$criteria->addSelectColumn( EmailServerPeer::SMTPSECURE);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_TRY_SEND_INMEDIATLY);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MAIL_TO);
|
||||
$criteria->addSelectColumn( EmailServerPeer::MESS_DEFAULT);
|
||||
return $criteria;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -61,12 +61,18 @@ class Designer extends Controller
|
||||
|
||||
$consolidated = 0;
|
||||
$enterprise = 0;
|
||||
$distribution = 0;
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$licensedFeatures = & PMLicensedFeatures::getSingleton();
|
||||
if ($licensedFeatures->verifyfeature('7TTeDBQeWRoZTZKYjh4eFpYUlRDUUEyVERPU3FxellWank=')) {
|
||||
$consolidated = 1;
|
||||
}
|
||||
$enterprise = 1;
|
||||
|
||||
if ($licensedFeatures->verifyfeature("Jb0N3dSZHVhZ1JNOEFZaElqdm15Y050Wmh5S0FEVEI0ckQ=")) {
|
||||
$distribution = 1;
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
$this->setVar('prj_uid', $proUid);
|
||||
@@ -76,7 +82,7 @@ class Designer extends Controller
|
||||
$this->setVar('prj_readonly', $proReadOnly);
|
||||
$this->setVar('credentials', base64_encode(json_encode($clientToken)));
|
||||
$this->setVar('isDebugMode', $debug);
|
||||
$this->setVar('distribution', file_exists(PATH_METHODS . "login/licenseUpdate.php"));
|
||||
$this->setVar("distribution", $distribution);
|
||||
|
||||
if ($debug) {
|
||||
if (! file_exists(PATH_HTML . "lib-dev/pmUI/build.cache")) {
|
||||
|
||||
@@ -904,12 +904,16 @@ try {
|
||||
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TIMEUNIT'] == 'HOURS') {
|
||||
$hoursSelected = "selected = 'selected'";
|
||||
} else {
|
||||
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TIMEUNIT'] == 'MINUTES') {
|
||||
$minSelected = "selected = 'selected'";
|
||||
}
|
||||
$daysSelected = "selected = 'selected'";
|
||||
}
|
||||
|
||||
$sAux = '<select name=' . $hiddenName . '[NEXT_TASK][TAS_TIMEUNIT] id= ' . $hiddenName . '[NEXT_TASK][TAS_TIMEUNIT] >';
|
||||
$sAux .= "<option " . $hoursSelected . " value='HOURS'>Hours</option> ";
|
||||
$sAux .= "<option " . $daysSelected . " value='DAYS'>Days</option> ";
|
||||
$sAux .= "<option " . $minSelected . " value='MINUTES'>Minutes</option> ";
|
||||
$sAux .= '</select>';
|
||||
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TIMEUNIT'] = $sAux;
|
||||
|
||||
|
||||
@@ -18,5 +18,9 @@ $headPublisher->addContent("emailServer/emailServer"); //Adding a HTML file
|
||||
$headPublisher->addExtJsScript("emailServer/emailServer", false); //Adding a JavaScript file
|
||||
$headPublisher->assign("CONFIG", $arrayConfig);
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$headPublisher->assign("EMAILSERVER_LICENSED", (PMLicensedFeatures::getSingleton()->verifyfeature("zIKRGpDM3pjcHFsWGplNDN0dTl5bGN3UTNiOWdQU0E5Q05QTksrU1ladWQ0VT0="))? 1 : 0);
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
G::RenderPage("publish", "extJs");
|
||||
|
||||
|
||||
@@ -26,33 +26,58 @@ use \ProcessMaker\Importer\XmlImporter;
|
||||
|
||||
ini_set("max_execution_time", 0);
|
||||
|
||||
if (isset($_FILES["PROCESS_FILENAME"]) &&
|
||||
pathinfo($_FILES["PROCESS_FILENAME"]["name"], PATHINFO_EXTENSION) == "pm" &&
|
||||
$_FILES["PROCESS_FILENAME"]["error"] == 0
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (PMLicensedFeatures::getSingleton()->verifyfeature("B0oWlBLY3hHdWY0YUNpZEtFQm5CeTJhQlIwN3IxMEkwaG4=") &&
|
||||
isset($_FILES["PROCESS_FILENAME"]) &&
|
||||
$_FILES["PROCESS_FILENAME"]["error"] == 0 &&
|
||||
preg_match("/^(?:pm|pmx)$/", pathinfo($_FILES["PROCESS_FILENAME"]["name"], PATHINFO_EXTENSION))
|
||||
) {
|
||||
//Check disabled code
|
||||
$response = array();
|
||||
|
||||
try {
|
||||
$arrayTrigger = array();
|
||||
$projectTitle = "";
|
||||
|
||||
switch (pathinfo($_FILES["PROCESS_FILENAME"]["name"], PATHINFO_EXTENSION)) {
|
||||
case "pm":
|
||||
$fh = fopen($_FILES["PROCESS_FILENAME"]["tmp_name"], "rb");
|
||||
$content = fread($fh, (int)(fread($fh, 9)));
|
||||
$data = unserialize($content);
|
||||
fclose($fh);
|
||||
|
||||
if (is_object($data) && isset($data->triggers) && is_array($data->triggers) && count($data->triggers) > 0) {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (is_object($data) && isset($data->triggers) && is_array($data->triggers) && !empty($data->triggers)) {
|
||||
$arrayTrigger = $data->triggers;
|
||||
$projectTitle = $data->process["PRO_TITLE"];
|
||||
}
|
||||
break;
|
||||
case "pmx":
|
||||
$importer = new XmlImporter();
|
||||
|
||||
$data = $importer->load($_FILES["PROCESS_FILENAME"]["tmp_name"]);
|
||||
|
||||
if (isset($data["tables"]["workflow"]["triggers"]) && is_array($data["tables"]["workflow"]["triggers"]) && !empty($data["tables"]["workflow"]["triggers"])) {
|
||||
$arrayTrigger = $data["tables"]["workflow"]["triggers"];
|
||||
$projectTitle = $data["tables"]["bpmn"]["project"][0]["prj_name"];
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
if (!empty($arrayTrigger)) {
|
||||
G::LoadClass("codeScanner");
|
||||
|
||||
$arraySystemConfiguration = System::getSystemConfiguration(PATH_CONFIG . "env.ini");
|
||||
|
||||
$cs = new CodeScanner((isset($arraySystemConfiguration["enable_blacklist"]) && (int)($arraySystemConfiguration["enable_blacklist"]) == 1)? "DISABLED_CODE" : "");
|
||||
|
||||
$strFoundDisabledCode = "";
|
||||
|
||||
foreach ($data->triggers as $value) {
|
||||
foreach ($arrayTrigger as $value) {
|
||||
$arrayTriggerData = $value;
|
||||
|
||||
$arrayFoundDisabledCode = $cs->checkDisabledCode("SOURCE", $arrayTriggerData["TRI_WEBBOT"]);
|
||||
|
||||
if (count($arrayFoundDisabledCode) > 0) {
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
$strCodeAndLine = "";
|
||||
|
||||
foreach ($arrayFoundDisabledCode["source"] as $key2 => $value2) {
|
||||
@@ -66,12 +91,11 @@ if (isset($_FILES["PROCESS_FILENAME"]) &&
|
||||
if ($strFoundDisabledCode != "") {
|
||||
$response["status"] = "DISABLED-CODE";
|
||||
$response["success"] = true;
|
||||
$response["message"] = G::LoadTranslation("ID_DISABLED_CODE_PROCESS", array($data->process["PRO_TITLE"], "\n" . $strFoundDisabledCode));
|
||||
$response["message"] = G::LoadTranslation("ID_DISABLED_CODE_PROCESS", array($projectTitle, "\n" . $strFoundDisabledCode));
|
||||
|
||||
echo G::json_encode($response);
|
||||
exit(0);
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
$response["status"] = "ERROR";
|
||||
@@ -82,6 +106,7 @@ if (isset($_FILES["PROCESS_FILENAME"]) &&
|
||||
exit(0);
|
||||
}
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
if (isset($_FILES["PROCESS_FILENAME"]) &&
|
||||
pathinfo($_FILES["PROCESS_FILENAME"]["name"], PATHINFO_EXTENSION) == "pmx"
|
||||
@@ -441,5 +466,5 @@ if ($action == "uploadFileNewProcessExist") {
|
||||
}
|
||||
|
||||
echo G::json_encode( $result );
|
||||
exit();
|
||||
exit(0);
|
||||
|
||||
|
||||
@@ -52,17 +52,17 @@ if ($handle = opendir( PATH_PLUGINS )) {
|
||||
|
||||
if (is_file(PATH_PLUGINS . $pluginName . ".php") && is_dir(PATH_PLUGINS . $pluginName)) {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (PMLicensedFeatures::getSingleton()->verifyfeature("B0oWlBLY3hHdWY0YUNpZEtFQm5CeTJhQlIwN3IxMEkwaG4=")) {
|
||||
//Check disabled code
|
||||
G::LoadClass("codeScanner");
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
$arraySystemConfiguration = System::getSystemConfiguration(PATH_CONFIG . "env.ini");
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
$cs = new CodeScanner((isset($arraySystemConfiguration["enable_blacklist"]) && (int)($arraySystemConfiguration["enable_blacklist"]) == 1)? "DISABLED_CODE" : "");
|
||||
|
||||
$arrayFoundDisabledCode = array_merge($cs->checkDisabledCode("FILE", PATH_PLUGINS . $pluginName . ".php"), $cs->checkDisabledCode("PATH", PATH_PLUGINS . $pluginName));
|
||||
|
||||
if (count($arrayFoundDisabledCode) > 0) {
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
$response = array();
|
||||
$response["status"] = "DISABLED-CODE";
|
||||
$response["message"] = G::LoadTranslation("ID_DISABLED_CODE_PLUGIN");
|
||||
@@ -70,7 +70,9 @@ if ($handle = opendir( PATH_PLUGINS )) {
|
||||
echo G::json_encode($response);
|
||||
exit(0);
|
||||
}
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
//print "change to ENABLED";
|
||||
require_once($path);
|
||||
$details = $oPluginRegistry->getPluginDetails($pluginFile);
|
||||
|
||||
@@ -238,18 +238,22 @@ try {
|
||||
unset( $oClass );
|
||||
}
|
||||
$res = $tar->extract( $path );
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (PMLicensedFeatures::getSingleton()->verifyfeature("B0oWlBLY3hHdWY0YUNpZEtFQm5CeTJhQlIwN3IxMEkwaG4=")) {
|
||||
//Check disabled code
|
||||
G::LoadClass("codeScanner");
|
||||
|
||||
$arraySystemConfiguration = System::getSystemConfiguration(PATH_CONFIG . "env.ini");
|
||||
|
||||
$cs = new CodeScanner((isset($arraySystemConfiguration["enable_blacklist"]) && (int)($arraySystemConfiguration["enable_blacklist"]) == 1)? "DISABLED_CODE" : "");
|
||||
|
||||
$arrayFoundDisabledCode = array_merge($cs->checkDisabledCode("FILE", $path . $pluginFile), $cs->checkDisabledCode("PATH", $path . $sClassName));
|
||||
|
||||
if (count($arrayFoundDisabledCode) > 0) {
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
throw new Exception(G::LoadTranslation("ID_DISABLED_CODE_PLUGIN"));
|
||||
}
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
//Check if is enterprise plugin
|
||||
|
||||
@@ -67,9 +67,7 @@ if (isset( $sfunction ) && $sfunction == 'lookforNameTrigger') {
|
||||
echo $flag;
|
||||
} else {
|
||||
G::LoadClass("processMap");
|
||||
/*----------------------------------********---------------------------------*/
|
||||
G::LoadClass("codeScanner");
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
$response = array();
|
||||
|
||||
try {
|
||||
@@ -82,15 +80,20 @@ if (isset( $sfunction ) && $sfunction == 'lookforNameTrigger') {
|
||||
$value = $_POST;
|
||||
}
|
||||
|
||||
if (isset($value["TRI_WEBBOT"])) {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (PMLicensedFeatures::getSingleton()->verifyfeature("B0oWlBLY3hHdWY0YUNpZEtFQm5CeTJhQlIwN3IxMEkwaG4=") &&
|
||||
isset($value["TRI_WEBBOT"])
|
||||
) {
|
||||
//Check disabled code
|
||||
G::LoadClass("codeScanner");
|
||||
|
||||
$arraySystemConfiguration = System::getSystemConfiguration(PATH_CONFIG . "env.ini");
|
||||
|
||||
$cs = new CodeScanner((isset($arraySystemConfiguration["enable_blacklist"]) && (int)($arraySystemConfiguration["enable_blacklist"]) == 1)? "DISABLED_CODE" : "");
|
||||
|
||||
$arrayFoundDisabledCode = $cs->checkDisabledCode("SOURCE", $value["TRI_WEBBOT"]);
|
||||
|
||||
if (count($arrayFoundDisabledCode) > 0) {
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
$strCodeAndLine = "";
|
||||
|
||||
foreach ($arrayFoundDisabledCode["source"] as $key => $value) {
|
||||
@@ -99,8 +102,9 @@ if (isset( $sfunction ) && $sfunction == 'lookforNameTrigger') {
|
||||
|
||||
throw new Exception(G::LoadTranslation("ID_DISABLED_CODE_TRIGGER", array($strCodeAndLine)));
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
$swCreate = true;
|
||||
if ($value['TRI_UID'] != '') {
|
||||
$oTrigger->load( $value['TRI_UID'] );
|
||||
|
||||
@@ -1010,7 +1010,7 @@ class CaseScheduler
|
||||
case "UPD":
|
||||
$arrayDataAux = $caseScheduler->load($caseSchedulerUid);
|
||||
|
||||
$arrayCaseSchedulerData["SCH_END_DATE"] = $arrayData["SCH_END_DATE"];
|
||||
$arrayCaseSchedulerData["SCH_END_DATE"] = ($arrayData["SCH_END_DATE"] != "")? $arrayData["SCH_END_DATE"] : null;
|
||||
|
||||
//If the start date has changed then recalculate the next run time
|
||||
$recalculateDate = ($arrayData["SCH_START_DATE"] == $arrayData["PREV_SCH_START_DATE"])? false : true;
|
||||
|
||||
@@ -155,7 +155,8 @@ class Task
|
||||
"TAS_SELFSERVICE_TIMEOUT" => $arrayDataAux["TAS_SELFSERVICE_TIMEOUT"],
|
||||
"TAS_SELFSERVICE_TIME" => $arrayDataAux["TAS_SELFSERVICE_TIME"],
|
||||
"TAS_SELFSERVICE_TIME_UNIT" => $arrayDataAux["TAS_SELFSERVICE_TIME_UNIT"],
|
||||
"TAS_SELFSERVICE_TRIGGER_UID" => $arrayDataAux["TAS_SELFSERVICE_TRIGGER_UID"]
|
||||
"TAS_SELFSERVICE_TRIGGER_UID" => $arrayDataAux["TAS_SELFSERVICE_TRIGGER_UID"],
|
||||
"TAS_SELFSERVICE_EXECUTION" => $arrayDataAux["TAS_SELFSERVICE_EXECUTION"]
|
||||
),
|
||||
$keyCase
|
||||
);
|
||||
@@ -277,6 +278,7 @@ class Task
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TIME");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TIME_UNIT");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TRIGGER_UID");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_EXECUTION");
|
||||
break;
|
||||
case 'EVALUATE':
|
||||
if (empty($arrayProperty["TAS_ASSIGN_VARIABLE"])) {
|
||||
@@ -287,6 +289,7 @@ class Task
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TIME");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TIME_UNIT");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TRIGGER_UID");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_EXECUTION");
|
||||
break;
|
||||
case 'SELF_SERVICE':
|
||||
case 'SELF_SERVICE_EVALUATE':
|
||||
@@ -312,10 +315,14 @@ class Task
|
||||
if (empty($arrayProperty["TAS_SELFSERVICE_TRIGGER_UID"])) {
|
||||
throw (new \Exception("Invalid value specified for 'tas_selfservice_trigger_uid'"));
|
||||
}
|
||||
if (empty($arrayProperty["TAS_SELFSERVICE_EXECUTION"])) {
|
||||
throw (new \Exception("Invalid value specified for 'tas_selfservice_execution'"));
|
||||
}
|
||||
} else {
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TIME");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TIME_UNIT");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_TRIGGER_UID");
|
||||
$this->unsetVar($arrayProperty, "TAS_SELFSERVICE_EXECUTION");
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -325,7 +332,7 @@ class Task
|
||||
if (!isset($arrayProperty["TAS_DURATION"])) {
|
||||
throw (new \Exception("Invalid value specified for 'tas_duration'"));
|
||||
}
|
||||
$valuesTimeUnit = array('DAYS','HOURS');
|
||||
$valuesTimeUnit = array('DAYS','HOURS','MINUTES');
|
||||
if ((!isset($arrayProperty["TAS_TIMEUNIT"])) ||
|
||||
(!in_array($arrayProperty["TAS_TIMEUNIT"], $valuesTimeUnit))) {
|
||||
throw (new \Exception("Invalid value specified for 'tas_timeunit'"));
|
||||
|
||||
@@ -181,6 +181,31 @@ class Trigger
|
||||
}
|
||||
}
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (\PMLicensedFeatures::getSingleton()->verifyfeature("B0oWlBLY3hHdWY0YUNpZEtFQm5CeTJhQlIwN3IxMEkwaG4=") &&
|
||||
isset($dataTrigger["TRI_WEBBOT"])
|
||||
) {
|
||||
//Check disabled code
|
||||
\G::LoadClass("codeScanner");
|
||||
|
||||
$arraySystemConfiguration = \System::getSystemConfiguration(PATH_CONFIG . "env.ini");
|
||||
|
||||
$cs = new \CodeScanner((isset($arraySystemConfiguration["enable_blacklist"]) && (int)($arraySystemConfiguration["enable_blacklist"]) == 1)? "DISABLED_CODE" : "");
|
||||
|
||||
$arrayFoundDisabledCode = $cs->checkDisabledCode("SOURCE", $dataTrigger["TRI_WEBBOT"]);
|
||||
|
||||
if (!empty($arrayFoundDisabledCode)) {
|
||||
$strCodeAndLine = "";
|
||||
|
||||
foreach ($arrayFoundDisabledCode["source"] as $key => $value) {
|
||||
$strCodeAndLine .= (($strCodeAndLine != "")? ", " : "") . \G::LoadTranslation("ID_DISABLED_CODE_CODE_AND_LINE", array($key, implode(", ", $value)));
|
||||
}
|
||||
|
||||
throw new \Exception(\G::LoadTranslation("ID_DISABLED_CODE_TRIGGER", array($strCodeAndLine)));
|
||||
}
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
$dataTrigger['PRO_UID'] = $sProcessUID;
|
||||
$oTrigger = new \Triggers();
|
||||
if ($create) {
|
||||
|
||||
@@ -27,7 +27,7 @@ abstract class Importer
|
||||
const IMPORT_STAT_INVALID_SOURCE_FILE = 102; //Error, Invalid file type or the file have corrupt data.
|
||||
const IMPORT_STAT_GROUP_ALREADY_EXISTS = 105; //Error, Group already exists.
|
||||
|
||||
public abstract function load();
|
||||
public abstract function load($filename = null);
|
||||
|
||||
/**
|
||||
* Verify if exists reserved words SQL
|
||||
|
||||
@@ -24,9 +24,13 @@ class XmlImporter extends Importer
|
||||
* )
|
||||
* @throws \Exception
|
||||
*/
|
||||
public function load()
|
||||
public function load($filename = null)
|
||||
{
|
||||
$this->dom->load($this->filename);
|
||||
if (!is_null($filename) && !file_exists($filename)) {
|
||||
throw new \Exception(\G::LoadTranslation("ID_INVALID_FILE"));
|
||||
}
|
||||
|
||||
$this->dom->load((is_null($filename))? $this->filename : $filename);
|
||||
$this->root = $this->dom->documentElement;
|
||||
|
||||
// validate version
|
||||
|
||||
@@ -258,7 +258,7 @@ class ActivityPropertiesStructure
|
||||
public $tas_selfservice_timeout;
|
||||
|
||||
/**
|
||||
* @var string {@from body} {@choice DAYS,,HOURS}
|
||||
* @var string {@from body} {@choice DAYS,,HOURS,MINUTES}
|
||||
*/
|
||||
public $tas_selfservice_time_unit;
|
||||
|
||||
@@ -267,6 +267,11 @@ class ActivityPropertiesStructure
|
||||
*/
|
||||
public $tas_selfservice_trigger_uid;
|
||||
|
||||
/**
|
||||
* @var string {@from body} {@choice EVERY_TIME,ONCE}
|
||||
*/
|
||||
public $tas_selfservice_execution;
|
||||
|
||||
/**
|
||||
* @var string {@from body} {@choice TRUE,FALSE}
|
||||
*/
|
||||
|
||||
@@ -151,12 +151,16 @@
|
||||
<a href="#" class="btn_create mafe-menu-databaseconnections-create"><span></span></a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" class="mafe-menu-permissions"></a>
|
||||
<a href="#" class="btn_create mafe-menu-permissions-create"><span></span></a>
|
||||
<a href="#" class="mafe-menu-templates"></a>
|
||||
<a href="#" class="btn_create mafe-menu-templates-create"><span></span></a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" class="mafe-menu-filemanager"></a>
|
||||
<a href="#" class="btn_create mafe-menu-filemanager-create"><span></span></a>
|
||||
<a href="#" class="mafe-menu-public"></a>
|
||||
<a href="#" class="btn_create mafe-menu-public-create"><span></span></a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" class="mafe-menu-permissions"></a>
|
||||
<a href="#" class="btn_create mafe-menu-permissions-create"><span></span></a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" class="mafe-menu-supervisors"></a>
|
||||
|
||||
@@ -49,7 +49,6 @@ emailServer.application = {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
switch (option) {
|
||||
|
||||
case "INS":
|
||||
var typeEmailEngine = Ext.getCmp("cboEmailEngine").getValue();
|
||||
|
||||
@@ -1049,10 +1048,14 @@ emailServer.application = {
|
||||
var arrayAux1 = [];
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
if (EMAILSERVER_LICENSED) {
|
||||
arrayAux1.push(btnNew);
|
||||
arrayAux1.push("-");
|
||||
}
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
arrayAux1.push(btnEdit);
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
arrayAux1.push(btnDelete);
|
||||
arrayAux1.push("->");
|
||||
@@ -1102,6 +1105,7 @@ emailServer.application = {
|
||||
var arrayAux2 = [];
|
||||
|
||||
arrayAux2.push(btnEdit);
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
arrayAux2.push(btnDelete);
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
@@ -1154,7 +1154,7 @@ Ext.onReady(function() {
|
||||
store: addonsStore,
|
||||
defaultType: "displayfield",
|
||||
padding: 5,
|
||||
autoHeight : true,
|
||||
height: 335,
|
||||
disabled: !licensed,
|
||||
columns: [
|
||||
expander,
|
||||
@@ -1605,4 +1605,3 @@ Ext.onReady(function() {
|
||||
addonsFeaturesStore.load();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
{
|
||||
oCasesFrame = document.getElementById('frameMain');
|
||||
oClientWinSize = getClientWindowSize();
|
||||
height = oClientWinSize.height - 105;
|
||||
height = oClientWinSize.height - 70 + "px";
|
||||
oCasesFrame.style.height = height;
|
||||
}
|
||||
function getStyle(targetElement,styleProp)
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
<en><![CDATA[Time]]></en>
|
||||
</TAS_SELFSERVICE_TIME>
|
||||
<TAS_SELFSERVICE_TIME_UNIT type="dropdown">
|
||||
<en><![CDATA[Time unit]]><option name="HOURS"><![CDATA[Hours]]></option><option name="DAYS"><![CDATA[Days]]></option></en>
|
||||
<en><![CDATA[Time unit]]><option name="HOURS"><![CDATA[Hours]]></option><option name="DAYS"><![CDATA[Days]]></option><option name="MINUTES"><![CDATA[Minutes]]></option></en>
|
||||
</TAS_SELFSERVICE_TIME_UNIT>
|
||||
<TAS_SELFSERVICE_TRIGGER_UID type="dropdown" required="1"><![CDATA[
|
||||
SELECT TGR.TRI_UID, CON.CON_VALUE
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
<en><![CDATA[Task duration]]></en>
|
||||
</TAS_DURATION>
|
||||
<TAS_TIMEUNIT type="dropdown" defaultvalue="DAYS" group="1">
|
||||
<en><![CDATA[Time unit]]><option name="HOURS"><![CDATA[Hours]]></option><option name="DAYS"><![CDATA[Days]]></option></en>
|
||||
<en><![CDATA[Time unit]]><option name="HOURS"><![CDATA[Hours]]></option><option name="DAYS"><![CDATA[Days]]></option><option name="MINUTES"><![CDATA[Minutes]]></option></en>
|
||||
</TAS_TIMEUNIT>
|
||||
<TAS_TYPE_DAY type="dropdown" defaultvalue="1" group="1">
|
||||
<en><![CDATA[Count days by]]><option name="1"><![CDATA[Work Days]]></option><option name="2"><![CDATA[Calendar Days]]></option></en>
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 8.9 KiB After Width: | Height: | Size: 11 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 9.9 KiB |
Reference in New Issue
Block a user