diff --git a/app/Domain/Actions/VacationRequest/ApproveAction.php b/app/Domain/Actions/VacationRequest/ApproveAction.php index 8e3e77d..32748df 100644 --- a/app/Domain/Actions/VacationRequest/ApproveAction.php +++ b/app/Domain/Actions/VacationRequest/ApproveAction.php @@ -29,6 +29,7 @@ class ApproveAction protected function notify(VacationRequest $vacationRequest): void { $users = User::query() + ->where("id", "!=", $vacationRequest->user->id) ->whereIn("role", [Role::TechnicalApprover, Role::AdministrativeApprover, Role::Administrator]) ->get(); diff --git a/app/Domain/Actions/VacationRequest/CancelAction.php b/app/Domain/Actions/VacationRequest/CancelAction.php index cb27004..13a0868 100644 --- a/app/Domain/Actions/VacationRequest/CancelAction.php +++ b/app/Domain/Actions/VacationRequest/CancelAction.php @@ -29,6 +29,7 @@ class CancelAction protected function notify(VacationRequest $vacationRequest): void { $users = User::query() + ->where("id", "!=", $vacationRequest->user->id) ->whereIn("role", [Role::TechnicalApprover, Role::AdministrativeApprover, Role::Administrator]) ->get(); diff --git a/app/Domain/Actions/VacationRequest/RejectAction.php b/app/Domain/Actions/VacationRequest/RejectAction.php index 12acf95..6703830 100644 --- a/app/Domain/Actions/VacationRequest/RejectAction.php +++ b/app/Domain/Actions/VacationRequest/RejectAction.php @@ -26,6 +26,7 @@ class RejectAction protected function notify(VacationRequest $vacationRequest): void { $users = User::query() + ->where("id", "!=", $vacationRequest->user->id) ->whereIn("role", [Role::TechnicalApprover, Role::AdministrativeApprover, Role::Administrator]) ->get(); diff --git a/app/Eloquent/Scopes/SelectedYearPeriodScope.php b/app/Eloquent/Scopes/SelectedYearPeriodScope.php deleted file mode 100644 index e278570..0000000 --- a/app/Eloquent/Scopes/SelectedYearPeriodScope.php +++ /dev/null @@ -1,22 +0,0 @@ -where("year_period_id", $this->yearPeriodRetriever->selected()->id); - } -} diff --git a/app/Infrastructure/Console/Commands/CreateUserCommand.php b/app/Infrastructure/Console/Commands/CreateUserCommand.php deleted file mode 100644 index b0092fd..0000000 --- a/app/Infrastructure/Console/Commands/CreateUserCommand.php +++ /dev/null @@ -1,25 +0,0 @@ -argument("email"); - - User::factory([ - "email" => $email, - ])->create(); - - $this->info("The user has been created"); - } -}