From 8abfd2d48ddedcdbc2bc0f93ec603e8feaa76868 Mon Sep 17 00:00:00 2001 From: Ludovic <54670129+lbr38@users.noreply.github.com> Date: Sun, 29 Dec 2024 14:40:04 +0100 Subject: [PATCH] patch --- .../Layout/Container/vars/tasks/log.vars.inc.php | 2 +- www/controllers/Repo/Mirror/Mirror.php | 4 ++-- .../{Logging/Logging.php => Task/Log/Log.php} | 10 +++++----- www/controllers/{Logging => Task/Log}/Step.php | 6 +++--- www/controllers/{Logging => Task/Log}/SubStep.php | 6 +++--- www/controllers/Task/Repo/Create.php | 4 ++-- www/controllers/Task/Repo/Delete.php | 4 ++-- www/controllers/Task/Repo/Duplicate.php | 4 ++-- www/controllers/Task/Repo/Env.php | 2 +- www/controllers/Task/Repo/Metadata/Metadata.php | 4 ++-- www/controllers/Task/Repo/Rebuild.php | 4 ++-- www/controllers/Task/Repo/RemoveEnv.php | 4 ++-- www/controllers/Task/Repo/Update.php | 4 ++-- www/controllers/Task/Step.php | 2 +- www/controllers/Task/Task.php | 4 ++-- www/models/{Logging/Logging.php => Task/Log/Log.php} | 4 ++-- www/models/{Logging => Task/Log}/Step.php | 2 +- www/models/{Logging => Task/Log}/SubStep.php | 2 +- 18 files changed, 36 insertions(+), 36 deletions(-) rename www/controllers/{Logging/Logging.php => Task/Log/Log.php} (89%) rename www/controllers/{Logging => Task/Log}/Step.php (94%) rename www/controllers/{Logging => Task/Log}/SubStep.php (97%) rename www/models/{Logging/Logging.php => Task/Log/Log.php} (92%) rename www/models/{Logging => Task/Log}/Step.php (99%) rename www/models/{Logging => Task/Log}/SubStep.php (99%) diff --git a/www/controllers/Layout/Container/vars/tasks/log.vars.inc.php b/www/controllers/Layout/Container/vars/tasks/log.vars.inc.php index 70e92ed8..ac1fc0d1 100644 --- a/www/controllers/Layout/Container/vars/tasks/log.vars.inc.php +++ b/www/controllers/Layout/Container/vars/tasks/log.vars.inc.php @@ -26,7 +26,7 @@ // If the task has a json log in database (new format) } else { - $loggingController = new \Controllers\Logging\Logging($taskId); + $loggingController = new \Controllers\Task\Log\Log($taskId); // Get raw params from the task $rawParams = json_decode($taskInfo['Raw_params'], true); diff --git a/www/controllers/Repo/Mirror/Mirror.php b/www/controllers/Repo/Mirror/Mirror.php index 77ab4ff5..ce23f198 100644 --- a/www/controllers/Repo/Mirror/Mirror.php +++ b/www/controllers/Repo/Mirror/Mirror.php @@ -40,8 +40,8 @@ class Mirror public function __construct(int $taskId) { $this->taskId = $taskId; - $this->loggingStepController = new \Controllers\Logging\Step($taskId); - $this->loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); + $this->loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); } public function setTaskId(string $taskId) diff --git a/www/controllers/Logging/Logging.php b/www/controllers/Task/Log/Log.php similarity index 89% rename from www/controllers/Logging/Logging.php rename to www/controllers/Task/Log/Log.php index 0611214c..ccab9287 100644 --- a/www/controllers/Logging/Logging.php +++ b/www/controllers/Task/Log/Log.php @@ -1,11 +1,11 @@ taskId = $taskId; - $this->model = new \Models\Logging\Logging($taskId); + $this->model = new \Models\Task\Log\Log($taskId); } /** @@ -22,8 +22,8 @@ public function __construct(int $taskId) public function getContent() : array { $content = []; - $stepController = new \Controllers\Logging\Step($this->taskId); - $subStepController = new \Controllers\Logging\SubStep($this->taskId); + $stepController = new \Controllers\Task\Log\Step($this->taskId); + $subStepController = new \Controllers\Task\Log\SubStep($this->taskId); try { /** diff --git a/www/controllers/Logging/Step.php b/www/controllers/Task/Log/Step.php similarity index 94% rename from www/controllers/Logging/Step.php rename to www/controllers/Task/Log/Step.php index f3f7bb5e..9437e745 100644 --- a/www/controllers/Logging/Step.php +++ b/www/controllers/Task/Log/Step.php @@ -1,18 +1,18 @@ model = new \Models\Logging\Step($taskId); + $this->model = new \Models\Task\Log\Step($taskId); } /** diff --git a/www/controllers/Logging/SubStep.php b/www/controllers/Task/Log/SubStep.php similarity index 97% rename from www/controllers/Logging/SubStep.php rename to www/controllers/Task/Log/SubStep.php index c16781f6..6f65f8d5 100644 --- a/www/controllers/Logging/SubStep.php +++ b/www/controllers/Task/Log/SubStep.php @@ -1,11 +1,11 @@ model = new \Models\Logging\SubStep($taskId); + $this->model = new \Models\Task\Log\SubStep($taskId); $this->stepController = new Step($taskId); } diff --git a/www/controllers/Task/Repo/Create.php b/www/controllers/Task/Repo/Create.php index f12c13b0..6a228224 100644 --- a/www/controllers/Task/Repo/Create.php +++ b/www/controllers/Task/Repo/Create.php @@ -23,8 +23,8 @@ public function __construct(string $taskId) { $this->repo = new \Controllers\Repo\Repo(); $this->task = new \Controllers\Task\Task(); - $this->loggingStepController = new \Controllers\Logging\Step($taskId); - $this->loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); + $this->loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); /** * Retrieve task params diff --git a/www/controllers/Task/Repo/Delete.php b/www/controllers/Task/Repo/Delete.php index a0fb7b21..109f5575 100644 --- a/www/controllers/Task/Repo/Delete.php +++ b/www/controllers/Task/Repo/Delete.php @@ -17,8 +17,8 @@ public function __construct(string $taskId) { $this->repo = new \Controllers\Repo\Repo(); $this->task = new \Controllers\Task\Task(); - $this->loggingStepController = new \Controllers\Logging\Step($taskId); - $this->loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); + $this->loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); /** * Retrieve task params diff --git a/www/controllers/Task/Repo/Duplicate.php b/www/controllers/Task/Repo/Duplicate.php index 64607dff..99ed431d 100644 --- a/www/controllers/Task/Repo/Duplicate.php +++ b/www/controllers/Task/Repo/Duplicate.php @@ -20,8 +20,8 @@ public function __construct(string $taskId) $this->sourceRepo = new \Controllers\Repo\Repo(); $this->repo = new \Controllers\Repo\Repo(); $this->task = new \Controllers\Task\Task(); - $this->loggingStepController = new \Controllers\Logging\Step($taskId); - $this->loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); + $this->loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); /** * Retrieve task params diff --git a/www/controllers/Task/Repo/Env.php b/www/controllers/Task/Repo/Env.php index b36931d3..09884c36 100644 --- a/www/controllers/Task/Repo/Env.php +++ b/www/controllers/Task/Repo/Env.php @@ -16,7 +16,7 @@ public function __construct(string $taskId) { $this->repo = new \Controllers\Repo\Repo(); $this->task = new \Controllers\Task\Task(); - $this->loggingStepController = new \Controllers\Logging\Step($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); /** * Retrieve task params diff --git a/www/controllers/Task/Repo/Metadata/Metadata.php b/www/controllers/Task/Repo/Metadata/Metadata.php index 1a4e23bc..565eb276 100644 --- a/www/controllers/Task/Repo/Metadata/Metadata.php +++ b/www/controllers/Task/Repo/Metadata/Metadata.php @@ -13,8 +13,8 @@ class Metadata public function __construct(int $taskId) { $this->taskController = new \Controllers\Task\Task(); - $this->loggingStepController = new \Controllers\Logging\Step($taskId); - $this->loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); + $this->loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); // Set task Id $this->taskController->setId($taskId); diff --git a/www/controllers/Task/Repo/Rebuild.php b/www/controllers/Task/Repo/Rebuild.php index 120a07e9..178d431d 100644 --- a/www/controllers/Task/Repo/Rebuild.php +++ b/www/controllers/Task/Repo/Rebuild.php @@ -20,8 +20,8 @@ public function __construct(string $taskId) { $this->repo = new \Controllers\Repo\Repo(); $this->task = new \Controllers\Task\Task(); - $this->loggingStepController = new \Controllers\Logging\Step($taskId); - $this->loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); + $this->loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); /** * Retrieve task params diff --git a/www/controllers/Task/Repo/RemoveEnv.php b/www/controllers/Task/Repo/RemoveEnv.php index b6b2bf9e..3c1aa19c 100644 --- a/www/controllers/Task/Repo/RemoveEnv.php +++ b/www/controllers/Task/Repo/RemoveEnv.php @@ -17,8 +17,8 @@ public function __construct(string $taskId) { $this->repo = new \Controllers\Repo\Repo(); $this->task = new \Controllers\Task\Task(); - $this->loggingStepController = new \Controllers\Logging\Step($taskId); - $this->loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); + $this->loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); /** * Retrieve task params diff --git a/www/controllers/Task/Repo/Update.php b/www/controllers/Task/Repo/Update.php index dc4e9939..c0864abe 100644 --- a/www/controllers/Task/Repo/Update.php +++ b/www/controllers/Task/Repo/Update.php @@ -23,8 +23,8 @@ public function __construct(string $taskId) $this->sourceRepo = new \Controllers\Repo\Repo(); $this->repo = new \Controllers\Repo\Repo(); $this->task = new \Controllers\Task\Task(); - $this->loggingStepController = new \Controllers\Logging\Step($taskId); - $this->loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $this->loggingStepController = new \Controllers\Task\Log\Step($taskId); + $this->loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); /** * Retrieve task params diff --git a/www/controllers/Task/Step.php b/www/controllers/Task/Step.php index 3089d92a..3bfb6acc 100644 --- a/www/controllers/Task/Step.php +++ b/www/controllers/Task/Step.php @@ -12,7 +12,7 @@ class Step public function __construct(int $taskId) { - $this->loggingController = new \Controllers\Logging\Logging($taskId); + $this->loggingController = new \Controllers\Task\Log\Log($taskId); $this->taskId = $taskId; /** diff --git a/www/controllers/Task/Task.php b/www/controllers/Task/Task.php index 16db165d..2305ed30 100644 --- a/www/controllers/Task/Task.php +++ b/www/controllers/Task/Task.php @@ -717,8 +717,8 @@ public function kill(string $pid) */ $this->updateStatus($taskId, 'stopped'); - $loggingStepController = new \Controllers\Logging\Step($taskId); - $loggingSubStepController = new \Controllers\Logging\SubStep($taskId); + $loggingStepController = new \Controllers\Task\Log\Step($taskId); + $loggingSubStepController = new \Controllers\Task\Log\SubStep($taskId); /** * Set latest step and substep as stopped diff --git a/www/models/Logging/Logging.php b/www/models/Task/Log/Log.php similarity index 92% rename from www/models/Logging/Logging.php rename to www/models/Task/Log/Log.php index 88f981f9..0443d5e5 100644 --- a/www/models/Logging/Logging.php +++ b/www/models/Task/Log/Log.php @@ -1,10 +1,10 @@