@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | */ |
20 | 20 | public function up(): void |
21 | 21 | { |
22 | - Schema::table('seat_hr_application_statuses', function (Blueprint $table): void { |
|
22 | + Schema::table('seat_hr_application_statuses', function(Blueprint $table): void { |
|
23 | 23 | $table->dropForeign('seat_hr_application_statuses_assigned_by_foreign'); |
24 | 24 | $table->dropForeign('seat_hr_application_statuses_assigned_to_foreign'); |
25 | 25 | |
@@ -42,7 +42,7 @@ discard block |
||
42 | 42 | */ |
43 | 43 | public function down(): void |
44 | 44 | { |
45 | - Schema::table('seat_hr_application_statuses', function (Blueprint $table): void { |
|
45 | + Schema::table('seat_hr_application_statuses', function(Blueprint $table): void { |
|
46 | 46 | $table->dropForeign('seat_hr_application_statuses_assigned_by_foreign'); |
47 | 47 | $table->dropForeign('seat_hr_application_statuses_assigned_to_foreign'); |
48 | 48 |
@@ -13,7 +13,7 @@ discard block |
||
13 | 13 | */ |
14 | 14 | public function up(): void |
15 | 15 | { |
16 | - Schema::table('seat_hr_corporation_questions', function (Blueprint $table): void { |
|
16 | + Schema::table('seat_hr_corporation_questions', function(Blueprint $table): void { |
|
17 | 17 | $table->dropForeign('seat_hr_corporation_questions_question_id_foreign'); |
18 | 18 | $table->foreign('question_id') |
19 | 19 | ->references('id') |
@@ -21,7 +21,7 @@ discard block |
||
21 | 21 | ->onDelete('cascade'); |
22 | 22 | }); |
23 | 23 | |
24 | - Schema::table('seat_hr_answers', function (Blueprint $table): void { |
|
24 | + Schema::table('seat_hr_answers', function(Blueprint $table): void { |
|
25 | 25 | $table->dropForeign('seat_hr_answers_question_id_foreign'); |
26 | 26 | $table->foreign('question_id') |
27 | 27 | ->references('id') |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | */ |
38 | 38 | public function down(): void |
39 | 39 | { |
40 | - Schema::table('seat_hr_corporation_questions', function (Blueprint $table): void { |
|
40 | + Schema::table('seat_hr_corporation_questions', function(Blueprint $table): void { |
|
41 | 41 | $table->dropForeign('seat_hr_corporation_questions_question_id_foreign'); |
42 | 42 | $table->foreign('question_id') |
43 | 43 | ->references('id') |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | ->onDelete('restrict'); |
46 | 46 | }); |
47 | 47 | |
48 | - Schema::table('seat_hr_answers', function (Blueprint $table): void { |
|
48 | + Schema::table('seat_hr_answers', function(Blueprint $table): void { |
|
49 | 49 | $table->dropForeign('seat_hr_answers_question_id_foreign'); |
50 | 50 | $table->foreign('question_id') |
51 | 51 | ->references('id') |
@@ -20,10 +20,10 @@ discard block |
||
20 | 20 | /* |
21 | 21 | * Optional methods to load your package assets |
22 | 22 | */ |
23 | - $this->loadRoutesFrom(__DIR__ . '/routes/web.php'); |
|
24 | - $this->loadViewsFrom(__DIR__ . '/resources/views', 'seat-hr'); |
|
23 | + $this->loadRoutesFrom(__DIR__.'/routes/web.php'); |
|
24 | + $this->loadViewsFrom(__DIR__.'/resources/views', 'seat-hr'); |
|
25 | 25 | $this->loadMigrationsFrom(__DIR__.'/database/migrations'); |
26 | - $this->loadTranslationsFrom(__DIR__ . '/resources/lang', 'seat-hr'); |
|
26 | + $this->loadTranslationsFrom(__DIR__.'/resources/lang', 'seat-hr'); |
|
27 | 27 | $this->loadViewComposers(); |
28 | 28 | |
29 | 29 | } |
@@ -34,12 +34,12 @@ discard block |
||
34 | 34 | public function register(): void |
35 | 35 | { |
36 | 36 | // Automatically apply the package configuration |
37 | - $this->mergeConfigFrom(__DIR__ . '/config/seat-hr.config.php', 'seat-hr'); |
|
38 | - $this->mergeConfigFrom(__DIR__ . '/config/seat-hr.sidebar.php', 'package.sidebar'); |
|
39 | - $this->mergeConfigFrom(__DIR__ . '/config/seat-hr.profile.menu.php', 'seat-hr.profile.menu'); |
|
40 | - $this->mergeConfigFrom(__DIR__ . '/config/seat-hr.review.menu.php', 'seat-hr.review.menu'); |
|
41 | - $this->mergeConfigFrom(__DIR__ . '/config/package.character.menu.php', 'package.character.menu'); |
|
42 | - $this->registerPermissions(__DIR__ . '/config/seat-hr.permissions.php', 'seat-hr'); |
|
37 | + $this->mergeConfigFrom(__DIR__.'/config/seat-hr.config.php', 'seat-hr'); |
|
38 | + $this->mergeConfigFrom(__DIR__.'/config/seat-hr.sidebar.php', 'package.sidebar'); |
|
39 | + $this->mergeConfigFrom(__DIR__.'/config/seat-hr.profile.menu.php', 'seat-hr.profile.menu'); |
|
40 | + $this->mergeConfigFrom(__DIR__.'/config/seat-hr.review.menu.php', 'seat-hr.review.menu'); |
|
41 | + $this->mergeConfigFrom(__DIR__.'/config/package.character.menu.php', 'package.character.menu'); |
|
42 | + $this->registerPermissions(__DIR__.'/config/seat-hr.permissions.php', 'seat-hr'); |
|
43 | 43 | |
44 | 44 | |
45 | 45 | // Register the main class to use with the facade |
@@ -27,7 +27,7 @@ |
||
27 | 27 | return $query |
28 | 28 | ->leftJoin( |
29 | 29 | 'seat_hr_corporation_questions', |
30 | - function ($join) use ($corporation_id) { |
|
30 | + function($join) use ($corporation_id) { |
|
31 | 31 | $join->on('seat_hr_questions.id', '=', 'seat_hr_corporation_questions.question_id') |
32 | 32 | ->where('seat_hr_corporation_questions.corporation_id', $corporation_id); |
33 | 33 | }) |
@@ -20,18 +20,18 @@ discard block |
||
20 | 20 | { |
21 | 21 | return datatables() |
22 | 22 | ->eloquent($query) |
23 | - ->editColumn('active', function ($row) { |
|
23 | + ->editColumn('active', function($row) { |
|
24 | 24 | $bool = $row->active; |
25 | 25 | return view('seat-hr::configuration.corporation_questions.partials.bool', ['bool' => $bool]); |
26 | 26 | }) |
27 | - ->editColumn('corporation_question_active', function ($row) { |
|
27 | + ->editColumn('corporation_question_active', function($row) { |
|
28 | 28 | // $bool = !is_null($row->id); |
29 | 29 | $bool = $row->corporation_question_active ?? false; |
30 | 30 | return view('seat-hr::configuration.corporation_questions.partials.bool', ['bool' => $bool]); |
31 | 31 | }) |
32 | 32 | ->editColumn('type', fn($row): string => ucwords((string) $row->type)) |
33 | 33 | ->addColumn('action', fn($row) => view('seat-hr::configuration.corporation_questions.partials.actions', ['row' => $row])) |
34 | - ->addColumn('debug', function ($row) use ($query) { |
|
34 | + ->addColumn('debug', function($row) use ($query) { |
|
35 | 35 | return $query->toSql(); |
36 | 36 | }); |
37 | 37 | } |
@@ -97,6 +97,6 @@ discard block |
||
97 | 97 | */ |
98 | 98 | protected function filename(): string |
99 | 99 | { |
100 | - return 'CorporationQuestion_' . date('YmdHis'); |
|
100 | + return 'CorporationQuestion_'.date('YmdHis'); |
|
101 | 101 | } |
102 | 102 | } |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | 'question_id' => [ |
35 | 35 | 'required', |
36 | 36 | 'exists:seat_hr_questions,id', |
37 | - Rule::unique('seat_hr_corporation_questions')->where(function ($query) use ($data) { |
|
37 | + Rule::unique('seat_hr_corporation_questions')->where(function($query) use ($data) { |
|
38 | 38 | return $query->where('corporation_id', $data['corporation_id']); |
39 | 39 | }), |
40 | 40 | ], |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | return back()->withErrors('Invalid question ID'); |
58 | 58 | } |
59 | 59 | |
60 | - $question->active = !(bool)$question->active; |
|
60 | + $question->active = !(bool) $question->active; |
|
61 | 61 | $question->save(); |
62 | 62 | |
63 | 63 | return back()->with('success', 'Question updated successfully.'); |