diff --git a/gulliver/js/codemirror/addon/tern/tern.js b/gulliver/js/codemirror/addon/tern/tern.js index 7f83c4e4c..6f82f104c 100644 --- a/gulliver/js/codemirror/addon/tern/tern.js +++ b/gulliver/js/codemirror/addon/tern/tern.js @@ -614,7 +614,7 @@ send({type: "getFile", err: String(err), text: text, id: data.id}); }); } else if (data.type == "debug") { - console.log(data.message); + //console.log(data.message); } else if (data.id && pending[data.id]) { pending[data.id](data.err, data.body); delete pending[data.id]; diff --git a/gulliver/system/class.g.php b/gulliver/system/class.g.php index 9f6866d77..69301c68f 100644 --- a/gulliver/system/class.g.php +++ b/gulliver/system/class.g.php @@ -5558,90 +5558,62 @@ class G foreach ($allowedTypes as $allowedType) { switch ($allowedType) { case 'xls': - if ($docType[1] == 'vnd.ms-excel' || ($fileExtension == 'xls' && $docType[1] == 'plain')) { - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'vnd.ms-excel' || ($fileExtension == 'xls' && $docType[1] == 'plain')); + return $res; break; case 'doc': - if ($docType[1] == 'msword' || ($fileExtension == 'doc' && $docType[1] == 'html')) { - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'msword' || ($fileExtension == 'doc' && $docType[1] == 'html')); + return $res; break; case 'ppt': - if ($docType[1] == 'vnd.ms-office') { - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'vnd.ms-office'); + return $res; break; case 'docx': - if ($docType[1] == 'vnd.openxmlformats-officedocument.wordprocessingml.document') { - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'vnd.openxmlformats-officedocument.wordprocessingml.document'); + return $res; break; case 'pptx': - if ($docType[1] == 'vnd.openxmlformats-officedocument.presentationml.presentation') { - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'vnd.openxmlformats-officedocument.presentationml.presentation'); + return $res; break; case 'xlsx': - if ($docType[1] == 'vnd.openxmlformats-officedocument.spreadsheetml.sheet') { - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'vnd.openxmlformats-officedocument.spreadsheetml.sheet'); + return $res; break; case 'exe': - if ($docType[1] == 'x-msdownload' || $docType[1] == 'x-dosexec') { - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'x-msdownload' || $docType[1] == 'x-dosexec'); + return $res; break; case 'wmv': - if($docType[1] == 'x-ms-asf' || $docType[1] == 'x-ms-wmv'){ - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'x-ms-asf' || $docType[1] == 'x-ms-wmv'); + return $res; break; case 'jpg': - if ($docType[1] == 'jpeg'){ - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'jpeg'); + return $res; break; case 'mp3': - if ($docType[1] == 'mpeg'){ - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'mpeg'); + return $res; break; case 'rar': - if ($docType[1] == 'x-rar'){ - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'x-rar'); + return $res; break; case 'txt': case 'pm': - if ($docType[1] == 'plain'){ - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'plain'); + return $res; break; case 'htm': case 'html': - if ($docType[1] == 'html'){ - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'html'); + return $res; break; case 'po': - if ($docType[1] == 'x-po'){ - $res->status = true; - return $res; - } + $res->status = ($docType[1] == 'x-po'); + return $res; break; case 'pdf': case 'png': @@ -5649,16 +5621,12 @@ class G case 'gif': case 'zip': case 'mp4': - if ($docType[1] == $allowedType){ - $res->status = true; - return $res; - } + $res->status = ($docType[1] == $allowedType); + return $res; break; default: - if ($validExtension) { - $res->status = true; - return $res; - } + $res->status = ($validExtension); + return $res; break; } } diff --git a/gulliver/thirdparty/pear/Net/FTP.php b/gulliver/thirdparty/pear/Net/FTP.php index 4f8ad4d5c..eae1f6707 100755 --- a/gulliver/thirdparty/pear/Net/FTP.php +++ b/gulliver/thirdparty/pear/Net/FTP.php @@ -1406,7 +1406,7 @@ class Net_FTP extends PEAR * NET_FTP_ERR_REMOTEPATHNODIR, NET_FTP_ERR_LOCALPATHNODIR, * NET_FTP_ERR_CREATELOCALDIR_FAILED */ - function getRecursive($remote_path, $local_path, $overwrite = false, + function getRecursive($remote_path, $local_p, $overwrite = false, $mode = null) { if (!class_exists('G')) { @@ -1426,16 +1426,16 @@ class Net_FTP extends PEAR "' seems not to be a directory.", NET_FTP_ERR_REMOTEPATHNODIR); } - if (!$this->_checkDir($local_path)) { - return $this->raiseError("Given local-path '".$local_path. + if (!$this->_checkDir($local_p)) { + return $this->raiseError("Given local-path '".$local_p. "' seems not to be a directory.", NET_FTP_ERR_LOCALPATHNODIR); } - if (!@is_dir($filter->validatePath($local_path))) { - $res = @mkdir($filter->validatePath($local_path)); + if (!@is_dir($filter->validatePath($local_p))) { + $res = @mkdir($filter->validatePath($local_p)); if (!$res) { - return $this->raiseError("Could not create dir '$local_path'", + return $this->raiseError("Could not create dir '$local_p'", NET_FTP_ERR_CREATELOCALDIR_FAILED); } } @@ -1447,9 +1447,9 @@ class Net_FTP extends PEAR foreach ($dir_list as $dir_entry) { if ($dir_entry['name'] != '.' && $dir_entry['name'] != '..') { $remote_path_new = $remote_path.$dir_entry["name"]."/"; - $local_path_new = $local_path.$dir_entry["name"]."/"; + $local_p_new = $local_p.$dir_entry["name"]."/"; $result = $this->getRecursive($remote_path_new, - $local_path_new, $overwrite, $mode); + $local_p_new, $overwrite, $mode); if ($this->isError($result)) { return $result; } @@ -1462,7 +1462,7 @@ class Net_FTP extends PEAR } foreach ($file_list as $file_entry) { $remote_file = $remote_path.$file_entry["name"]; - $local_file = $local_path.$file_entry["name"]; + $local_file = $local_p.$file_entry["name"]; $result = $this->get($remote_file, $local_file, $overwrite, $mode); if ($this->isError($result)) { return $result; diff --git a/gulliver/thirdparty/pear/Net/FTP/Socket.php b/gulliver/thirdparty/pear/Net/FTP/Socket.php index 0319cb564..bf3026b01 100755 --- a/gulliver/thirdparty/pear/Net/FTP/Socket.php +++ b/gulliver/thirdparty/pear/Net/FTP/Socket.php @@ -672,11 +672,12 @@ function ftp_get(&$control, $local, $remote, $mode, $resume = 0) } if(is_file($filter->validatePath($local))) { - $fp = fopen($filter->validatePath($local), 'w'.$windows[$mode]); + $var = 'w'.$windows[$mode]; + $fp = fopen($filter->validatePath($local), $var); } else { $fp = false; } - + if (!is_resource($fp)) { $fp = null; return false; diff --git a/gulliver/thirdparty/phing/lib/Capsule.php b/gulliver/thirdparty/phing/lib/Capsule.php index 904ea5a02..246664073 100755 --- a/gulliver/thirdparty/phing/lib/Capsule.php +++ b/gulliver/thirdparty/phing/lib/Capsule.php @@ -124,13 +124,13 @@ class Capsule { $path = $this->templatePath . PATH_SEPARATOR . $__old_inc_path; if(strpos($path,":")>0){ - $firstPath = explode(":", $this->templatePath . PATH_SEPARATOR . $__old_inc_path); + $firstPath = explode(":", $path); if (is_dir($firstPath[0])) { - ini_set('include_path', $this->templatePath . PATH_SEPARATOR . $__old_inc_path); + ini_set('include_path', $path); } } else { - if(is_dir($this->templatePath . PATH_SEPARATOR . $__old_inc_path)) { - ini_set('include_path', $this->templatePath . PATH_SEPARATOR . $__old_inc_path); + if(is_dir($path)) { + ini_set('include_path', $path); } } diff --git a/gulliver/thirdparty/tcpdf/tcpdf.php b/gulliver/thirdparty/tcpdf/tcpdf.php index 5e96dd903..43b53cfa1 100644 --- a/gulliver/thirdparty/tcpdf/tcpdf.php +++ b/gulliver/thirdparty/tcpdf/tcpdf.php @@ -18281,7 +18281,7 @@ class TCPDF { * @author Nicola Asuni * @since 4.6.005 (2009-04-24) */ - public function setSignature($signing_cert='', $private_key='', $private_key_password='', $extracerts='', $cert_type=2, $info=array()) { + public function setSignature($signing_cert='', $private_key='', $private_key_p='', $extracerts='', $cert_type=2, $info=array()) { // to create self-signed signature: openssl req -x509 -nodes -days 365000 -newkey rsa:1024 -keyout tcpdf.crt -out tcpdf.crt // to export crt to p12: openssl pkcs12 -export -in tcpdf.crt -out tcpdf.p12 // to convert pfx certificate to pem: openssl @@ -18293,14 +18293,14 @@ class TCPDF { $this->signature_data = array(); if (strlen($signing_cert) == 0) { $signing_cert = 'file://'.dirname(__FILE__).'/tcpdf.crt'; - $private_key_password = 'tcpdfdemo'; + $private_key_p = 'tcpdfdemo'; } if (strlen($private_key) == 0) { $private_key = $signing_cert; } $this->signature_data['signcert'] = $signing_cert; $this->signature_data['privkey'] = $private_key; - $this->signature_data['password'] = $private_key_password; + $this->signature_data['password'] = $private_key_p; $this->signature_data['extracerts'] = $extracerts; $this->signature_data['cert_type'] = $cert_type; $this->signature_data['info'] = $info; diff --git a/workflow/engine/js/dbConnections/main.js b/workflow/engine/js/dbConnections/main.js index f27d87559..4da60c47d 100755 --- a/workflow/engine/js/dbConnections/main.js +++ b/workflow/engine/js/dbConnections/main.js @@ -297,9 +297,9 @@ function testHost(step) var user = $('form[DBS_USERNAME]').value; if($('form[DBS_PASSWORD]').value != '') { - var passwd = $('form[DBS_PASSWORD]').value; + var pas = $('form[DBS_PASSWORD]').value; } else { - var passwd = 'none'; + var pas = 'none'; } if($('form[DBS_PORT]').value.trim() != '') { @@ -312,7 +312,7 @@ function testHost(step) var tns = getField("DBS_TNS").value; var requestfile = PROCESS_REQUEST_FILE; - var uri = 'action=testConnection&step='+step+'&type='+type+'&server='+server+'&db_name='+db_name+'&user='+user+'&port='+port+'&passwd='+passwd + "&connectionType=" + connectionType + "&tns=" + tns; + var uri = 'action=testConnection&step='+step+'&type='+type+'&server='+server+'&db_name='+db_name+'&user='+user+'&port='+port+'&passwd='+pas + "&connectionType=" + connectionType + "&tns=" + tns; var ajax = AJAX(); mainRequest = ajax; diff --git a/workflow/engine/methods/dbConnections/dbConnectionsAjax.php b/workflow/engine/methods/dbConnections/dbConnectionsAjax.php index eb7670381..4cbf2b76e 100755 --- a/workflow/engine/methods/dbConnections/dbConnectionsAjax.php +++ b/workflow/engine/methods/dbConnections/dbConnectionsAjax.php @@ -351,7 +351,8 @@ switch ($action) { if ($engine != "0") { $dbs = new dbConnections(); - echo Bootstrap::json_encode($dbs->getEncondeList($filter->xssFilterHard($engine))); + $var = Bootstrap::json_encode($dbs->getEncondeList($filter->xssFilterHard($engine))); + echo $var; } else { echo '[["0","..."]]'; diff --git a/workflow/engine/methods/users/users_Ajax.php b/workflow/engine/methods/users/users_Ajax.php index d517b980a..a2d63f96d 100644 --- a/workflow/engine/methods/users/users_Ajax.php +++ b/workflow/engine/methods/users/users_Ajax.php @@ -91,11 +91,13 @@ try { $oTasks = new Tasks(); switch ((int) $_POST['TU_RELATION']) { case 1: - echo htmlentities($oTasks->assignUser($_POST['TAS_UID'], $_POST['USR_UID'], $_POST['TU_TYPE']), ENT_QUOTES | ENT_HTML5, 'UTF-8'); + $resh = htmlentities($oTasks->assignUser($_POST['TAS_UID'], $_POST['USR_UID'], $_POST['TU_TYPE']), ENT_QUOTES | ENT_HTML5, 'UTF-8'); + echo $res; G::auditlog("AssignUserTask","Assign a User to a Task -> ".$_POST['TAS_UID'].' User UID -> '.$_POST['USR_UID']); break; case 2: - echo htmlentities($oTasks->assignGroup($_POST['TAS_UID'], $_POST['USR_UID'], $_POST['TU_TYPE']), ENT_QUOTES | ENT_HTML5, 'UTF-8'); + $resh = htmlentities($oTasks->assignGroup($_POST['TAS_UID'], $_POST['USR_UID'], $_POST['TU_TYPE']), ENT_QUOTES | ENT_HTML5, 'UTF-8'); + echo $resh; G::auditlog("AssignGroupTask","Assign a Group to a Task -> ".$_POST['TAS_UID'].' User UID -> '.$_POST['USR_UID']); break; } diff --git a/workflow/engine/templates/reportTables/mainLoad.php b/workflow/engine/templates/reportTables/mainLoad.php deleted file mode 100755 index 3be5caa4c..000000000 --- a/workflow/engine/templates/reportTables/mainLoad.php +++ /dev/null @@ -1,50 +0,0 @@ -xssFilterHard($_GET['gui']); - $gui = $_GET['gui']; -} -?> - - - - - - - \ No newline at end of file diff --git a/workflow/engine/templates/setup/environmentSettings.js b/workflow/engine/templates/setup/environmentSettings.js index cd45a7533..3482e1872 100755 --- a/workflow/engine/templates/setup/environmentSettings.js +++ b/workflow/engine/templates/setup/environmentSettings.js @@ -3,7 +3,7 @@ var fsSamples; var fsNames; var fsDates; var fsCases; -var _firstName, _lastName, _userName, _dateSample; +var _firstName, _lastName, _uName, _dateSample; var txtCasesRefreshTime; @@ -12,7 +12,7 @@ Ext.onReady(function() { _firstName = 'John'; _lastName = 'Deere'; - _userName = 'johndeere'; + _uName = 'johndeere'; _dateSample = '2011-02-17 19:15:38'; fsSample = new Ext.form.FieldSet({ @@ -321,7 +321,7 @@ Ext.onReady(function() { //Load Samples Label loadSamples = function () { - Ext.getCmp("lblFullName").setText(_FNF(_userName, _firstName, _lastName, FORMATS.format)); + Ext.getCmp("lblFullName").setText(_FNF(_uName, _firstName, _lastName, FORMATS.format)); Ext.getCmp("lblDateFormat").setText(_DF(_dateSample, FORMATS.dateFormat)); Ext.getCmp("lblCasesDateFormat").setText(_DF(_dateSample, FORMATS.casesListDateFormat, FORMATS.casesListDateFormat)); //Ext.getCmp("lblCasesRowsList").setText(FORMATS.casesListRowNumber); @@ -338,7 +338,7 @@ changeSettings = function (iType) var f = FORMATS.format; FORMATS.format = cmbUsernameFormat.getValue(); - Ext.getCmp("lblFullName").setText(_FNF(_userName, _firstName, _lastName, cmbUsernameFormat.getValue())); + Ext.getCmp("lblFullName").setText(_FNF(_uName, _firstName, _lastName, cmbUsernameFormat.getValue())); FORMATS.format = f; break; case 2: