Skip to content

Commit

Permalink
- fix - change method name from data() to getData()
Browse files Browse the repository at this point in the history
  • Loading branch information
EwelinaSkrzypacz committed Dec 17, 2024
1 parent 72b8f7b commit 3810ec9
Show file tree
Hide file tree
Showing 16 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions app/Http/Controllers/EquipmentController.php
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ public function store(
): RedirectResponse {
$this->authorize("manageEquipment");

EquipmentItem::query()->create($request->data());
EquipmentItem::query()->create($request->getData());

return redirect()
->route("equipment-items.index")
Expand Down Expand Up @@ -157,7 +157,7 @@ public function update(
): RedirectResponse {
$this->authorize("manageUsers");

$equipmentItem->update($request->data());
$equipmentItem->update($request->getData());

return redirect()
->route("equipment-items.index")
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/EquipmentLabelController.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function store(EquipmentLabelRequest $request): RedirectResponse
{
$this->authorize("manageEquipment");

$label = EquipmentLabel::query()->create($request->data());
$label = EquipmentLabel::query()->create($request->getData());

return redirect()
->back()
Expand Down
4 changes: 2 additions & 2 deletions app/Http/Controllers/HolidayController.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public function store(HolidayRequest $request): RedirectResponse
{
$this->authorize("manageHolidays");

Holiday::query()->create($request->data());
Holiday::query()->create($request->getData());

return redirect()
->route("holidays.index")
Expand All @@ -74,7 +74,7 @@ public function update(HolidayRequest $request, Holiday $holiday): RedirectRespo
{
$this->authorize("manageHolidays");

$holiday->update($request->data());
$holiday->update($request->getData());

return redirect()
->route("holidays.index")
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/OvertimeRequestController.php
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ public function store(OvertimeRequestRequest $request, CreateAction $createActio
{
$this->authorize("canUseOvertimeRequestFunctionality", $request->user());

$overtimeRequest = $createAction->execute($request->data(), $request->user());
$overtimeRequest = $createAction->execute($request->getData(), $request->user());

return redirect()
->route("overtime.requests.show", $overtimeRequest)
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/TechnologyController.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function store(TechnologyRequest $request): RedirectResponse
{
$this->authorize("manageResumes");

$technology = Technology::query()->create($request->data());
$technology = Technology::query()->create($request->getData());

return redirect()
->back()
Expand Down
4 changes: 2 additions & 2 deletions app/Http/Controllers/UserHistoryController.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function store(UserHistoryRequest $request, User $user): RedirectResponse
{
$this->authorize("manageUsers");

$user->histories()->create($request->data());
$user->histories()->create($request->getData());

return redirect()
->route("users.history", $user)
Expand All @@ -67,7 +67,7 @@ public function update(UserHistoryRequest $request, UserHistory $history): Redir
{
$this->authorize("manageUsers");

$history->update($request->data());
$history->update($request->getData());

return redirect()
->route("users.history", $history->user_id)
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/VacationLimitController.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public function update(VacationLimitRequest $request): RedirectResponse
{
$this->authorize("manageVacationLimits");

foreach ($request->data() as $limit) {
foreach ($request->getData() as $limit) {
VacationLimit::query()->updateOrCreate(
[
"user_id" => $limit["user"],
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/VacationRequestController.php
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ public function store(VacationRequestRequest $request, CreateAction $createActio
$this->authorize("skipRequestFlow");
}

$vacationRequest = $createAction->execute($request->data(), $request->user());
$vacationRequest = $createAction->execute($request->getData(), $request->user());

return redirect()
->route("vacation.requests.show", $vacationRequest)
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Requests/EquipmentLabelRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public function rules(): array
];
}

public function data(): array
public function getData(): array
{
return [
"name" => $this->get("name"),
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Requests/EquipmentRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function rules(): array
];
}

public function data(): array
public function getData(): array
{
return [
"id_number" => $this->get("idNumber"),
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Requests/HolidayRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public function rules(): array
];
}

public function data(): array
public function getData(): array
{
$date = $this->get("date");

Expand Down
2 changes: 1 addition & 1 deletion app/Http/Requests/OvertimeRequestRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function rules(): array
];
}

public function data(): array
public function getData(): array
{
return [
"user_id" => $this->get("user"),
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Requests/TechnologyRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public function rules(): array
];
}

public function data(): array
public function getData(): array
{
return [
"name" => $this->get("name"),
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Requests/UserHistoryRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function rules(): array
];
}

public function data(): array
public function getData(): array
{
return [
"from" => $this->get("from"),
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Requests/VacationLimitRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public function rules(): array
];
}

public function data(): Collection
public function getData(): Collection
{
return $this->collect("items");
}
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Requests/VacationRequestRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public function rules(): array
];
}

public function data(): array
public function getData(): array
{
return [
"user_id" => $this->get("user"),
Expand Down

0 comments on commit 3810ec9

Please sign in to comment.