From 684008944fdabe8c8b7aab56e0c37f24fd9f6b4d Mon Sep 17 00:00:00 2001 From: Henry Jordan Date: Tue, 26 Oct 2021 19:30:58 +0000 Subject: [PATCH 1/7] PMCORE-3458 --- .../js/home/TaskMetrics/VueChartLvThree.vue | 80 +++++++++---------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/resources/assets/js/home/TaskMetrics/VueChartLvThree.vue b/resources/assets/js/home/TaskMetrics/VueChartLvThree.vue index bbd17f288..2ae16d432 100644 --- a/resources/assets/js/home/TaskMetrics/VueChartLvThree.vue +++ b/resources/assets/js/home/TaskMetrics/VueChartLvThree.vue @@ -137,11 +137,11 @@ export default { size: this.data[3] && this.data[3].data.size ? this.data[3].data.size - : { name: this.$t("ID_ALL"), id: "all" }, + : { name: "20", id: "20" }, riskType: this.data[3] && this.data[3].data.riskType ? this.data[3].data.riskType - : "ON_TIME", + : "AT_RISK", settingsBreadcrumbs: [ { class: "fas fa-info-circle", @@ -150,11 +150,11 @@ export default { }, ], sizeOptions: [ - { name: this.$t("ID_ALL"), id: "all" }, - { name: "5", id: "5" }, { name: "10", id: "10" }, - { name: "15", id: "15" }, { name: "20", id: "20" }, + { name: "30", id: "30" }, + { name: "40", id: "40" }, + { name: "50", id: "50" }, ], dataCasesByRisk: [], width: 0, @@ -222,47 +222,47 @@ export default { * Change datepickers or radio button */ changeOption() { - let dt; - if (this.dateFrom && this.dateTo) { - dt = { - process: this.data[2].id, - caseList: this.data[1].id.toLowerCase(), - dateFrom: moment(this.dateFrom).format("YYYY-MM-DD"), - dateTo: moment(this.dateTo).format("YYYY-MM-DD"), - riskStatus: this.riskType, - }; - this.size.id != "all" ? (dt["topCases"] = this.size.id) : null; - this.dateNow = moment().format("YYYY-MM-DD h:mm:ss a"); - this.updateSettings(); - } + let dt; + if (this.dateFrom && this.dateTo) { + dt = { + process: this.data[2].id, + caseList: this.data[1].id.toLowerCase(), + dateFrom: moment(this.dateFrom).format("YYYY-MM-DD"), + dateTo: moment(this.dateTo).format("YYYY-MM-DD"), + riskStatus: this.riskType, + }; + this.size.id != "all" ? (dt["topCases"] = this.size.id) : null; + this.dateNow = moment().format("YYYY-MM-DD h:mm:ss a"); + this.updateSettings(); + } }, /** * Load option saved in userConfig */ loadOption() { - let that = this, - dt; - if (this.data.length > 2) { - if (this.dateFrom && this.dateTo) { - dt = { - process: this.data[2].id, - caseList: this.data[1].id.toLowerCase(), - dateFrom: moment(this.dateFrom).format("YYYY-MM-DD"), - dateTo: moment(this.dateTo).format("YYYY-MM-DD"), - riskStatus: this.riskType, - }; - this.size.id != "all" ? (dt["topCases"] = this.size.id) : null; - this.dateNow = moment().format("YYYY-MM-DD h:mm:ss a"); - Api.process - .totalCasesByRisk(dt) - .then((response) => { - that.formatDataRange(response.data); - }) - .catch((e) => { - console.error(e); - }); - } + let that = this, + dt; + if (this.data.length > 2) { + if (this.dateFrom && this.dateTo) { + dt = { + process: this.data[2].id, + caseList: this.data[1].id.toLowerCase(), + dateFrom: moment(this.dateFrom).format("YYYY-MM-DD"), + dateTo: moment(this.dateTo).format("YYYY-MM-DD"), + riskStatus: this.riskType, + }; + this.size.id != "all" ? (dt["topCases"] = this.size.id) : null; + this.dateNow = moment().format("YYYY-MM-DD h:mm:ss a"); + Api.process + .totalCasesByRisk(dt) + .then((response) => { + that.formatDataRange(response.data); + }) + .catch((e) => { + console.error(e); + }); } + } }, /** * Format response fromn API From 0db586541de12c38d153111c4f3eac15d246f238 Mon Sep 17 00:00:00 2001 From: Rodrigo Quelca Date: Wed, 27 Oct 2021 13:10:36 +0000 Subject: [PATCH 2/7] PMCORE-3459: Save Search in the Advanced Search does not update the saved search in the menu when saved PMCORE_3.7.0-5487 --- resources/assets/js/home/Home.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/resources/assets/js/home/Home.vue b/resources/assets/js/home/Home.vue index 0fa340acb..f437b4ed3 100755 --- a/resources/assets/js/home/Home.vue +++ b/resources/assets/js/home/Home.vue @@ -515,7 +515,7 @@ export default { addMenuSearchChild(data) { let newMenu = this.menu; let advSearch = _.find(newMenu, function(o) { - return o.id === "advanced-search"; + return o.id === "CASES_SEARCH"; }); if (advSearch) { const index = advSearch.child.findIndex(function(o) { @@ -533,7 +533,7 @@ export default { title: data.name, icon: "fas fa-circle", id: data.id, - page: "/advanced-search", + page: "advanced-search", }); } } @@ -565,7 +565,7 @@ export default { removeMenuSearchChild(id) { let newMenu = this.menu; let advSearch = _.find(newMenu, function(o) { - return o.id === "advanced-search"; + return o.id === "CASES_SEARCH"; }); if (advSearch) { const index = advSearch.child.findIndex(function(o) { From 0872f0ee719af98cd5e6dd3489ce3ce60773f713 Mon Sep 17 00:00:00 2001 From: Henry Jordan Date: Wed, 27 Oct 2021 15:21:17 +0000 Subject: [PATCH 3/7] PMCORE-3366 --- resources/assets/js/home/TaskMetrics/VueChartLvOne.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/assets/js/home/TaskMetrics/VueChartLvOne.vue b/resources/assets/js/home/TaskMetrics/VueChartLvOne.vue index 96379173f..b5acd26d5 100644 --- a/resources/assets/js/home/TaskMetrics/VueChartLvOne.vue +++ b/resources/assets/js/home/TaskMetrics/VueChartLvOne.vue @@ -294,7 +294,7 @@ export default { category: this.category.id, caseList: this.data[1].id.toLowerCase(), processes: this.selectedProcesses, - top: this.top, + topTen: this.top, }; this.category.id == "all" ? delete dt.category : null; Api.process From 48b4bd3d031fd05ff0e2bc094a67074c8a70fca1 Mon Sep 17 00:00:00 2001 From: fabio Date: Wed, 27 Oct 2021 11:27:57 -0400 Subject: [PATCH 4/7] PMCORE-3431:TASKS > Level 1 or Level 2 the mark position in the left menu is not updated after selecting Data option for a specific process --- resources/assets/js/home/Home.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/resources/assets/js/home/Home.vue b/resources/assets/js/home/Home.vue index f437b4ed3..be93519bf 100755 --- a/resources/assets/js/home/Home.vue +++ b/resources/assets/js/home/Home.vue @@ -163,7 +163,9 @@ export default { that.onUpdatePage(data); }); eventBus.$on('home::sidebar::click-item', (data) => { - that.OnClickSidebarItem(that.getItemMenuByValue("page",data)); + let item = that.getItemMenuByValue("page",data); + that.OnClickSidebarItem(item); + this.$router.push(item.item.href); }); eventBus.$on('home::update-settings', (data) => { that.updateSettings(data); From 3cb9043e70939793aee5c99b4cd6de3c8d5b72ac Mon Sep 17 00:00:00 2001 From: Andrea Adamczyk Date: Wed, 27 Oct 2021 12:46:39 -0400 Subject: [PATCH 5/7] PMCORE-3469 --- workflow/engine/classes/class.pmScript.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/workflow/engine/classes/class.pmScript.php b/workflow/engine/classes/class.pmScript.php index 50fca088e..d94104e6e 100644 --- a/workflow/engine/classes/class.pmScript.php +++ b/workflow/engine/classes/class.pmScript.php @@ -649,14 +649,15 @@ class PMScript Public function evaluateVariable() { $process = new Process(); - if (!$process->isBpmnProcess($_SESSION['PROCESS'])) { + $proUid = isset($_SESSION['PROCESS']) ? $_SESSION['PROCESS'] : null; + if (!$process->isBpmnProcess($proUid)) { return; } require_once PATH_CORE . 'controllers/pmTablesProxy.php'; $pmTablesProxy = new pmTablesProxy(); $variableModule = new ProcessMaker\BusinessModel\Variable(); $searchTypes = array('checkgroup', 'dropdown', 'suggest'); - $processVariables = $pmTablesProxy->getDynaformVariables($_SESSION['PROCESS'], $searchTypes, false); + $processVariables = $pmTablesProxy->getDynaformVariables($proUid, $searchTypes, false); $variables = $this->affected_fields; $variables = (is_array($variables)) ? array_unique($variables) : $variables; $newFields = []; @@ -678,7 +679,7 @@ class PMScript } } if (sizeof($arrayLabels)) { - $varInfo = $variableModule->getVariableTypeByName($_SESSION['PROCESS'], $var); + $varInfo = $variableModule->getVariableTypeByName($proUid, $var); if (is_array($varInfo) && sizeof($varInfo)) { $varType = $varInfo['VAR_FIELD_TYPE']; switch ($varType) { @@ -702,7 +703,7 @@ class PMScript } } if (isset($this->aFields[$var]) && is_string($this->aFields[$var])) { - $varInfo = $variableModule->getVariableTypeByName($_SESSION['PROCESS'], $var); + $varInfo = $variableModule->getVariableTypeByName($proUid, $var); $options = G::json_decode($varInfo["VAR_ACCEPTED_VALUES"]); $no = count($options); for ($io = 0; $io < $no; $io++) { From 582269b7f95f8a1628616170e949af4cf9a69ecd Mon Sep 17 00:00:00 2001 From: Roly Gutierrez Date: Wed, 27 Oct 2021 14:55:44 -0400 Subject: [PATCH 6/7] PMCORE-3196 CLONAR - [6261] La tarea 'Casos no asignados' en cron no funciona correctamente con 'system_utc_time_zone' habilitado --- gulliver/system/class.bootstrap.php | 2 +- .../BusinessModel/Cases/HomeTest.php | 4 +- .../BusinessModel/Cases/UnassignedTest.php | 14 ++-- .../src/ProcessMaker/Model/CaseListTest.php | 20 +++--- .../engine/methods/cases/cases_PrintView.php | 2 +- .../methods/tracker/tracker_PrintView.php | 2 +- .../src/ProcessMaker/BusinessModel/Cases.php | 11 +++- .../src/ProcessMaker/TaskScheduler/Task.php | 66 +++++++++---------- 8 files changed, 64 insertions(+), 57 deletions(-) diff --git a/gulliver/system/class.bootstrap.php b/gulliver/system/class.bootstrap.php index c99f4b9ef..f2250c7c9 100644 --- a/gulliver/system/class.bootstrap.php +++ b/gulliver/system/class.bootstrap.php @@ -2673,7 +2673,7 @@ class Bootstrap $context = [ 'ip' => G::getIpAddress(), 'workspace' => config('system.workspace', 'Undefined Workspace'), - 'timeZone' => DateTime::convertUtcToTimeZone(date('Y-m-d H:m:s')), + 'timeZone' => DateTime::convertUtcToTimeZone(date('Y-m-d H:i:s')), 'usrUid' => G::LoadTranslation('UID_UNDEFINED_USER') ]; $context = array_merge($context, $extraParams); diff --git a/tests/unit/workflow/engine/src/ProcessMaker/BusinessModel/Cases/HomeTest.php b/tests/unit/workflow/engine/src/ProcessMaker/BusinessModel/Cases/HomeTest.php index 5e7922ee6..36879d5d3 100644 --- a/tests/unit/workflow/engine/src/ProcessMaker/BusinessModel/Cases/HomeTest.php +++ b/tests/unit/workflow/engine/src/ProcessMaker/BusinessModel/Cases/HomeTest.php @@ -119,7 +119,7 @@ class HomeTest extends TestCase 'PRO_ID' => $process->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-1 year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-1 year")) ]); $home = new Home($user->USR_UID); @@ -415,7 +415,7 @@ class HomeTest extends TestCase 'PRO_ID' => $process->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-1 year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-1 year")) ]); $caseList = factory(CaseList::class)->create([ diff --git a/tests/unit/workflow/engine/src/ProcessMaker/BusinessModel/Cases/UnassignedTest.php b/tests/unit/workflow/engine/src/ProcessMaker/BusinessModel/Cases/UnassignedTest.php index c0475f04e..00c7f2720 100644 --- a/tests/unit/workflow/engine/src/ProcessMaker/BusinessModel/Cases/UnassignedTest.php +++ b/tests/unit/workflow/engine/src/ProcessMaker/BusinessModel/Cases/UnassignedTest.php @@ -84,7 +84,7 @@ class UnassignedTest extends TestCase 'PRO_ID' => $process->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-$i year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-$i year")) ]); } @@ -149,7 +149,7 @@ class UnassignedTest extends TestCase 'PRO_ID' => $process->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-$i year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-$i year")) ]); } @@ -193,7 +193,7 @@ class UnassignedTest extends TestCase 'PRO_ID' => $process->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-$i year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-$i year")) ]); } return $user; @@ -474,7 +474,7 @@ class UnassignedTest extends TestCase 'PRO_ID' => $process1->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-1 year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-1 year")) ]); $task2 = factory(Task::class)->create([ 'TAS_ASSIGN_TYPE' => 'SELF_SERVICE', @@ -494,7 +494,7 @@ class UnassignedTest extends TestCase 'PRO_ID' => $process2->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-2 year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-2 year")) ]); $unassigned = new Unassigned(); $unassigned->setUserId($user->USR_ID); @@ -555,7 +555,7 @@ class UnassignedTest extends TestCase 'PRO_ID' => $process1->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-1 year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-1 year")) ]); $task2 = factory(Task::class)->create([ 'TAS_ASSIGN_TYPE' => 'SELF_SERVICE', @@ -575,7 +575,7 @@ class UnassignedTest extends TestCase 'PRO_ID' => $process2->PRO_ID, 'DEL_THREAD_STATUS' => 'OPEN', 'USR_ID' => 0, - 'DEL_DELEGATE_DATE' => date('Y-m-d H:m:s', strtotime("-2 year")) + 'DEL_DELEGATE_DATE' => date('Y-m-d H:i:s', strtotime("-2 year")) ]); $unassigned = new Unassigned(); $unassigned->setUserId($user->USR_ID); diff --git a/tests/unit/workflow/engine/src/ProcessMaker/Model/CaseListTest.php b/tests/unit/workflow/engine/src/ProcessMaker/Model/CaseListTest.php index 87f500e3c..58aa78b50 100644 --- a/tests/unit/workflow/engine/src/ProcessMaker/Model/CaseListTest.php +++ b/tests/unit/workflow/engine/src/ProcessMaker/Model/CaseListTest.php @@ -43,8 +43,8 @@ class CaseListTest extends TestCase 'iconList' => 'deafult.png', 'iconColor' => 'red', 'iconColorScreen' => 'blue', - 'createDate' => date('Y-m-d H:m:s'), - 'updateDate' => date('Y-m-d H:m:s') + 'createDate' => date('Y-m-d H:i:s'), + 'updateDate' => date('Y-m-d H:i:s') ]; $array = CaseList::getColumnNameFromAlias($data); @@ -81,8 +81,8 @@ class CaseListTest extends TestCase 'CAL_ICON_LIST' => 'deafult.png', 'CAL_ICON_COLOR' => 'red', 'CAL_ICON_COLOR_SCREEN' => 'blue', - 'CAL_CREATE_DATE' => date('Y-m-d H:m:s'), - 'CAL_UPDATE_DATE' => date('Y-m-d H:m:s') + 'CAL_CREATE_DATE' => date('Y-m-d H:i:s'), + 'CAL_UPDATE_DATE' => date('Y-m-d H:i:s') ]; $array = CaseList::getAliasFromColumnName($data); @@ -118,8 +118,8 @@ class CaseListTest extends TestCase 'iconList' => 'deafult.png', 'iconColor' => 'red', 'iconColorScreen' => 'blue', - 'createDate' => date('Y-m-d H:m:s'), - 'updateDate' => date('Y-m-d H:m:s') + 'createDate' => date('Y-m-d H:i:s'), + 'updateDate' => date('Y-m-d H:i:s') ]; $caseList = CaseList::createSetting($data, $data['userId']); @@ -152,8 +152,8 @@ class CaseListTest extends TestCase 'iconList' => 'deafult.png', 'iconColor' => 'red', 'iconColorScreen' => 'blue', - 'createDate' => date('Y-m-d H:m:s'), - 'updateDate' => date('Y-m-d H:m:s') + 'createDate' => date('Y-m-d H:i:s'), + 'updateDate' => date('Y-m-d H:i:s') ]; $model = CaseList::createSetting($data, $data['userId']); @@ -194,8 +194,8 @@ class CaseListTest extends TestCase 'iconList' => 'deafult.png', 'iconColor' => 'red', 'iconColorScreen' => 'blue', - 'createDate' => date('Y-m-d H:m:s'), - 'updateDate' => date('Y-m-d H:m:s') + 'createDate' => date('Y-m-d H:i:s'), + 'updateDate' => date('Y-m-d H:i:s') ]; $model = CaseList::createSetting($data, $data['userId']); diff --git a/workflow/engine/methods/cases/cases_PrintView.php b/workflow/engine/methods/cases/cases_PrintView.php index 221f1f49a..22957a82c 100644 --- a/workflow/engine/methods/cases/cases_PrintView.php +++ b/workflow/engine/methods/cases/cases_PrintView.php @@ -71,7 +71,7 @@ try { $array['APP_TITLE'] = $Fields['TITLE']; $array['USR_USERNAME'] = $Fields['APP_DATA']['USR_USERNAME']; $array['USER_ENV'] = $Fields['APP_DATA']['SYS_SYS']; - $array['DATEPRINT'] = date( 'Y-m-d H:m:s' ); + $array['DATEPRINT'] = date( 'Y-m-d H:i:s' ); } $array['APP_PROCESS'] = $sProcess; diff --git a/workflow/engine/methods/tracker/tracker_PrintView.php b/workflow/engine/methods/tracker/tracker_PrintView.php index 58da6a0c5..333d28a79 100644 --- a/workflow/engine/methods/tracker/tracker_PrintView.php +++ b/workflow/engine/methods/tracker/tracker_PrintView.php @@ -48,7 +48,7 @@ try { $array['APP_TITLE'] = $Fields['TITLE']; $array['USR_USERNAME'] = $Fields['APP_DATA']['USR_USERNAME']; $array['USER_ENV'] = $Fields['APP_DATA']['SYS_SYS']; - $array['DATEPRINT'] = date( 'Y-m-d H:m:s' ); + $array['DATEPRINT'] = date( 'Y-m-d H:i:s' ); } $array['APP_PROCESS'] = $sProcess; diff --git a/workflow/engine/src/ProcessMaker/BusinessModel/Cases.php b/workflow/engine/src/ProcessMaker/BusinessModel/Cases.php index 7b0f27bf1..e126ae178 100644 --- a/workflow/engine/src/ProcessMaker/BusinessModel/Cases.php +++ b/workflow/engine/src/ProcessMaker/BusinessModel/Cases.php @@ -4140,10 +4140,15 @@ class Cases // Add the time in the corresponding unit to the delegation date $delegateDate = calculateDate($delegateDate, $taskSelfServiceTimeUnit, $taskSelfServiceTime); + $datetime = new DateTime($delegateDate); + //please the seconds is variant not must be considered + $delegateDate = $datetime->format('Y-m-d H:i:00'); // Define the current time $datetime = new DateTime('now'); - $currentDate = $datetime->format('Y-m-d H:i:s'); + //please the seconds is variant not must be considered + $currentDate = $datetime->format('Y-m-d H:i:00'); + $currentDate = UtilDateTime::convertDataToUtc($currentDate); // Check if the triggers to be executed if ($currentDate >= $delegateDate && $flagExecuteOnce) { @@ -4208,8 +4213,10 @@ class Cases 'tasUid' => $taskUid, 'selfServiceTime' => $taskSelfServiceTime, 'selfServiceTimeUnit' => $taskSelfServiceTimeUnit, + 'currentDate' => $currentDate, + 'delegateDate' => $delegateDate ]; - Log::channel(':TriggerExecution')->info('Timeout trigger execution', Bootstrap::context($context)); + Log::channel('taskScheduler:executeSelfServiceTimeout')->info('TriggerExecution', Bootstrap::context($context)); } unset($_SESSION["PROCESS"]); diff --git a/workflow/engine/src/ProcessMaker/TaskScheduler/Task.php b/workflow/engine/src/ProcessMaker/TaskScheduler/Task.php index 8dd09c6a4..d097a7e79 100644 --- a/workflow/engine/src/ProcessMaker/TaskScheduler/Task.php +++ b/workflow/engine/src/ProcessMaker/TaskScheduler/Task.php @@ -147,7 +147,7 @@ class Task public function resendEmails($now, $dateSystem) { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:resendEmails')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($now, $dateSystem, $scheduledTaskIdentifier) { $this->setExecutionMessage("Resending emails"); @@ -189,7 +189,7 @@ class Task $context = [ "trace" => $e->getTraceAsString() ]; - Log::channel('taskScheduler:taskScheduler')->error($e->getMessage(), Bootstrap::context($context)); + Log::channel('taskScheduler:resendEmails')->error($e->getMessage(), Bootstrap::context($context)); $criteria = new Criteria("workflow"); $criteria->clearSelectColumns(); $criteria->addSelectColumn(ConfigurationPeer::CFG_UID); @@ -212,7 +212,7 @@ class Task $this->saveLog("resendEmails", "error", "Error Resending Emails: " . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:resendEmails')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -224,7 +224,7 @@ class Task public function unpauseApplications($now) { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:unpauseApplications')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($now, $scheduledTaskIdentifier) { $this->setExecutionMessage("Unpausing applications"); @@ -242,7 +242,7 @@ class Task $this->saveLog('unpauseApplications', 'error', 'Error Unpausing Applications: ' . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:unpauseApplications')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -255,7 +255,7 @@ class Task function executeCaseSelfService() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:executeCaseSelfService')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($scheduledTaskIdentifier) { try { @@ -275,7 +275,7 @@ class Task $this->saveLog("unassignedCase", "error", "Error in unassigned case: " . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:executeCaseSelfService')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -286,7 +286,7 @@ class Task public function calculateDuration() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:calculateDuration')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($scheduledTaskIdentifier) { $this->setExecutionMessage("Calculating Duration"); @@ -303,7 +303,7 @@ class Task $this->saveLog('calculateDuration', 'error', 'Error Calculating Duration: ' . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:calculateDuration')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -314,7 +314,7 @@ class Task public function calculateAppDuration() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:calculateAppDuration')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($scheduledTaskIdentifier) { $this->setExecutionMessage("Calculating Duration by Application"); @@ -331,7 +331,7 @@ class Task $this->saveLog('calculateDurationByApp', 'error', 'Error Calculating Duration: ' . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:calculateAppDuration')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -342,7 +342,7 @@ class Task public function cleanSelfServiceTables() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:cleanSelfServiceTables')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($scheduledTaskIdentifier) { try { @@ -373,7 +373,7 @@ class Task $this->saveLog("ExecuteCleanSelfServiceTables", "error", "Error when try to clean self-service tables " . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:cleanSelfServiceTables')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -385,7 +385,7 @@ class Task public function executePlugins() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:executePlugins')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($scheduledTaskIdentifier) { $pathCronPlugins = PATH_CORE . 'bin' . PATH_SEP . 'plugins' . PATH_SEP; @@ -429,7 +429,7 @@ class Task } } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:executePlugins')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -475,7 +475,7 @@ class Task public function fillReportByUser($dateInit, $dateFinish) { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:fillReportByUser')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); if ($dateInit == null) { if ($this->asynchronous === false) { @@ -484,7 +484,7 @@ class Task } if ($this->asynchronous === true) { $message = 'You must enter the starting date. Example: +init-date"YYYY-MM-DD HH:MM:SS" +finish-date"YYYY-MM-DD HH:MM:SS"'; - Log::channel('taskScheduler:taskScheduler')->info($message, Bootstrap::context()); + Log::channel('taskScheduler:fillReportByUser')->info($message, Bootstrap::context()); } return false; } @@ -506,7 +506,7 @@ class Task $this->saveLog("fillReportByUser", "error", "Error in fill report by user: " . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:fillReportByUser')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -520,7 +520,7 @@ class Task public function fillReportByProcess($dateInit, $dateFinish) { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:fillReportByProcess')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); if ($dateInit == null) { if ($this->asynchronous === false) { @@ -529,7 +529,7 @@ class Task } if ($this->asynchronous === true) { $message = 'You must enter the starting date. Example: +init-date"YYYY-MM-DD HH:MM:SS" +finish-date"YYYY-MM-DD HH:MM:SS"'; - Log::channel('taskScheduler:taskScheduler')->info($message, Bootstrap::context()); + Log::channel('taskScheduler:fillReportByProcess')->info($message, Bootstrap::context()); } return false; } @@ -551,7 +551,7 @@ class Task $this->saveLog("fillReportByProcess", "error", "Error in fill report by process: " . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:fillReportByProcess')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -563,14 +563,14 @@ class Task public function ldapcron($debug) { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:ldapcron')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($debug, $scheduledTaskIdentifier) { require_once(PATH_HOME . 'engine' . PATH_SEP . 'methods' . PATH_SEP . 'services' . PATH_SEP . 'ldapadvanced.php'); $ldapadvancedClassCron = new ldapadvancedClassCron(); $ldapadvancedClassCron->executeCron($debug); - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:ldapcron')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -581,7 +581,7 @@ class Task function sendNotifications() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:sendNotifications')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($scheduledTaskIdentifier) { try { @@ -627,7 +627,7 @@ class Task $this->saveLog("ExecuteSendNotifications", "error", "Error when sending notifications " . $e->getMessage()); } - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:sendNotifications')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -638,13 +638,13 @@ class Task public function actionsByEmailResponse() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:actionsByEmailResponse')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($scheduledTaskIdentifier) { $responseReader = new ResponseReader(); $responseReader->actionsByEmailEmailResponse(); - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:actionsByEmailResponse')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -655,13 +655,13 @@ class Task public function messageeventcron() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:messageeventcron')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use($scheduledTaskIdentifier) { $messageApplication = new MessageApplication(); $messageApplication->catchMessageEvent(true); - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:messageeventcron')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -675,13 +675,13 @@ class Task public function timerEventCron($datetime, $frontEnd) { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:timerEventCron')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use ($datetime, $frontEnd, $scheduledTaskIdentifier) { $timerEvent = new TimerEvent(); $timerEvent->startContinueCaseByTimerEvent($datetime, $frontEnd); - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:timerEventCron')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } @@ -692,12 +692,12 @@ class Task public function webEntriesCron() { $scheduledTaskIdentifier = uniqid(__FUNCTION__ . "#"); - Log::channel('taskScheduler:taskScheduler')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:webEntriesCron')->info("Start {$scheduledTaskIdentifier}", Bootstrap::context()); $job = function() use ($scheduledTaskIdentifier) { WebEntry::deleteOldWebEntries(); - Log::channel('taskScheduler:taskScheduler')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); + Log::channel('taskScheduler:webEntriesCron')->info("Finish {$scheduledTaskIdentifier}", Bootstrap::context()); }; $this->runTask($job); } From 30742b47461f49ebed3429c1696e68ab3d9fc5bd Mon Sep 17 00:00:00 2001 From: Henry Jordan Date: Thu, 28 Oct 2021 16:15:12 +0000 Subject: [PATCH 7/7] update --- .../js/home/TaskMetrics/VueChartLvThree.vue | 997 +++++++++--------- 1 file changed, 519 insertions(+), 478 deletions(-) diff --git a/resources/assets/js/home/TaskMetrics/VueChartLvThree.vue b/resources/assets/js/home/TaskMetrics/VueChartLvThree.vue index 2ae16d432..7c2d66f14 100644 --- a/resources/assets/js/home/TaskMetrics/VueChartLvThree.vue +++ b/resources/assets/js/home/TaskMetrics/VueChartLvThree.vue @@ -1,105 +1,107 @@ - \ No newline at end of file +