HOR-4070
This commit is contained in:
@@ -267,7 +267,7 @@ class DataBaseMaintenance
|
||||
// Commented that is not assigned to a variable.
|
||||
// mysql_escape_string("';");
|
||||
if (! @mysql_query( $sql )) {
|
||||
$ws = (!empty(config("system.workspace")))? config("system.workspace") : "Wokspace Undefined";
|
||||
$ws = (!empty(config("system.workspace")))? config("system.workspace") : "Undefined Workspace";
|
||||
Bootstrap::registerMonolog('MysqlCron', 400, mysql_error(), array('sql'=>$sql), $ws, 'processmaker.log');
|
||||
$varRes = mysql_error() . "\n";
|
||||
G::outRes( $varRes );
|
||||
@@ -288,7 +288,7 @@ class DataBaseMaintenance
|
||||
$tableName = str_replace( '.dump', '', basename( $backupFile ) );
|
||||
$sql = "LOAD DATA INFILE '$backupFile' INTO TABLE $tableName FIELDS TERMINATED BY '\t|\t' OPTIONALLY ENCLOSED BY '\"' LINES TERMINATED BY '\t\t\r\r\n'";
|
||||
if (! @mysql_query( $sql )) {
|
||||
$ws = (!empty(config("system.workspace")))? config("system.workspace") : "Wokspace Undefined";
|
||||
$ws = (!empty(config("system.workspace")))? config("system.workspace") : "Undefined Workspace";
|
||||
Bootstrap::registerMonolog('MysqlCron', 400, mysql_error(), array('sql'=>$sql), $ws, 'processmaker.log');
|
||||
$varRes = mysql_error() . "\n";
|
||||
G::outRes( $varRes );
|
||||
|
||||
@@ -5447,7 +5447,7 @@ class G
|
||||
*/
|
||||
public static function auditLog($actionToLog, $valueToLog = "")
|
||||
{
|
||||
$workspace = !empty(config("system.workspace")) ? config("system.workspace") : 'Wokspace Undefined';
|
||||
$workspace = !empty(config("system.workspace")) ? config("system.workspace") : 'Undefined Workspace';
|
||||
$conf = new Configurations();
|
||||
$sflag = $conf->getConfiguration('AUDIT_LOG', 'log');
|
||||
$sflagAudit = $sflag == 'true' ? true : false;
|
||||
|
||||
@@ -21,7 +21,7 @@ class PMException extends Exception
|
||||
}
|
||||
|
||||
public static function registerErrorLog($error, $token){
|
||||
$ws = (!empty(config("system.workspace")))? config("system.workspace") : "Wokspace Undefined";
|
||||
$ws = (!empty(config("system.workspace")))? config("system.workspace") : "Undefined Workspace";
|
||||
Bootstrap::registerMonolog('ExceptionCron', 400, $error->getMessage(), array('token'=>$token), $ws, 'processmaker.log');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -255,7 +255,7 @@ class XmlFormField
|
||||
$rs = $con->executeQuery( $query, ResultSet::FETCHMODE_NUM );
|
||||
} catch (Exception $e) {
|
||||
//dismiss error because dbarray shouldnt be defined in some contexts.
|
||||
$workspace = !empty(config("system.workspace"))? config("system.workspace") : "Wokspace Undefined";
|
||||
$workspace = !empty(config("system.workspace"))? config("system.workspace") : "Undefined Workspace";
|
||||
G::log($workspace . " | ip: | " . G::getIpAddress() . " | type error: | " . $e->getMessage() . " | query: " . $query, PATH_DATA, "queriesWithErrors.log");
|
||||
|
||||
return $result;
|
||||
@@ -267,7 +267,7 @@ class XmlFormField
|
||||
$rs = $stmt->executeQuery( $query, ResultSet::FETCHMODE_NUM );
|
||||
} catch (Exception $e) {
|
||||
//dismiss error because dbarray shouldnt be defined in some contexts.
|
||||
$workspace = !empty(config("system.workspace"))? config("system.workspace") : "Wokspace Undefined";
|
||||
$workspace = !empty(config("system.workspace"))? config("system.workspace") : "Undefined Workspace";
|
||||
G::log($workspace . " | ip: | " . G::getIpAddress() . " | type error: | " . $e->getMessage() . " | query: " . $query, PATH_DATA, "queriesWithErrors.log");
|
||||
|
||||
return $result;
|
||||
|
||||
@@ -650,7 +650,7 @@ class IndicatorsCalculator
|
||||
}
|
||||
|
||||
private function pdoConnection() {
|
||||
$currentWS = !empty(config("system.workspace")) ? config("system.workspace") : 'Wokspace Undefined';
|
||||
$currentWS = !empty(config("system.workspace")) ? config("system.workspace") : 'Undefined Workspace';
|
||||
$workSpace = new WorkspaceTools($currentWS);
|
||||
$arrayHost = explode(':', $workSpace->dbHost);
|
||||
$host = "host=".$arrayHost[0];
|
||||
|
||||
@@ -63,7 +63,7 @@ class EmailServer
|
||||
$currentUser = $RBAC->aUserInfo['USER_INFO'];
|
||||
$info = array(
|
||||
'ip' => G::getIpAddress(),
|
||||
'workspace' => (!empty(config("system.workspace"))) ? config("system.workspace") : "Workspace undefined",
|
||||
'workspace' => (!empty(config("system.workspace"))) ? config("system.workspace") : "Undefined Workspace",
|
||||
'usrUid' => $currentUser['USR_UID']
|
||||
);
|
||||
$this->setContextLog($info);
|
||||
|
||||
@@ -1151,7 +1151,7 @@ class TimerEvent
|
||||
private function log($action, $value = "", $status = "action")
|
||||
{
|
||||
try {
|
||||
$workspace = (!empty(config("system.workspace")))? config("system.workspace") : "Wokspace Undefined";
|
||||
$workspace = (!empty(config("system.workspace")))? config("system.workspace") : "Undefined Workspace";
|
||||
$ipClient = \G::getIpAddress();
|
||||
|
||||
$actionTimer = "timereventcron: ";
|
||||
|
||||
@@ -138,7 +138,7 @@ class Bpmn extends Handler
|
||||
//Define the variables for the logging
|
||||
$info = array(
|
||||
'ip' => G::getIpAddress(),
|
||||
'workspace' => (!empty(config("system.workspace")))? config("system.workspace") : "Workspace undefined"
|
||||
'workspace' => (!empty(config("system.workspace")))? config("system.workspace") : "Undefined Workspace"
|
||||
);
|
||||
$this->setContextLog($info);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user