From e75ca50e428875dd37fbb656012beeb185281ddd Mon Sep 17 00:00:00 2001 From: Nuwan Jaliyagoda Date: Wed, 18 Dec 2024 07:50:55 +0530 Subject: [PATCH] Taxonomy Integration - Release 3.0.0 (#171) (#239) Co-authored-by: Supun Dulara Co-authored-by: Hasan10100 <150885485+Hasan10100@users.noreply.github.com> Co-authored-by: kusaljayawardhana Co-authored-by: IsharaEkanayaka --- .../Models/Traits/Scope/CourseScope.php | 2 +- app/Domains/Taxonomy/Models/Taxonomy.php | 94 + app/Domains/Taxonomy/Models/TaxonomyTerm.php | 151 ++ .../Taxonomy/Services/TaxonomyService.php | 22 + .../Controllers/API/TaxonomyApiController.php | 82 + .../Backend/TaxonomyController.php | 147 ++ .../Backend/TaxonomyTermController.php | 234 +++ .../Controllers/Frontend/HomeController.php | 3 +- app/Http/Livewire/Backend/TaxonomyTable.php | 48 + .../Livewire/Backend/TaxonomyTermTable.php | 77 + app/Http/Resources/TaxonomyListResource.php | 28 + app/Http/Resources/TaxonomyResource.php | 35 + app/Http/Resources/TaxonomyTermResource.php | 38 + composer.lock | 1694 ++++------------- database/factories/TaxonomyFactory.php | 54 + database/factories/TaxonomyTermFactory.php | 47 + ...4_10_11_120037_create_taxonomies_table.php | 37 + ..._12_085403_create_taxonomy_terms_table.php | 38 + database/seeders/DatabaseSeeder.php | 2 + database/seeders/TaxonomySeeder.php | 49 + database/seeders/TaxonomyTermSeeder.php | 201 ++ resources/sass/backend/app.scss | 4 + .../views/backend/includes/sidebar.blade.php | 16 + .../views/backend/taxonomy/create.blade.php | 87 + .../views/backend/taxonomy/delete.blade.php | 47 + .../views/backend/taxonomy/edit.blade.php | 114 ++ .../taxonomy/index-table-row.blade.php | 53 + .../views/backend/taxonomy/index.blade.php | 31 + .../backend/taxonomy/terms/create.blade.php | 150 ++ .../backend/taxonomy/terms/delete.blade.php | 45 + .../backend/taxonomy/terms/edit.blade.php | 180 ++ .../taxonomy/terms/index-table-row.blade.php | 61 + .../backend/taxonomy/terms/index.blade.php | 31 + .../views/backend/taxonomy/view.blade.php | 23 + .../backend/taxonomy_property_adder.blade.php | 187 ++ .../frontend/pages/contributors.blade.php | 2 +- .../backend/event-item-table.blade.php | 3 - routes/api.php | 13 +- routes/backend/taxonomy.php | 127 ++ scripts/deploy-prod.sh | 4 +- 40 files changed, 2938 insertions(+), 1323 deletions(-) create mode 100644 app/Domains/Taxonomy/Models/Taxonomy.php create mode 100644 app/Domains/Taxonomy/Models/TaxonomyTerm.php create mode 100644 app/Domains/Taxonomy/Services/TaxonomyService.php create mode 100644 app/Http/Controllers/API/TaxonomyApiController.php create mode 100644 app/Http/Controllers/Backend/TaxonomyController.php create mode 100644 app/Http/Controllers/Backend/TaxonomyTermController.php create mode 100644 app/Http/Livewire/Backend/TaxonomyTable.php create mode 100644 app/Http/Livewire/Backend/TaxonomyTermTable.php create mode 100644 app/Http/Resources/TaxonomyListResource.php create mode 100644 app/Http/Resources/TaxonomyResource.php create mode 100644 app/Http/Resources/TaxonomyTermResource.php create mode 100644 database/factories/TaxonomyFactory.php create mode 100644 database/factories/TaxonomyTermFactory.php create mode 100644 database/migrations/2024_10_11_120037_create_taxonomies_table.php create mode 100644 database/migrations/2024_10_12_085403_create_taxonomy_terms_table.php create mode 100644 database/seeders/TaxonomySeeder.php create mode 100644 database/seeders/TaxonomyTermSeeder.php create mode 100644 resources/views/backend/taxonomy/create.blade.php create mode 100644 resources/views/backend/taxonomy/delete.blade.php create mode 100644 resources/views/backend/taxonomy/edit.blade.php create mode 100644 resources/views/backend/taxonomy/index-table-row.blade.php create mode 100644 resources/views/backend/taxonomy/index.blade.php create mode 100644 resources/views/backend/taxonomy/terms/create.blade.php create mode 100644 resources/views/backend/taxonomy/terms/delete.blade.php create mode 100644 resources/views/backend/taxonomy/terms/edit.blade.php create mode 100644 resources/views/backend/taxonomy/terms/index-table-row.blade.php create mode 100644 resources/views/backend/taxonomy/terms/index.blade.php create mode 100644 resources/views/backend/taxonomy/view.blade.php create mode 100644 resources/views/components/backend/taxonomy_property_adder.blade.php delete mode 100644 resources/views/livewire/backend/event-item-table.blade.php create mode 100644 routes/backend/taxonomy.php diff --git a/app/Domains/AcademicProgram/Course/Models/Traits/Scope/CourseScope.php b/app/Domains/AcademicProgram/Course/Models/Traits/Scope/CourseScope.php index cc11480e..6370a5f4 100644 --- a/app/Domains/AcademicProgram/Course/Models/Traits/Scope/CourseScope.php +++ b/app/Domains/AcademicProgram/Course/Models/Traits/Scope/CourseScope.php @@ -54,4 +54,4 @@ public function scopeOfVersion($query, $version) { return $query->where('version', $version); } -} \ No newline at end of file +} diff --git a/app/Domains/Taxonomy/Models/Taxonomy.php b/app/Domains/Taxonomy/Models/Taxonomy.php new file mode 100644 index 00000000..08d8aca8 --- /dev/null +++ b/app/Domains/Taxonomy/Models/Taxonomy.php @@ -0,0 +1,94 @@ + 'String', + 'integer' => 'Integer Number', + 'float' => 'Floating Point Number', + 'date' => 'Date', + 'datetime' => 'Date Time', + 'boolean' => 'Boolean', + 'url' => 'URL', + // 'image' => 'Image' + // 'pdf' => 'PDF File' + ]; + + protected $casts = [ + 'properties' => 'json', + 'created_at' => 'datetime', + 'updated_at' => 'datetime', + ]; + + public function user() + { + return $this->belongsTo(User::class, 'created_by'); + } + + public function user_created() + { + return $this->belongsTo(User::class, 'created_by'); + } + + public function user_updated() + { + return $this->belongsTo(User::class, 'created_by'); + } + + public function terms() + { + return $this->hasMany(TaxonomyTerm::class, 'taxonomy_id') + ->orderBy('parent_id', 'asc') + ->orderBy('code', 'asc'); + } + + public function first_child_terms() + { + return $this->hasMany(TaxonomyTerm::class, 'taxonomy_id') + ->whereNull('parent_id') + ->orderBy('code', 'asc'); + } + + public function to_dict() + { + $taxonomy = $this->toArray(); + foreach (['properties', 'created_at', 'updated_at', 'created_by', 'updated_by'] as $attribute) { + unset($taxonomy[$attribute]); + } + $taxonomy['properties'] = $this->properties; + $taxonomy['terms'] = TaxonomyTerm::getByTaxonomy($this->id); + return $taxonomy; + } + + protected static function newFactory() + { + return TaxonomyFactory::new(); + } +} diff --git a/app/Domains/Taxonomy/Models/TaxonomyTerm.php b/app/Domains/Taxonomy/Models/TaxonomyTerm.php new file mode 100644 index 00000000..a53a1021 --- /dev/null +++ b/app/Domains/Taxonomy/Models/TaxonomyTerm.php @@ -0,0 +1,151 @@ + 'json', + 'created_at' => 'datetime', + 'updated_at' => 'datetime', + ]; + + public function getFormattedMetadataAttribute() + { + $response = array(); + if (is_array($this->metadata)) { + $filteredMetadata = array_filter($this->metadata, function ($value) { + return !is_null($value['value']); + }); + + foreach ($filteredMetadata as $metadata) { + $response[$metadata['code']] = $metadata['value']; + } + } + return $response; + } + + public function user() + { + return $this->belongsTo(User::class, 'created_by'); + } + + public function user_created() + { + return $this->belongsTo(User::class, 'created_by'); + } + + public function user_updated() + { + return $this->belongsTo(User::class, 'created_by'); + } + + public function taxonomy() + { + return $this->belongsTo(Taxonomy::class, 'taxonomy_id'); + } + + public function parent() + { + return $this->belongsTo(self::class, 'parent_id'); + } + + public function children() + { + return $this->hasMany(self::class, 'parent_id') + ->orderBy('code', 'asc');; + } + + public function getMetadata($code) + { + if (is_array($this->metadata)) { + foreach ($this->metadata as $item) { + if ($item['code'] === $code && $item['value'] != null) { + return $item['value']; + } + } + } + return null; + } + + protected static function boot() + { + parent::boot(); + + static::deleting(function ($taxonomyTerm) { + $taxonomyTerm->children()->delete(); + }); + } + + public static function getHierarchicalPath($id) + { + $term = TaxonomyTerm::find($id); + if ($term != null) { + if ($term->parent_id != null) { + return TaxonomyTerm::getHierarchicalPath($term->parent_id) . " > " . $term->name; + } else { + return $term->name; + } + } else { + return ''; + } + } + + public static function getByTaxonomy($taxonomyId, $parent = null) + { + if ($parent == null) { + $res = TaxonomyTerm::where('taxonomy_id', $taxonomyId)->whereNull('parent_id'); + } else { + $res = TaxonomyTerm::where('taxonomy_id', $taxonomyId)->where('parent_id', $parent); + } + + $taxonomyTerms = []; + foreach ($res->get() as $term) { + $termData = $term->to_dict(); + + if ($term->children()->count() > 0) { + $termData['terms'] = $term->getByTaxonomy($taxonomyId, $term->id); + } + array_push($taxonomyTerms, $termData); + } + return $taxonomyTerms; + } + + public function to_dict() + { + $taxonomyTerm = $this->toArray(); + foreach (['id', 'taxonomy_id', 'parent_id', 'metadata', 'created_at', 'updated_at', 'created_by', 'updated_by'] as $attribute) { + unset($taxonomyTerm[$attribute]); + } + $taxonomyTerm['metadata'] = $this->formatted_metadata; + return $taxonomyTerm; + } + + protected static function newFactory() + { + return TaxonomyTermFactory::new(); + } +} \ No newline at end of file diff --git a/app/Domains/Taxonomy/Services/TaxonomyService.php b/app/Domains/Taxonomy/Services/TaxonomyService.php new file mode 100644 index 00000000..a144a70d --- /dev/null +++ b/app/Domains/Taxonomy/Services/TaxonomyService.php @@ -0,0 +1,22 @@ +model = $taxonomy; + } +} diff --git a/app/Http/Controllers/API/TaxonomyApiController.php b/app/Http/Controllers/API/TaxonomyApiController.php new file mode 100644 index 00000000..440ed76e --- /dev/null +++ b/app/Http/Controllers/API/TaxonomyApiController.php @@ -0,0 +1,82 @@ +json( + [ + 'status' => 'success', + 'data' => TaxonomyListResource::collection($result) + ] + ); + } else { + return response()->json(['status' => 'error', 'message' => 'No Taxonomies found'], 404); + } + } catch (\Exception $e) { + Log::error('Error in TaxonomyApiController@index', ['error' => $e->getMessage()]); + return response()->json(['status' => 'error', 'message' => 'An error occurred while fetching taxonomy index'], 500); + } + } + + public function get_taxonomy($taxonomy_code) + { + try { + $result = Taxonomy::where('code', $taxonomy_code)->first(); + + if ($result) { + return response()->json( + [ + 'status' => 'success', + 'data' => TaxonomyResource::collection([$result])->resolve()[0] + ] + ); + } else { + return response()->json(['status' => 'error', 'message' => 'Taxonomy not found'], 404); + } + } catch (\Exception $e) { + Log::error('Error in TaxonomyApiController@get_taxonomy', ['error' => $e->getMessage()]); + return response()->json(['status' => 'error', 'message' => 'An error occurred while fetching a taxonomy'], 500); + } + } + + + public function get_term($term_code) + { + try { + $result = TaxonomyTerm::where('code', $term_code)->first(); + + if ($result) { + $data = TaxonomyTermResource::collection([$result])->resolve()[0]; + $data['taxonomy'] = $result->taxonomy->code; // Add the taxonomy code at the top-level term + + return response()->json( + [ + 'status' => 'success', + 'data' => $data + ] + ); + } else { + return response()->json(['status' => 'error', 'message' => 'Taxonomy term not found'], 404); + } + } catch (\Exception $e) { + Log::error('Error in TaxonomyApiController@get_term', ['error' => $e->getMessage()]); + return response()->json(['status' => 'error', 'message' => 'An error occurred while fetching a taxonomy term'], 500); + } + } +} \ No newline at end of file diff --git a/app/Http/Controllers/Backend/TaxonomyController.php b/app/Http/Controllers/Backend/TaxonomyController.php new file mode 100644 index 00000000..9fea2114 --- /dev/null +++ b/app/Http/Controllers/Backend/TaxonomyController.php @@ -0,0 +1,147 @@ + $ex->getMessage()]); + return abort(500); + } + } + + /** + * Preview the resource . + * + * @param \App\Domains\Taxonomy\Models\Taxonomy $taxonomy + * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View + */ + public function view(Taxonomy $taxonomy) + { + $taxonomyData = $taxonomy->to_dict(); + return view('backend.taxonomy.view', compact('taxonomyData')); + } + + /** + * Store a newly created resource in storage. + * + * @param \Illuminate\Http\Request $request + * @return \Illuminate\Http\RedirectResponse|void + */ + public function store(Request $request) + { + $validatedData = $request->validate([ + 'code' => 'required|unique:taxonomies', + 'name' => 'required', + 'description' => 'nullable', + ]); + + try { + $taxonomy = new Taxonomy($validatedData); + $taxonomy->properties = json_decode($request->properties); + $taxonomy->created_by = Auth::user()->id; + $taxonomy->save(); + return redirect()->route('dashboard.taxonomy.index')->with('Success', 'Taxonomy created successfully'); + } catch (\Exception $ex) { + Log::error('Failed to create taxonomy', ['error' => $ex->getMessage()]); + return abort(500); + } + } + /** + * Show the form for editing the specified resource. + * + * @param \App\Domains\Taxonomy\Models\Taxonomy $taxonomy + * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View + */ + public function edit(Taxonomy $taxonomy) + { + try { + return view('backend.taxonomy.edit', [ + 'taxonomy' => $taxonomy, + ]); + } catch (\Exception $ex) { + Log::error('Failed to load taxonomy edit page', ['error' => $ex->getMessage()]); + return abort(500); + } + } + + + /** + * Update the specified resource in storage. + * + * @param \Illuminate\Http\Request $request + * @param \App\Domains\Taxonomy\Models\Taxonomy $taxonomy + * @return \Illuminate\Http\RedirectResponse + */ + public function update(Request $request, Taxonomy $taxonomy) + { + $data = $request->validate([ + 'code' => 'string|required', + 'name' => 'string|required', + 'description' => 'nullable', + 'properties' => 'string' + ]); + + try { + $taxonomy->update($data); + $taxonomy->properties = json_decode($request->properties); + $taxonomy->updated_by = Auth::user()->id; + $taxonomy->save(); + return redirect()->route('dashboard.taxonomy.index')->with('Success', 'Taxonomy updated successfully'); + } catch (\Exception $ex) { + Log::error('Failed to update taxonomy', ['error' => $ex->getMessage()]); + return abort(500); + } + } + /** + * Confirm to delete the specified resource from storage. + * + * @param \App\Domains\Taxonomy\Models\Taxonomy $taxonomy + * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View + */ + public function delete(Taxonomy $taxonomy) + { + $terms = TaxonomyTerm::where('taxonomy_id', $taxonomy->id)->get(); + return view('backend.taxonomy.delete', compact('taxonomy', 'terms')); + } + + + /** + * Remove the specified resource from storage. + * + * @param \App\Domains\Taxonomy\Models\Taxonomy $taxonomy + * @return \Illuminate\Http\RedirectResponse|null + */ + public function destroy(Taxonomy $taxonomy) + { + try { + $terms = TaxonomyTerm::where('taxonomy_id', $taxonomy->id)->get(); + if ($terms->count() > 0) { + return redirect()->route('dashboard.taxonomy.index') + ->withErrors('Can not delete the Taxonomy as it already has associated Taxonomy Terms. Please reassign or delete those first.'); + } + + $taxonomy->delete(); + return redirect()->route('dashboard.taxonomy.index')->with('Success', 'Taxonomy was deleted !'); + } catch (\Exception $ex) { + Log::error('Failed to delete taxonomy', ['taxonomy_id' => $taxonomy->id, 'error' => $ex->getMessage()]); + return abort(500); + } + } +} \ No newline at end of file diff --git a/app/Http/Controllers/Backend/TaxonomyTermController.php b/app/Http/Controllers/Backend/TaxonomyTermController.php new file mode 100644 index 00000000..fe237757 --- /dev/null +++ b/app/Http/Controllers/Backend/TaxonomyTermController.php @@ -0,0 +1,234 @@ + $ex->getMessage()]); + return abort(500); + } + } + /** + * Store a newly created resource in storage. + * + * @param \Illuminate\Http\Request $request + * @return \Illuminate\Http\RedirectResponse|void + */ + public function store(Request $request, Taxonomy $taxonomy, TaxonomyTerm $taxonomyTerm) + { + try { + $validatedData = $request->validate([ + 'code' => 'required|unique:taxonomy_terms,code', + 'name' => 'required', + 'taxonomy_id' => 'required|exists:taxonomies,id', + 'parent_id' => 'nullable|exists:taxonomy_terms,id', + 'metadata' => 'array', + ]); + + + foreach ($taxonomy->properties as $property) { + $metadataKey = "metadata.{$property['code']}"; + + switch ($property['data_type']) { + case 'string': + $request->validate([$metadataKey => 'nullable|string']); + break; + case 'integer': + $request->validate([$metadataKey => 'nullable|integer']); + break; + case 'float': + $request->validate([$metadataKey => 'nullable|numeric']); + break; + case 'boolean': + $request->validate([$metadataKey => 'nullable|boolean']); + break; + case 'date': + $request->validate([$metadataKey => 'nullable|date']); + break; + case 'datetime': + $request->validate([$metadataKey => 'nullable|date']); + break; + case 'url': + $request->validate([$metadataKey => 'nullable|url']); + break; + case 'image': + + if ($request->hasFile("metadata.{$property['code']}")) { + $imagePath = $this->uploadThumb(null, $request->file("metadata.{$property['code']}"), "taxonomy_terms"); + $value = $imagePath; + } else { + $value = null; + } + break; + } + } + + $metadataArray = []; + + foreach ($taxonomy->properties as $property) { + $value = $request->input("metadata.{$property['code']}"); + + if ($property['data_type'] === 'boolean') { + $value = $request->has("metadata.{$property['code']}") ? true : false; + } + $metadataArray[] = [ + 'code' => $property['code'], + 'value' => $value === '' ? null : $value + ]; + } + + $taxonomyTerm = new TaxonomyTerm($validatedData); + $taxonomyTerm->metadata = $metadataArray; + $taxonomyTerm->created_by = Auth::user()->id; + $taxonomyTerm->save(); + + return redirect()->route('dashboard.taxonomy.terms.index', $taxonomy) + ->with('Success', 'Taxonomy term was created successfully!'); + } catch (\Exception $ex) { + Log::error('Failed to create taxonomy term', ['error' => $ex->getMessage()]); + return back()->withInput()->withErrors(['error' => 'Failed to create taxonomy term. Please try again.']); + } + } + /** + * Show the form for editing the specified resource. + * + * @param \App\Domains\TaxonomyTerm\Models\TaxonomyTerm $taxonomyTerm + * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View + */ + public function edit(Taxonomy $taxonomy, TaxonomyTerm $term) + { + try { + return view('backend.taxonomy.terms.edit', compact('taxonomy', 'term')); + } catch (\Exception $ex) { + Log::error('Failed to load taxonomy term edit page', ['error' => $ex->getMessage()]); + return abort(500); + } + } + /** + * Update the specified resource in storage. + * + * @param \Illuminate\Http\Request $request + * @param \App\Domains\TaxonomyTerm\Models\TaxonomyTerm $taxonomyTerm + * @return \Illuminate\Http\RedirectResponse + */ + public function update(Request $request, Taxonomy $taxonomy, TaxonomyTerm $term) + { + try { + $validatedData = $request->validate([ + 'code' => 'required|unique:taxonomy_terms,code,' . $term->id, + 'name' => 'required', + 'parent_id' => 'nullable|exists:taxonomy_terms,id', + 'metadata' => 'array', + ]); + + foreach ($taxonomy->properties as $property) { + $metadataKey = "metadata.{$property['code']}"; + + switch ($property['data_type']) { + case 'string': + $request->validate([$metadataKey => 'nullable|string']); + break; + case 'integer': + $request->validate([$metadataKey => 'nullable|integer']); + break; + case 'float': + $request->validate([$metadataKey => 'nullable|numeric']); + break; + case 'boolean': + $request->validate([$metadataKey => 'nullable|boolean']); + break; + case 'date': + $request->validate([$metadataKey => 'nullable|date']); + break; + case 'datetime': + $request->validate([$metadataKey => 'nullable|date']); + break; + case 'url': + $request->validate([$metadataKey => 'nullable|url']); + break; + case 'image': + if ($request->hasFile("metadata.{$property['code']}")) { + $imagePath = $this->uploadThumb($term, $request->file("metadata.{$property['code']}"), "taxonomy_terms"); + $value = $imagePath; + } else { + $value = null; + } + break; + } + } + + $metadataArray = []; + foreach ($taxonomy->properties as $property) { + $value = $request->input("metadata.{$property['code']}"); + + if ($property['data_type'] === 'boolean') { + $value = $request->has("metadata.{$property['code']}") ? true : false; + } + + $metadataArray[] = [ + 'code' => $property['code'], + 'value' => $value === '' ? null : $value + ]; + } + + $term->update($validatedData); + $term->metadata = $metadataArray; + $term->updated_by = Auth::user()->id; + $term->save(); + + return redirect()->route('dashboard.taxonomy.terms.index', $taxonomy) + ->with('Success', 'Taxonomy term was updated successfully!'); + } catch (\Exception $ex) { + Log::error('Failed to update taxonomy term', ['term_id' => $term->id, 'error' => $ex->getMessage()]); + return back()->withInput()->withErrors(['error' => 'Failed to update taxonomy term. Please try again.']); + } + } + /** + * Confirm to delete the specified resource from storage. + * + * @param \App\Domains\TaxonomyTerm\Models\TaxonomyTerm $taxonomyTerm + * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View + */ + public function delete(Taxonomy $taxonomy, TaxonomyTerm $term) + { + return view('backend.taxonomy.terms.delete', compact('taxonomy', 'term')); + } + + /** + * Remove the specified resource from storage. + * + * @param \App\Domains\TaxonomyTerm\Models\TaxonomyTerm $taxonomyTerm + * @return \Illuminate\Http\RedirectResponse|null + */ + public function destroy(Taxonomy $taxonomy, TaxonomyTerm $term) + { + try { + $term->delete(); + return redirect()->route('dashboard.taxonomy.terms.index', $taxonomy)->with('Success', 'Taxonomy term was deleted !'); + } catch (\Exception $ex) { + Log::error('Failed to delete taxonomy term', ['term_id' => $term->id, 'error' => $ex->getMessage()]); + return back()->withErrors(['error' => 'Failed to delete taxonomy term. Please try again.']); + } + } +} \ No newline at end of file diff --git a/app/Http/Controllers/Frontend/HomeController.php b/app/Http/Controllers/Frontend/HomeController.php index d49454e3..dfd0e1e0 100644 --- a/app/Http/Controllers/Frontend/HomeController.php +++ b/app/Http/Controllers/Frontend/HomeController.php @@ -32,6 +32,7 @@ public function contributors() { $projects = [ '/projects/v1/co225/E20/Computer-Engineering-Portal/', + '/projects/v1/co227/E20/Computer-Engineering-Portal/', ]; $data = []; @@ -44,4 +45,4 @@ public function contributors() return view('frontend.pages.contributors', compact('data')); } -} \ No newline at end of file +} diff --git a/app/Http/Livewire/Backend/TaxonomyTable.php b/app/Http/Livewire/Backend/TaxonomyTable.php new file mode 100644 index 00000000..9028c80e --- /dev/null +++ b/app/Http/Livewire/Backend/TaxonomyTable.php @@ -0,0 +1,48 @@ +searchable()->sortable(), + Column::make("Name", "name") + ->searchable()->sortable(), + Column::make("Created by", "created_by") + ->sortable(), + Column::make("Updated by", "updated_by") + ->sortable(), + Column::make("Created at", "created_at") + ->sortable(), + Column::make("Updated at", "updated_at") + ->sortable(), + Column::make("Actions") + ]; + } + + public function query(): Builder + { + return Taxonomy::query() + ->with('user'); + } + + public function rowView(): string + { + return 'backend.taxonomy.index-table-row'; + } +} + diff --git a/app/Http/Livewire/Backend/TaxonomyTermTable.php b/app/Http/Livewire/Backend/TaxonomyTermTable.php new file mode 100644 index 00000000..e21ea266 --- /dev/null +++ b/app/Http/Livewire/Backend/TaxonomyTermTable.php @@ -0,0 +1,77 @@ +taxonomy = $taxonomy; + } + + public function columns(): array + { + return [ + Column::make("Name", "name") + ->searchable()->sortable(), + Column::make("Code", "code") + ->searchable()->sortable(), + Column::make("Taxonomy Parent", "parent_id"), + Column::make("Created by", "created_by") + ->sortable(), + Column::make("Updated by", "updated_by") + ->sortable(), + Column::make("Created at", "created_at") + ->sortable(), + Column::make("Updated at", "updated_at") + ->sortable(), + Column::make("Actions") + ]; + } + + public function query(): Builder + { + return TaxonomyTerm::query() + ->where('taxonomy_id', $this->taxonomy->id) + ->when($this->getFilter('taxonomy_term'), fn($query, $type) => $query->where('parent_id', $type)->orWhere('id', $type)) + ->with('user')->orderBy('parent_id'); + } + + public function filters(): array + { + $terms = []; + + foreach ( + TaxonomyTerm::query() + ->where('taxonomy_id', $this->taxonomy->id) + ->whereNull('parent_id')->get() as $key => $value + ) { + $terms[$value->id] = $value->name; + }; + + return [ + 'taxonomy_term' => Filter::make('Taxonomy Term') + ->select($terms) + ]; + } + + + public function rowView(): string + { + return 'backend.taxonomy.terms.index-table-row'; + } +} \ No newline at end of file diff --git a/app/Http/Resources/TaxonomyListResource.php b/app/Http/Resources/TaxonomyListResource.php new file mode 100644 index 00000000..bff3dd17 --- /dev/null +++ b/app/Http/Resources/TaxonomyListResource.php @@ -0,0 +1,28 @@ + $this->code, + 'name' => $this->name, + 'description' => $this->description, + 'api' => config('app.url', '') . "/api/taxonomy/v1/" . $this->code, + ]; + } +} \ No newline at end of file diff --git a/app/Http/Resources/TaxonomyResource.php b/app/Http/Resources/TaxonomyResource.php new file mode 100644 index 00000000..b97d05b5 --- /dev/null +++ b/app/Http/Resources/TaxonomyResource.php @@ -0,0 +1,35 @@ + $this->code, + 'name' => $this->name, + 'description' => $this->description, + // 'properties' => $this->properties, + 'terms' => TaxonomyTermResource::collection($this->first_child_terms), + // 'created_by' => User::find($this->created_by)?->name, + // 'updated_by' => User::find($this->updated_by)?->name, + // 'created_at' => $this->created_at, + // 'updated_at' => $this->updated_at, + ]; + } +} \ No newline at end of file diff --git a/app/Http/Resources/TaxonomyTermResource.php b/app/Http/Resources/TaxonomyTermResource.php new file mode 100644 index 00000000..252214c3 --- /dev/null +++ b/app/Http/Resources/TaxonomyTermResource.php @@ -0,0 +1,38 @@ +getFormattedMetadataAttribute(); + + + return [ + 'code' => $this->code, + 'name' => $this->name, + 'terms' => $this->when( + sizeof($this->children) > 0, + TaxonomyTermResource::collection($this->children) + ), + 'metadata' => $this->when( + sizeof($metadata) > 0, + $metadata + ), + // 'created_by' => User::find($this->created_by)?->name, + // 'updated_by' => User::find($this->updated_by)?->name, + // 'created_at' => $this->created_at, + // 'updated_at' => $this->updated_at, + ]; + } +} \ No newline at end of file diff --git a/composer.lock b/composer.lock index 2f9ba4b5..35c0e3bd 100644 --- a/composer.lock +++ b/composer.lock @@ -45,17 +45,13 @@ } }, "autoload": { - "files": [ - "helpers.php" - ], + "files": ["helpers.php"], "psr-4": { "Arcanedev\\LogViewer\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "ARCANEDEV", @@ -112,17 +108,13 @@ } }, "autoload": { - "files": [ - "helpers.php" - ], + "files": ["helpers.php"], "psr-4": { "Arcanedev\\Support\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "ARCANEDEV", @@ -132,12 +124,7 @@ ], "description": "ARCANEDEV Support Helpers", "homepage": "https://github.com/ARCANEDEV/Support", - "keywords": [ - "arcanedev", - "arcanesoft", - "laravel", - "support" - ], + "keywords": ["arcanedev", "arcanesoft", "laravel", "support"], "support": { "issues": "https://github.com/ARCANEDEV/Support/issues", "source": "https://github.com/ARCANEDEV/Support/tree/8.1.1" @@ -179,9 +166,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-2-Clause" - ], + "license": ["BSD-2-Clause"], "authors": [ { "name": "Ben Scholzen 'DASPRiD'", @@ -227,9 +212,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "description": "Arbitrary-precision arithmetic library", "keywords": [ "Arbitrary-precision", @@ -290,9 +273,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "KyleKatarn", @@ -300,13 +281,7 @@ } ], "description": "Types to use Carbon in Doctrine", - "keywords": [ - "carbon", - "date", - "datetime", - "doctrine", - "time" - ], + "keywords": ["carbon", "date", "datetime", "doctrine", "time"], "support": { "issues": "https://github.com/CarbonPHP/carbon-doctrine-types/issues", "source": "https://github.com/CarbonPHP/carbon-doctrine-types/tree/2.1.0" @@ -371,9 +346,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Italo Israel Baeza Cabrera", @@ -435,9 +408,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-2-Clause" - ], + "license": ["BSD-2-Clause"], "authors": [ { "name": "Ben Scholzen 'DASPRiD'", @@ -447,10 +418,7 @@ } ], "description": "PHP 7.1 enum implementation", - "keywords": [ - "enum", - "map" - ], + "keywords": ["enum", "map"], "support": { "issues": "https://github.com/DASPRiD/Enum/issues", "source": "https://github.com/DASPRiD/Enum/tree/1.0.6" @@ -493,9 +461,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Dragonfly Development Inc.", @@ -520,12 +486,7 @@ ], "description": "Given a deep data structure, access data by dot notation.", "homepage": "https://github.com/dflydev/dflydev-dot-access-data", - "keywords": [ - "access", - "data", - "dot", - "notation" - ], + "keywords": ["access", "data", "dot", "notation"], "support": { "issues": "https://github.com/dflydev/dflydev-dot-access-data/issues", "source": "https://github.com/dflydev/dflydev-dot-access-data/tree/v3.0.3" @@ -567,9 +528,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-3.0-only" - ], + "license": ["LGPL-3.0-only"], "description": "DO File Cache is a PHP File-based Caching Library. Its syntax is designed to closely resemble the PHP memcache extension.", "keywords": [ "cache", @@ -615,9 +574,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-3.0-only" - ], + "license": ["LGPL-3.0-only"], "authors": [ { "name": "Jordan Hall", @@ -660,9 +617,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-3.0-only" - ], + "license": ["LGPL-3.0-only"], "authors": [ { "name": "Jordan Hall", @@ -724,17 +679,13 @@ } }, "autoload": { - "files": [ - "src/PasswordExposedFunction.php" - ], + "files": ["src/PasswordExposedFunction.php"], "psr-4": { "DivineOmega\\PasswordExposed\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-3.0-only" - ], + "license": ["LGPL-3.0-only"], "authors": [ { "name": "Jordan Hall", @@ -786,9 +737,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-3.0-only" - ], + "license": ["LGPL-3.0-only"], "authors": [ { "name": "Jordan Hall", @@ -843,9 +792,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Guilherme Blanco", @@ -941,9 +888,7 @@ "suggest": { "symfony/console": "For helpful console commands such as SQL execution and import of files." }, - "bin": [ - "bin/doctrine-dbal" - ], + "bin": ["bin/doctrine-dbal"], "type": "library", "autoload": { "psr-4": { @@ -951,9 +896,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Guilherme Blanco", @@ -1050,9 +993,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "description": "A small layer on top of trigger_error(E_USER_DEPRECATED) or PSR-3 logging with options to disable all deprecations or selectively for packages.", "homepage": "https://www.doctrine-project.org/", "support": { @@ -1094,9 +1035,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Guilherme Blanco", @@ -1184,9 +1123,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Guilherme Blanco", @@ -1273,9 +1210,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Guilherme Blanco", @@ -1292,13 +1227,7 @@ ], "description": "PHP Doctrine Lexer parser library that can be used in Top-Down, Recursive Descent Parsers.", "homepage": "https://www.doctrine-project.org/projects/lexer.html", - "keywords": [ - "annotations", - "docblock", - "lexer", - "parser", - "php" - ], + "keywords": ["annotations", "docblock", "lexer", "parser", "php"], "support": { "issues": "https://github.com/doctrine/lexer/issues", "source": "https://github.com/doctrine/lexer/tree/1.2.3" @@ -1357,9 +1286,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Chris Tankersley", @@ -1368,10 +1295,7 @@ } ], "description": "CRON for PHP: Calculate the next or previous run date and determine if a CRON expression is due", - "keywords": [ - "cron", - "schedule" - ], + "keywords": ["cron", "schedule"], "support": { "issues": "https://github.com/dragonmantank/cron-expression/issues", "source": "https://github.com/dragonmantank/cron-expression/tree/v3.4.0" @@ -1423,9 +1347,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Eduardo Gulias Davis" @@ -1488,9 +1410,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Neuman Vong", @@ -1505,10 +1425,7 @@ ], "description": "A simple library to encode and decode JSON Web Tokens (JWT) in PHP. Should conform to the current spec.", "homepage": "https://github.com/firebase/php-jwt", - "keywords": [ - "jwt", - "php" - ], + "keywords": ["jwt", "php"], "support": { "issues": "https://github.com/firebase/php-jwt/issues", "source": "https://github.com/firebase/php-jwt/tree/v6.10.1" @@ -1547,9 +1464,7 @@ "dev-master": "3.0-dev" }, "laravel": { - "providers": [ - "Fruitcake\\Cors\\CorsServiceProvider" - ] + "providers": ["Fruitcake\\Cors\\CorsServiceProvider"] } }, "autoload": { @@ -1558,9 +1473,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fruitcake", @@ -1572,12 +1485,7 @@ } ], "description": "Adds CORS (Cross-Origin Resource Sharing) headers support in your Laravel application", - "keywords": [ - "api", - "cors", - "crossdomain", - "laravel" - ], + "keywords": ["api", "cors", "crossdomain", "laravel"], "support": { "issues": "https://github.com/fruitcake/laravel-cors/issues", "source": "https://github.com/fruitcake/laravel-cors/tree/v3.0.0" @@ -1630,9 +1538,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fruitcake", @@ -1645,11 +1551,7 @@ ], "description": "Cross-origin resource sharing library for the Symfony HttpFoundation", "homepage": "https://github.com/fruitcake/php-cors", - "keywords": [ - "cors", - "laravel", - "symfony" - ], + "keywords": ["cors", "laravel", "symfony"], "support": { "issues": "https://github.com/fruitcake/php-cors/issues", "source": "https://github.com/fruitcake/php-cors/tree/v1.3.0" @@ -1694,9 +1596,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Graham Campbell", @@ -1774,17 +1674,13 @@ } }, "autoload": { - "files": [ - "src/functions_include.php" - ], + "files": ["src/functions_include.php"], "psr-4": { "GuzzleHttp\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Graham Campbell", @@ -1888,9 +1784,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Graham Campbell", @@ -1914,9 +1808,7 @@ } ], "description": "Guzzle promises library", - "keywords": [ - "promise" - ], + "keywords": ["promise"], "support": { "issues": "https://github.com/guzzle/promises/issues", "source": "https://github.com/guzzle/promises/tree/2.0.4" @@ -1982,9 +1874,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Graham Campbell", @@ -2087,9 +1977,7 @@ "dev-master": "2.4-dev" }, "laravel": { - "providers": [ - "Intervention\\Image\\ImageServiceProvider" - ], + "providers": ["Intervention\\Image\\ImageServiceProvider"], "aliases": { "Image": "Intervention\\Image\\Facades\\Image" } @@ -2101,9 +1989,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Oliver Vogel", @@ -2175,9 +2061,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "James Mills", @@ -2185,10 +2069,7 @@ } ], "description": "Timezone storage and retrieval for Laravel", - "keywords": [ - "laravel", - "timezone" - ], + "keywords": ["laravel", "timezone"], "support": { "issues": "https://github.com/jamesmills/laravel-timezone/issues", "source": "https://github.com/jamesmills/laravel-timezone/tree/1.13.0" @@ -2227,17 +2108,13 @@ } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Lab404\\Impersonate\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Marceau Casals", @@ -2300,9 +2177,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-3.0-only" - ], + "license": ["LGPL-3.0-only"], "authors": [ { "name": "Jordan Hall", @@ -2468,9 +2343,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Taylor Otwell", @@ -2479,10 +2352,7 @@ ], "description": "The Laravel Framework.", "homepage": "https://laravel.com", - "keywords": [ - "framework", - "laravel" - ], + "keywords": ["framework", "laravel"], "support": { "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" @@ -2522,9 +2392,7 @@ "dev-master": "2.x-dev" }, "laravel": { - "providers": [ - "Laravel\\Sanctum\\SanctumServiceProvider" - ] + "providers": ["Laravel\\Sanctum\\SanctumServiceProvider"] } }, "autoload": { @@ -2533,9 +2401,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Taylor Otwell", @@ -2543,11 +2409,7 @@ } ], "description": "Laravel Sanctum provides a featherweight authentication system for SPAs and simple APIs.", - "keywords": [ - "auth", - "laravel", - "sanctum" - ], + "keywords": ["auth", "laravel", "sanctum"], "support": { "issues": "https://github.com/laravel/sanctum/issues", "source": "https://github.com/laravel/sanctum" @@ -2590,9 +2452,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Taylor Otwell", @@ -2604,11 +2464,7 @@ } ], "description": "Laravel Serializable Closure provides an easy and secure way to serialize closures in PHP.", - "keywords": [ - "closure", - "laravel", - "serializable" - ], + "keywords": ["closure", "laravel", "serializable"], "support": { "issues": "https://github.com/laravel/serializable-closure/issues", "source": "https://github.com/laravel/serializable-closure" @@ -2666,9 +2522,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Taylor Otwell", @@ -2677,10 +2531,7 @@ ], "description": "Laravel wrapper around OAuth 1 & OAuth 2 libraries.", "homepage": "https://laravel.com", - "keywords": [ - "laravel", - "oauth" - ], + "keywords": ["laravel", "oauth"], "support": { "issues": "https://github.com/laravel/socialite/issues", "source": "https://github.com/laravel/socialite" @@ -2720,9 +2571,7 @@ "type": "library", "extra": { "laravel": { - "providers": [ - "Laravel\\Tinker\\TinkerServiceProvider" - ] + "providers": ["Laravel\\Tinker\\TinkerServiceProvider"] } }, "autoload": { @@ -2731,9 +2580,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Taylor Otwell", @@ -2741,12 +2588,7 @@ } ], "description": "Powerful REPL for the Laravel framework.", - "keywords": [ - "REPL", - "Tinker", - "laravel", - "psysh" - ], + "keywords": ["REPL", "Tinker", "laravel", "psysh"], "support": { "issues": "https://github.com/laravel/tinker/issues", "source": "https://github.com/laravel/tinker/tree/v2.10.0" @@ -2783,9 +2625,7 @@ "dev-master": "3.x-dev" }, "laravel": { - "providers": [ - "Laravel\\Ui\\UiServiceProvider" - ] + "providers": ["Laravel\\Ui\\UiServiceProvider"] } }, "autoload": { @@ -2795,9 +2635,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Taylor Otwell", @@ -2805,10 +2643,7 @@ } ], "description": "Laravel UI utilities and presets.", - "keywords": [ - "laravel", - "ui" - ], + "keywords": ["laravel", "ui"], "support": { "source": "https://github.com/laravel/ui/tree/v3.4.6" }, @@ -2847,9 +2682,7 @@ "dev-master": "6.x-dev" }, "laravel": { - "providers": [ - "Collective\\Html\\HtmlServiceProvider" - ], + "providers": ["Collective\\Html\\HtmlServiceProvider"], "aliases": { "Form": "Collective\\Html\\FormFacade", "Html": "Collective\\Html\\HtmlFacade" @@ -2857,17 +2690,13 @@ } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Collective\\Html\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Adam Engebretson", @@ -2943,9 +2772,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Colin O'Dell", @@ -3031,9 +2858,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Colin O'Dell", @@ -3128,9 +2953,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Frank de Jonge", @@ -3199,9 +3022,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Frank de Jonge", @@ -3269,9 +3090,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Ben Corlett", @@ -3335,26 +3154,20 @@ "type": "library", "extra": { "laravel": { - "providers": [ - "Livewire\\LivewireServiceProvider" - ], + "providers": ["Livewire\\LivewireServiceProvider"], "aliases": { "Livewire": "Livewire\\Livewire" } } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Livewire\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Caleb Porzio", @@ -3403,9 +3216,7 @@ "type": "library", "extra": { "laravel": { - "providers": [ - "MarvinLabs\\DiscordLogger\\ServiceProvider" - ] + "providers": ["MarvinLabs\\DiscordLogger\\ServiceProvider"] } }, "autoload": { @@ -3414,9 +3225,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Vincent Mimoun-Prat", @@ -3426,12 +3235,7 @@ } ], "description": "Logging to a discord channel in Laravel", - "keywords": [ - "discord", - "laravel", - "logger", - "logging" - ], + "keywords": ["discord", "laravel", "logger", "logging"], "support": { "issues": "https://github.com/marvinlabs/laravel-discord-logger/issues", "source": "https://github.com/marvinlabs/laravel-discord-logger/tree/v1.4.2" @@ -3513,9 +3317,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Jordi Boggiano", @@ -3525,11 +3327,7 @@ ], "description": "Sends your logs to files, sockets, inboxes, databases and various web services", "homepage": "https://github.com/Seldaek/monolog", - "keywords": [ - "log", - "logging", - "psr-3" - ], + "keywords": ["log", "logging", "psr-3"], "support": { "issues": "https://github.com/Seldaek/monolog/issues", "source": "https://github.com/Seldaek/monolog/tree/2.9.3" @@ -3585,9 +3383,7 @@ "phpunit/phpunit": "^7.5.20 || ^8.5.26 || ^9.5.20", "squizlabs/php_codesniffer": "^3.4" }, - "bin": [ - "bin/carbon" - ], + "bin": ["bin/carbon"], "type": "library", "extra": { "branch-alias": { @@ -3595,14 +3391,10 @@ "dev-2.x": "2.x-dev" }, "laravel": { - "providers": [ - "Carbon\\Laravel\\ServiceProvider" - ] + "providers": ["Carbon\\Laravel\\ServiceProvider"] }, "phpstan": { - "includes": [ - "extension.neon" - ] + "includes": ["extension.neon"] } }, "autoload": { @@ -3611,9 +3403,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Brian Nesbitt", @@ -3627,11 +3417,7 @@ ], "description": "An API extension for DateTime that supports 281 different languages.", "homepage": "https://carbon.nesbot.com", - "keywords": [ - "date", - "datetime", - "time" - ], + "keywords": ["date", "datetime", "time"], "support": { "docs": "https://carbon.nesbot.com/docs", "issues": "https://github.com/briannesbitt/Carbon/issues", @@ -3683,16 +3469,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0-only", - "GPL-3.0-only" - ], + "license": ["BSD-3-Clause", "GPL-2.0-only", "GPL-3.0-only"], "authors": [ { "name": "David Grudl", @@ -3705,10 +3485,7 @@ ], "description": "📐 Nette Schema: validating data structures against a given Schema.", "homepage": "https://nette.org", - "keywords": [ - "config", - "nette" - ], + "keywords": ["config", "nette"], "support": { "issues": "https://github.com/nette/schema/issues", "source": "https://github.com/nette/schema/tree/v1.3.2" @@ -3757,16 +3534,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0-only", - "GPL-3.0-only" - ], + "license": ["BSD-3-Clause", "GPL-2.0-only", "GPL-3.0-only"], "authors": [ { "name": "David Grudl", @@ -3825,9 +3596,7 @@ "ircmaxell/php-yacc": "^0.0.7", "phpunit/phpunit": "^9.0" }, - "bin": [ - "bin/php-parse" - ], + "bin": ["bin/php-parse"], "type": "library", "extra": { "branch-alias": { @@ -3840,19 +3609,14 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Nikita Popov" } ], "description": "A PHP parser written in PHP", - "keywords": [ - "parser", - "php" - ], + "keywords": ["parser", "php"], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", "source": "https://github.com/nikic/PHP-Parser/tree/v5.3.1" @@ -3902,9 +3666,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Tobias Nyholm", @@ -3917,10 +3679,7 @@ ], "description": "A fast PHP7 implementation of PSR-7", "homepage": "https://tnyholm.se", - "keywords": [ - "psr-17", - "psr-7" - ], + "keywords": ["psr-17", "psr-7"], "support": { "issues": "https://github.com/Nyholm/psr7/issues", "source": "https://github.com/Nyholm/psr7/tree/1.8.2" @@ -3965,17 +3724,13 @@ } }, "autoload": { - "files": [ - "functions.php" - ], + "files": ["functions.php"], "psr-4": { "Opis\\Closure\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Marius Sarca", @@ -4028,9 +3783,7 @@ "composer/composer": "^1|^2", "phpunit/phpunit": "^4|^5|^6|^7|^8|^9" }, - "bin": [ - "bin/certainty-cert-symlink" - ], + "bin": ["bin/certainty-cert-symlink"], "type": "library", "autoload": { "psr-4": { @@ -4038,9 +3791,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "ISC" - ], + "license": ["ISC"], "authors": [ { "name": "Paragon Initiative Enterprises", @@ -4096,9 +3847,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Paragon Initiative Enterprises", @@ -4161,9 +3910,7 @@ }, "type": "library", "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Paragon Initiative Enterprises", @@ -4172,12 +3919,7 @@ } ], "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", - "keywords": [ - "csprng", - "polyfill", - "pseudorandom", - "random" - ], + "keywords": ["csprng", "polyfill", "pseudorandom", "random"], "support": { "email": "info@paragonie.com", "issues": "https://github.com/paragonie/random_compat/issues", @@ -4217,14 +3959,10 @@ } }, "autoload": { - "files": [ - "autoload.php" - ] + "files": ["autoload.php"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "ISC" - ], + "license": ["ISC"], "authors": [ { "name": "Paragon Initiative Enterprises", @@ -4323,14 +4061,10 @@ "psr-4": { "Http\\Discovery\\": "src/" }, - "exclude-from-classmap": [ - "src/Composer/Plugin.php" - ] + "exclude-from-classmap": ["src/Composer/Plugin.php"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Márk Sági-Kazár", @@ -4392,9 +4126,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "Apache-2.0" - ], + "license": ["Apache-2.0"], "authors": [ { "name": "Johannes M. Schmitt", @@ -4408,12 +4140,7 @@ } ], "description": "Option Type for PHP", - "keywords": [ - "language", - "option", - "php", - "type" - ], + "keywords": ["language", "option", "php", "type"], "support": { "issues": "https://github.com/schmittjoh/php-option/issues", "source": "https://github.com/schmittjoh/php-option/tree/1.9.3" @@ -4461,17 +4188,13 @@ }, "type": "library", "autoload": { - "files": [ - "phpseclib/bootstrap.php" - ], + "files": ["phpseclib/bootstrap.php"], "psr-4": { "phpseclib3\\": "phpseclib/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Jim Wigginton", @@ -4569,9 +4292,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4579,11 +4300,7 @@ } ], "description": "Common interface for caching libraries", - "keywords": [ - "cache", - "psr", - "psr-6" - ], + "keywords": ["cache", "psr", "psr-6"], "support": { "source": "https://github.com/php-fig/cache/tree/master" }, @@ -4613,9 +4330,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4624,13 +4339,7 @@ ], "description": "Common interface for reading the clock.", "homepage": "https://github.com/php-fig/clock", - "keywords": [ - "clock", - "now", - "psr", - "psr-20", - "time" - ], + "keywords": ["clock", "now", "psr", "psr-20", "time"], "support": { "issues": "https://github.com/php-fig/clock/issues", "source": "https://github.com/php-fig/clock/tree/1.0.0" @@ -4661,9 +4370,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4714,9 +4421,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4724,11 +4429,7 @@ } ], "description": "Standard interfaces for event handling.", - "keywords": [ - "events", - "psr", - "psr-14" - ], + "keywords": ["events", "psr", "psr-14"], "support": { "issues": "https://github.com/php-fig/event-dispatcher/issues", "source": "https://github.com/php-fig/event-dispatcher/tree/1.0.0" @@ -4765,9 +4466,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4776,12 +4475,7 @@ ], "description": "Common interface for HTTP clients", "homepage": "https://github.com/php-fig/http-client", - "keywords": [ - "http", - "http-client", - "psr", - "psr-18" - ], + "keywords": ["http", "http-client", "psr", "psr-18"], "support": { "source": "https://github.com/php-fig/http-client" }, @@ -4817,9 +4511,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4871,9 +4563,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4924,9 +4614,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4935,11 +4623,7 @@ ], "description": "Common interface for logging libraries", "homepage": "https://github.com/php-fig/log", - "keywords": [ - "log", - "psr", - "psr-3" - ], + "keywords": ["log", "psr", "psr-3"], "support": { "source": "https://github.com/php-fig/log/tree/2.0.0" }, @@ -4974,9 +4658,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "PHP-FIG", @@ -4984,13 +4666,7 @@ } ], "description": "Common interfaces for simple caching", - "keywords": [ - "cache", - "caching", - "psr", - "psr-16", - "simple-cache" - ], + "keywords": ["cache", "caching", "psr", "psr-16", "simple-cache"], "support": { "source": "https://github.com/php-fig/simple-cache/tree/master" }, @@ -5029,9 +4705,7 @@ "ext-pdo-sqlite": "The doc command requires SQLite to work.", "ext-posix": "If you have PCNTL, you'll want the POSIX extension as well." }, - "bin": [ - "bin/psysh" - ], + "bin": ["bin/psysh"], "type": "library", "extra": { "branch-alias": { @@ -5043,17 +4717,13 @@ } }, "autoload": { - "files": [ - "src/functions.php" - ], + "files": ["src/functions.php"], "psr-4": { "Psy\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Justin Hileman", @@ -5063,12 +4733,7 @@ ], "description": "An interactive shell for modern PHP.", "homepage": "http://psysh.org", - "keywords": [ - "REPL", - "console", - "interactive", - "shell" - ], + "keywords": ["REPL", "console", "interactive", "shell"], "support": { "issues": "https://github.com/bobthecow/psysh/issues", "source": "https://github.com/bobthecow/psysh/tree/v0.12.4" @@ -5098,14 +4763,10 @@ }, "type": "library", "autoload": { - "files": [ - "src/getallheaders.php" - ] + "files": ["src/getallheaders.php"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Ralph Khattar", @@ -5173,9 +4834,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Ben Ramsey", @@ -5184,14 +4843,7 @@ } ], "description": "A PHP library for representing and manipulating collections.", - "keywords": [ - "array", - "collection", - "hash", - "map", - "queue", - "set" - ], + "keywords": ["array", "collection", "hash", "map", "queue", "set"], "support": { "issues": "https://github.com/ramsey/collection/issues", "source": "https://github.com/ramsey/collection/tree/2.0.0" @@ -5267,23 +4919,15 @@ } }, "autoload": { - "files": [ - "src/functions.php" - ], + "files": ["src/functions.php"], "psr-4": { "Ramsey\\Uuid\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "description": "A PHP library for generating and working with universally unique identifiers (UUIDs).", - "keywords": [ - "guid", - "identifier", - "uuid" - ], + "keywords": ["guid", "identifier", "uuid"], "support": { "issues": "https://github.com/ramsey/uuid/issues", "source": "https://github.com/ramsey/uuid/tree/4.7.6" @@ -5341,9 +4985,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Anthony Rappa", @@ -5397,9 +5039,7 @@ "type": "library", "extra": { "laravel": { - "providers": [ - "Rappasoft\\Lockout\\LockoutServiceProvider" - ] + "providers": ["Rappasoft\\Lockout\\LockoutServiceProvider"] } }, "autoload": { @@ -5408,9 +5048,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Anthony Rappa", @@ -5420,12 +5058,7 @@ ], "description": "Put your Laravel application into read-only mode.", "homepage": "https://github.com/rappasoft/lockout", - "keywords": [ - "Read-Only", - "laravel", - "lockout", - "rappasoft" - ], + "keywords": ["Read-Only", "laravel", "lockout", "rappasoft"], "support": { "issues": "https://github.com/rappasoft/lockout/issues", "source": "https://github.com/rappasoft/lockout/tree/v3.0.1" @@ -5472,17 +5105,13 @@ } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Spatie\\Activitylog\\": "src" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Freek Van der Herten", @@ -5505,13 +5134,7 @@ ], "description": "A very simple activity logger to monitor the users of your website or application", "homepage": "https://github.com/spatie/activitylog", - "keywords": [ - "activity", - "laravel", - "log", - "spatie", - "user" - ], + "keywords": ["activity", "laravel", "log", "spatie", "user"], "support": { "issues": "https://github.com/spatie/laravel-activitylog/issues", "source": "https://github.com/spatie/laravel-activitylog/tree/3.17.0" @@ -5559,9 +5182,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Freek Van der Herten", @@ -5571,10 +5192,7 @@ ], "description": "Tools for creating Laravel packages", "homepage": "https://github.com/spatie/laravel-package-tools", - "keywords": [ - "laravel-package-tools", - "spatie" - ], + "keywords": ["laravel-package-tools", "spatie"], "support": { "issues": "https://github.com/spatie/laravel-package-tools/issues", "source": "https://github.com/spatie/laravel-package-tools/tree/1.12.1" @@ -5626,17 +5244,13 @@ } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Spatie\\Permission\\": "src" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Freek Van der Herten", @@ -5704,14 +5318,10 @@ } }, "autoload": { - "files": [ - "lib/swift_required.php" - ] + "files": ["lib/swift_required.php"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Chris Corbyn" @@ -5723,11 +5333,7 @@ ], "description": "Swiftmailer, free feature-rich PHP mailer", "homepage": "https://swiftmailer.symfony.com", - "keywords": [ - "email", - "mail", - "mailer" - ], + "keywords": ["email", "mail", "mailer"], "support": { "issues": "https://github.com/swiftmailer/swiftmailer/issues", "source": "https://github.com/swiftmailer/swiftmailer/tree/v6.3.0" @@ -5799,14 +5405,10 @@ "psr-4": { "Symfony\\Component\\Console\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -5819,12 +5421,7 @@ ], "description": "Eases the creation of beautiful and testable command line interfaces", "homepage": "https://symfony.com", - "keywords": [ - "cli", - "command-line", - "console", - "terminal" - ], + "keywords": ["cli", "command-line", "console", "terminal"], "support": { "source": "https://github.com/symfony/console/tree/v5.4.44" }, @@ -5866,14 +5463,10 @@ "psr-4": { "Symfony\\Component\\CssSelector\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -5937,14 +5530,10 @@ } }, "autoload": { - "files": [ - "function.php" - ] + "files": ["function.php"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -6000,22 +5589,16 @@ "symfony/http-kernel": "^4.4|^5.0|^6.0", "symfony/serializer": "^4.4|^5.0|^6.0" }, - "bin": [ - "Resources/bin/patch-type-declarations" - ], + "bin": ["Resources/bin/patch-type-declarations"], "type": "library", "autoload": { "psr-4": { "Symfony\\Component\\ErrorHandler\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -6088,14 +5671,10 @@ "psr-4": { "Symfony\\Component\\EventDispatcher\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -6161,9 +5740,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -6227,14 +5804,10 @@ "psr-4": { "Symfony\\Component\\Finder\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -6303,14 +5876,10 @@ "psr-4": { "Symfony\\Component\\HttpFoundation\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -6416,14 +5985,10 @@ "psr-4": { "Symfony\\Component\\HttpKernel\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -6497,14 +6062,10 @@ "psr-4": { "Symfony\\Component\\Mime\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -6517,10 +6078,7 @@ ], "description": "Allows manipulating MIME messages", "homepage": "https://symfony.com", - "keywords": [ - "mime", - "mime-type" - ], + "keywords": ["mime", "mime-type"], "support": { "source": "https://github.com/symfony/mime/tree/v5.4.43" }, @@ -6571,17 +6129,13 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Ctype\\": "" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Gert de Pagter", @@ -6594,12 +6148,7 @@ ], "description": "Symfony polyfill for ctype functions", "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "ctype", - "polyfill", - "portable" - ], + "keywords": ["compatibility", "ctype", "polyfill", "portable"], "support": { "source": "https://github.com/symfony/polyfill-ctype/tree/v1.31.0" }, @@ -6650,17 +6199,13 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Iconv\\": "" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -6727,17 +6272,13 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Intl\\Grapheme\\": "" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -6806,17 +6347,13 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Intl\\Idn\\": "" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Laurent Bassin", @@ -6888,20 +6425,14 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Intl\\Normalizer\\": "" }, - "classmap": [ - "Resources/stubs" - ] + "classmap": ["Resources/stubs"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -6972,17 +6503,13 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Mbstring\\": "" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -7046,20 +6573,14 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Php73\\": "" }, - "classmap": [ - "Resources/stubs" - ] + "classmap": ["Resources/stubs"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -7072,12 +6593,7 @@ ], "description": "Symfony polyfill backporting some PHP 7.3+ features to lower PHP versions", "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], + "keywords": ["compatibility", "polyfill", "portable", "shim"], "support": { "source": "https://github.com/symfony/polyfill-php73/tree/v1.31.0" }, @@ -7122,20 +6638,14 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Php80\\": "" }, - "classmap": [ - "Resources/stubs" - ] + "classmap": ["Resources/stubs"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Ion Bazan", @@ -7152,12 +6662,7 @@ ], "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], + "keywords": ["compatibility", "polyfill", "portable", "shim"], "support": { "source": "https://github.com/symfony/polyfill-php80/tree/v1.31.0" }, @@ -7200,14 +6705,10 @@ "psr-4": { "Symfony\\Component\\Process\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -7284,14 +6785,10 @@ "psr-4": { "Symfony\\Component\\Routing\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -7304,12 +6801,7 @@ ], "description": "Maps an HTTP request to a set of configuration variables", "homepage": "https://symfony.com", - "keywords": [ - "router", - "routing", - "uri", - "url" - ], + "keywords": ["router", "routing", "uri", "url"], "support": { "source": "https://github.com/symfony/routing/tree/v5.4.43" }, @@ -7365,14 +6857,10 @@ "psr-4": { "Symfony\\Contracts\\Service\\": "" }, - "exclude-from-classmap": [ - "/Test/" - ] + "exclude-from-classmap": ["/Test/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -7445,20 +6933,14 @@ }, "type": "library", "autoload": { - "files": [ - "Resources/functions.php" - ], + "files": ["Resources/functions.php"], "psr-4": { "Symfony\\Component\\String\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -7548,20 +7030,14 @@ }, "type": "library", "autoload": { - "files": [ - "Resources/functions.php" - ], + "files": ["Resources/functions.php"], "psr-4": { "Symfony\\Component\\Translation\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -7624,14 +7100,10 @@ "psr-4": { "Symfony\\Contracts\\Translation\\": "" }, - "exclude-from-classmap": [ - "/Test/" - ] + "exclude-from-classmap": ["/Test/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -7706,25 +7178,17 @@ "ext-intl": "To show region name in time zone dump", "symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script" }, - "bin": [ - "Resources/bin/var-dump-server" - ], + "bin": ["Resources/bin/var-dump-server"], "type": "library", "autoload": { - "files": [ - "Resources/functions/dump.php" - ], + "files": ["Resources/functions/dump.php"], "psr-4": { "Symfony\\Component\\VarDumper\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -7737,10 +7201,7 @@ ], "description": "Provides mechanisms for walking through any arbitrary PHP variable", "homepage": "https://symfony.com", - "keywords": [ - "debug", - "dump" - ], + "keywords": ["debug", "dump"], "support": { "source": "https://github.com/symfony/var-dumper/tree/v5.4.43" }, @@ -7806,9 +7267,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Alexandr Chernyaev", @@ -7871,9 +7330,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Tijs Verkoyen", @@ -7927,26 +7384,20 @@ "dev-master": "1.0-dev" }, "laravel": { - "providers": [ - "Torann\\GeoIP\\GeoIPServiceProvider" - ], + "providers": ["Torann\\GeoIP\\GeoIPServiceProvider"], "aliases": { "GeoIP": "Torann\\GeoIP\\Facades\\GeoIP" } } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Torann\\GeoIP\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-2-Clause" - ], + "license": ["BSD-2-Clause"], "authors": [ { "name": "Daniel Stainback", @@ -8016,9 +7467,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Graham Campbell", @@ -8032,11 +7481,7 @@ } ], "description": "Loads environment variables from `.env` to `getenv()`, `$_ENV` and `$_SERVER` automagically.", - "keywords": [ - "dotenv", - "env", - "environment" - ], + "keywords": ["dotenv", "env", "environment"], "support": { "issues": "https://github.com/vlucas/phpdotenv/issues", "source": "https://github.com/vlucas/phpdotenv/tree/v5.6.1" @@ -8083,9 +7528,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Lars Moelleken", @@ -8094,11 +7537,7 @@ ], "description": "Portable ASCII library - performance optimized (ascii) string functions for php.", "homepage": "https://github.com/voku/portable-ascii", - "keywords": [ - "ascii", - "clean", - "php" - ], + "keywords": ["ascii", "clean", "php"], "support": { "issues": "https://github.com/voku/portable-ascii/issues", "source": "https://github.com/voku/portable-ascii/tree/1.6.1" @@ -8164,9 +7603,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Bernhard Schussek", @@ -8174,11 +7611,7 @@ } ], "description": "Assertions to validate method input/output with nice error messages.", - "keywords": [ - "assert", - "check", - "validate" - ], + "keywords": ["assert", "check", "validate"], "support": { "issues": "https://github.com/webmozarts/assert/issues", "source": "https://github.com/webmozarts/assert/tree/1.11.0" @@ -8221,26 +7654,20 @@ "dev-master": "3.6-dev" }, "laravel": { - "providers": [ - "Barryvdh\\Debugbar\\ServiceProvider" - ], + "providers": ["Barryvdh\\Debugbar\\ServiceProvider"], "aliases": { "Debugbar": "Barryvdh\\Debugbar\\Facades\\Debugbar" } } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Barryvdh\\Debugbar\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Barry vd. Heuvel", @@ -8328,9 +7755,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Barry vd. Heuvel", @@ -8397,15 +7822,11 @@ }, "autoload": { "psr-0": { - "Barryvdh": [ - "src/" - ] + "Barryvdh": ["src/"] } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Mike van Riel", @@ -8464,15 +7885,11 @@ "type": "library", "autoload": { "psr-4": { - "ParaTest\\": [ - "src/" - ] + "ParaTest\\": ["src/"] } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Brian Scaturro", @@ -8487,12 +7904,7 @@ ], "description": "Parallel testing for PHP", "homepage": "https://github.com/paratestphp/paratest", - "keywords": [ - "concurrent", - "parallel", - "phpunit", - "testing" - ], + "keywords": ["concurrent", "parallel", "phpunit", "testing"], "support": { "issues": "https://github.com/paratestphp/paratest/issues", "source": "https://github.com/paratestphp/paratest/tree/v6.11.1" @@ -8538,9 +7950,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Christian Lück", @@ -8612,9 +8022,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Jordi Boggiano", @@ -8623,9 +8031,7 @@ } ], "description": "Utilities to scan PHP code and generate class maps.", - "keywords": [ - "classmap" - ], + "keywords": ["classmap"], "support": { "issues": "https://github.com/composer/class-map-generator/issues", "source": "https://github.com/composer/class-map-generator/tree/1.4.0" @@ -8677,9 +8083,7 @@ "dev-main": "3.x-dev" }, "phpstan": { - "includes": [ - "extension.neon" - ] + "includes": ["extension.neon"] } }, "autoload": { @@ -8688,9 +8092,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Jordi Boggiano", @@ -8699,12 +8101,7 @@ } ], "description": "PCRE wrapping library that offers type-safe preg_* replacements.", - "keywords": [ - "PCRE", - "preg", - "regex", - "regular expression" - ], + "keywords": ["PCRE", "preg", "regex", "regular expression"], "support": { "issues": "https://github.com/composer/pcre/issues", "source": "https://github.com/composer/pcre/tree/3.3.1" @@ -8758,9 +8155,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nils Adermann", @@ -8779,12 +8174,7 @@ } ], "description": "Semver library that offers utilities, version constraint parsing and validation.", - "keywords": [ - "semantic", - "semver", - "validation", - "versioning" - ], + "keywords": ["semantic", "semver", "validation", "versioning"], "support": { "irc": "ircs://irc.libera.chat:6697/composer", "issues": "https://github.com/composer/semver/issues", @@ -8837,9 +8227,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "John Stevenson", @@ -8847,10 +8235,7 @@ } ], "description": "Restarts a process without Xdebug.", - "keywords": [ - "Xdebug", - "performance" - ], + "keywords": ["Xdebug", "performance"], "support": { "irc": "ircs://irc.libera.chat:6697/composer", "issues": "https://github.com/composer/xdebug-handler/issues", @@ -8906,9 +8291,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Marco Pivetta", @@ -8918,10 +8301,7 @@ ], "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", "homepage": "https://www.doctrine-project.org/projects/instantiator.html", - "keywords": [ - "constructor", - "instantiate" - ], + "keywords": ["constructor", "instantiate"], "support": { "issues": "https://github.com/doctrine/instantiator/issues", "source": "https://github.com/doctrine/instantiator/tree/2.0.0" @@ -8969,9 +8349,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Igor Wiedler", @@ -8979,10 +8357,7 @@ } ], "description": "Événement is a very simple event dispatching library for PHP", - "keywords": [ - "event-dispatcher", - "event-emitter" - ], + "keywords": ["event-dispatcher", "event-emitter"], "support": { "issues": "https://github.com/igorw/evenement/issues", "source": "https://github.com/igorw/evenement/tree/v3.0.2" @@ -9023,25 +8398,16 @@ } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Facade\\FlareClient\\": "src" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "description": "Send PHP errors to Flare", "homepage": "https://github.com/facade/flare-client-php", - "keywords": [ - "exception", - "facade", - "flare", - "reporting" - ], + "keywords": ["exception", "facade", "flare", "reporting"], "support": { "issues": "https://github.com/facade/flare-client-php/issues", "source": "https://github.com/facade/flare-client-php/tree/1.10.0" @@ -9096,34 +8462,23 @@ "dev-master": "2.x-dev" }, "laravel": { - "providers": [ - "Facade\\Ignition\\IgnitionServiceProvider" - ], + "providers": ["Facade\\Ignition\\IgnitionServiceProvider"], "aliases": { "Flare": "Facade\\Ignition\\Facades\\Flare" } } }, "autoload": { - "files": [ - "src/helpers.php" - ], + "files": ["src/helpers.php"], "psr-4": { "Facade\\Ignition\\": "src" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "description": "A beautiful error page for Laravel applications.", "homepage": "https://github.com/facade/ignition", - "keywords": [ - "error", - "flare", - "laravel", - "page" - ], + "keywords": ["error", "flare", "laravel", "page"], "support": { "docs": "https://flareapp.io/docs/ignition-for-laravel/introduction", "forum": "https://twitter.com/flareappio", @@ -9161,9 +8516,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Freek Van der Herten", @@ -9174,11 +8527,7 @@ ], "description": "Solution contracts for Ignition", "homepage": "https://github.com/facade/ignition-contracts", - "keywords": [ - "contracts", - "flare", - "ignition" - ], + "keywords": ["contracts", "flare", "ignition"], "support": { "issues": "https://github.com/facade/ignition-contracts/issues", "source": "https://github.com/facade/ignition-contracts/tree/1.0.2" @@ -9228,20 +8577,14 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "François Zaninotto" } ], "description": "Faker is a PHP library that generates fake data for you.", - "keywords": [ - "data", - "faker", - "fixtures" - ], + "keywords": ["data", "faker", "fixtures"], "support": { "issues": "https://github.com/FakerPHP/Faker/issues", "source": "https://github.com/FakerPHP/Faker/tree/v1.23.1" @@ -9283,9 +8626,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Théo FIDRY", @@ -9293,10 +8634,7 @@ } ], "description": "Tiny utility to get the number of CPU cores.", - "keywords": [ - "CPU", - "core" - ], + "keywords": ["CPU", "core"], "support": { "issues": "https://github.com/theofidry/cpu-core-counter/issues", "source": "https://github.com/theofidry/cpu-core-counter/tree/1.2.0" @@ -9348,9 +8686,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Filipe Dobreira", @@ -9438,22 +8774,16 @@ "ext-dom": "For handling output formats in XML", "ext-mbstring": "For handling non-UTF8 characters." }, - "bin": [ - "php-cs-fixer" - ], + "bin": ["php-cs-fixer"], "type": "application", "autoload": { "psr-4": { "PhpCsFixer\\": "src/" }, - "exclude-from-classmap": [ - "src/Fixer/Internal/*" - ] + "exclude-from-classmap": ["src/Fixer/Internal/*"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -9516,18 +8846,12 @@ } }, "autoload": { - "classmap": [ - "hamcrest" - ] + "classmap": ["hamcrest"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "description": "This is the PHP port of Hamcrest Matchers", - "keywords": [ - "test" - ], + "keywords": ["test"], "support": { "issues": "https://github.com/hamcrest/hamcrest-php/issues", "source": "https://github.com/hamcrest/hamcrest-php/tree/v2.0.1" @@ -9571,9 +8895,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Alessandro Lai", @@ -9581,12 +8903,7 @@ } ], "description": "A library to get pretty versions strings of installed dependencies", - "keywords": [ - "composer", - "package", - "release", - "versions" - ], + "keywords": ["composer", "package", "release", "versions"], "support": { "issues": "https://github.com/Jean85/pretty-package-versions/issues", "source": "https://github.com/Jean85/pretty-package-versions/tree/2.0.6" @@ -9618,18 +8935,14 @@ "orchestra/testbench": "^6.0|^7.0|^8.0", "phpstan/phpstan": "^1.10" }, - "bin": [ - "bin/sail" - ], + "bin": ["bin/sail"], "type": "library", "extra": { "branch-alias": { "dev-master": "1.x-dev" }, "laravel": { - "providers": [ - "Laravel\\Sail\\SailServiceProvider" - ] + "providers": ["Laravel\\Sail\\SailServiceProvider"] } }, "autoload": { @@ -9638,9 +8951,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Taylor Otwell", @@ -9648,10 +8959,7 @@ } ], "description": "Docker files for running a basic Laravel application.", - "keywords": [ - "docker", - "laravel" - ], + "keywords": ["docker", "laravel"], "support": { "issues": "https://github.com/laravel/sail/issues", "source": "https://github.com/laravel/sail" @@ -9700,9 +9008,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Maxime Bouroumeau-Fuseau", @@ -9716,10 +9022,7 @@ ], "description": "Debug bar in the browser for php application", "homepage": "https://github.com/maximebf/php-debugbar", - "keywords": [ - "debug", - "debugbar" - ], + "keywords": ["debug", "debugbar"], "support": { "issues": "https://github.com/maximebf/php-debugbar/issues", "source": "https://github.com/maximebf/php-debugbar/tree/v1.23.2" @@ -9754,18 +9057,13 @@ }, "type": "library", "autoload": { - "files": [ - "library/helpers.php", - "library/Mockery.php" - ], + "files": ["library/helpers.php", "library/Mockery.php"], "psr-4": { "Mockery\\": "library/Mockery" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Pádraic Brady", @@ -9838,17 +9136,13 @@ }, "type": "library", "autoload": { - "files": [ - "src/DeepCopy/deep_copy.php" - ], + "files": ["src/DeepCopy/deep_copy.php"], "psr-4": { "DeepCopy\\": "src/DeepCopy/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "description": "Create deep copies (clones) of your objects", "keywords": [ "clone", @@ -9914,9 +9208,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nuno Maduro", @@ -9985,14 +9277,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Arne Blankerts", @@ -10042,14 +9330,10 @@ }, "type": "library", "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Arne Blankerts", @@ -10103,9 +9387,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Jaap van Otterdijk", @@ -10169,9 +9451,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Mike van Riel", @@ -10216,15 +9496,11 @@ "type": "library", "autoload": { "psr-4": { - "PHPStan\\PhpDocParser\\": [ - "src/" - ] + "PHPStan\\PhpDocParser\\": ["src/"] } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "description": "PHPDoc parser with support for nullable, intersection and generic types", "support": { "issues": "https://github.com/phpstan/phpdoc-parser/issues", @@ -10275,14 +9551,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -10292,11 +9564,7 @@ ], "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", "homepage": "https://github.com/sebastianbergmann/php-code-coverage", - "keywords": [ - "coverage", - "testing", - "xunit" - ], + "keywords": ["coverage", "testing", "xunit"], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", @@ -10337,14 +9605,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -10354,10 +9618,7 @@ ], "description": "FilterIterator implementation that filters files based on a list of suffixes.", "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", - "keywords": [ - "filesystem", - "iterator" - ], + "keywords": ["filesystem", "iterator"], "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" @@ -10401,14 +9662,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -10418,9 +9675,7 @@ ], "description": "Invoke callables with a timeout", "homepage": "https://github.com/sebastianbergmann/php-invoker/", - "keywords": [ - "process" - ], + "keywords": ["process"], "support": { "issues": "https://github.com/sebastianbergmann/php-invoker/issues", "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" @@ -10460,14 +9715,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -10477,9 +9728,7 @@ ], "description": "Simple template engine.", "homepage": "https://github.com/sebastianbergmann/php-text-template/", - "keywords": [ - "template" - ], + "keywords": ["template"], "support": { "issues": "https://github.com/sebastianbergmann/php-text-template/issues", "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" @@ -10519,14 +9768,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -10536,9 +9781,7 @@ ], "description": "Utility class for timing", "homepage": "https://github.com/sebastianbergmann/php-timer/", - "keywords": [ - "timer" - ], + "keywords": ["timer"], "support": { "issues": "https://github.com/sebastianbergmann/php-timer/issues", "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" @@ -10598,9 +9841,7 @@ "ext-soap": "To be able to generate mocks based on WSDL files", "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" }, - "bin": [ - "phpunit" - ], + "bin": ["phpunit"], "type": "library", "extra": { "branch-alias": { @@ -10608,17 +9849,11 @@ } }, "autoload": { - "files": [ - "src/Framework/Assert/Functions.php" - ], - "classmap": [ - "src/" - ] + "files": ["src/Framework/Assert/Functions.php"], + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -10628,11 +9863,7 @@ ], "description": "The PHP Unit Testing framework.", "homepage": "https://phpunit.de/", - "keywords": [ - "phpunit", - "testing", - "xunit" - ], + "keywords": ["phpunit", "testing", "xunit"], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", @@ -10682,9 +9913,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Christian Lück", @@ -10708,12 +9937,7 @@ } ], "description": "Async, Promise-based cache interface for ReactPHP", - "keywords": [ - "cache", - "caching", - "promise", - "reactphp" - ], + "keywords": ["cache", "caching", "promise", "reactphp"], "support": { "issues": "https://github.com/reactphp/cache/issues", "source": "https://github.com/reactphp/cache/tree/v1.2.0" @@ -10758,9 +9982,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Christian Lück", @@ -10784,11 +10006,7 @@ } ], "description": "Event-driven library for executing child processes with ReactPHP.", - "keywords": [ - "event-driven", - "process", - "reactphp" - ], + "keywords": ["event-driven", "process", "reactphp"], "support": { "issues": "https://github.com/reactphp/child-process/issues", "source": "https://github.com/reactphp/child-process/tree/v0.6.5" @@ -10837,9 +10055,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Christian Lück", @@ -10863,12 +10079,7 @@ } ], "description": "Async DNS resolver for ReactPHP", - "keywords": [ - "async", - "dns", - "dns-resolver", - "reactphp" - ], + "keywords": ["async", "dns", "dns-resolver", "reactphp"], "support": { "issues": "https://github.com/reactphp/dns/issues", "source": "https://github.com/reactphp/dns/tree/v1.13.0" @@ -10911,9 +10122,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Christian Lück", @@ -10937,10 +10146,7 @@ } ], "description": "ReactPHP's core reactor event loop that libraries can use for evented I/O.", - "keywords": [ - "asynchronous", - "event-loop" - ], + "keywords": ["asynchronous", "event-loop"], "support": { "issues": "https://github.com/reactphp/event-loop/issues", "source": "https://github.com/reactphp/event-loop/tree/v1.5.0" @@ -10976,17 +10182,13 @@ }, "type": "library", "autoload": { - "files": [ - "src/functions_include.php" - ], + "files": ["src/functions_include.php"], "psr-4": { "React\\Promise\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Jan Sorgalla", @@ -11010,10 +10212,7 @@ } ], "description": "A lightweight implementation of CommonJS Promises/A for PHP", - "keywords": [ - "promise", - "promises" - ], + "keywords": ["promise", "promises"], "support": { "issues": "https://github.com/reactphp/promise/issues", "source": "https://github.com/reactphp/promise/tree/v3.2.0" @@ -11061,9 +10260,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Christian Lück", @@ -11087,13 +10284,7 @@ } ], "description": "Async, streaming plaintext TCP/IP and secure TLS socket server and client connections for ReactPHP", - "keywords": [ - "Connection", - "Socket", - "async", - "reactphp", - "stream" - ], + "keywords": ["Connection", "Socket", "async", "reactphp", "stream"], "support": { "issues": "https://github.com/reactphp/socket/issues", "source": "https://github.com/reactphp/socket/tree/v1.16.0" @@ -11136,9 +10327,7 @@ } }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Christian Lück", @@ -11980,9 +11169,7 @@ }, "type": "metapackage", "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Marco Pivetta", @@ -11996,9 +11183,7 @@ } ], "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it", - "keywords": [ - "dev" - ], + "keywords": ["dev"], "support": { "issues": "https://github.com/Roave/SecurityAdvisories/issues", "source": "https://github.com/Roave/SecurityAdvisories/tree/latest" @@ -12042,14 +11227,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12098,14 +11279,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12154,14 +11331,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12211,14 +11384,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12239,11 +11408,7 @@ ], "description": "Provides the functionality to compare PHP values for equality", "homepage": "https://github.com/sebastianbergmann/comparator", - "keywords": [ - "comparator", - "compare", - "equality" - ], + "keywords": ["comparator", "compare", "equality"], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.8" @@ -12284,14 +11449,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12341,14 +11502,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12361,12 +11518,7 @@ ], "description": "Diff implementation", "homepage": "https://github.com/sebastianbergmann/diff", - "keywords": [ - "diff", - "udiff", - "unidiff", - "unified diff" - ], + "keywords": ["diff", "udiff", "unidiff", "unified diff"], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", "source": "https://github.com/sebastianbergmann/diff/tree/4.0.6" @@ -12409,14 +11561,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12425,11 +11573,7 @@ ], "description": "Provides functionality to handle HHVM/PHP environments", "homepage": "http://www.github.com/sebastianbergmann/environment", - "keywords": [ - "Xdebug", - "environment", - "hhvm" - ], + "keywords": ["Xdebug", "environment", "hhvm"], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", "source": "https://github.com/sebastianbergmann/environment/tree/5.1.5" @@ -12471,14 +11615,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12503,10 +11643,7 @@ ], "description": "Provides the functionality to export PHP variables for visualization", "homepage": "https://www.github.com/sebastianbergmann/exporter", - "keywords": [ - "export", - "exporter" - ], + "keywords": ["export", "exporter"], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.6" @@ -12552,14 +11689,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12568,9 +11701,7 @@ ], "description": "Snapshotting of global state", "homepage": "http://www.github.com/sebastianbergmann/global-state", - "keywords": [ - "global state" - ], + "keywords": ["global state"], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.7" @@ -12611,14 +11742,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12669,14 +11796,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12724,14 +11847,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12779,14 +11898,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12842,14 +11957,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12896,14 +12007,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -12949,14 +12056,10 @@ } }, "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Sebastian Bergmann", @@ -13005,14 +12108,10 @@ "psr-4": { "Symfony\\Component\\Filesystem\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -13067,14 +12166,10 @@ "psr-4": { "Symfony\\Component\\OptionsResolver\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -13087,11 +12182,7 @@ ], "description": "Provides an improved replacement for the array_replace PHP function", "homepage": "https://symfony.com", - "keywords": [ - "config", - "configuration", - "options" - ], + "keywords": ["config", "configuration", "options"], "support": { "source": "https://github.com/symfony/options-resolver/tree/v7.1.1" }, @@ -13136,20 +12227,14 @@ } }, "autoload": { - "files": [ - "bootstrap.php" - ], + "files": ["bootstrap.php"], "psr-4": { "Symfony\\Polyfill\\Php81\\": "" }, - "classmap": [ - "Resources/stubs" - ] + "classmap": ["Resources/stubs"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Nicolas Grekas", @@ -13162,12 +12247,7 @@ ], "description": "Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions", "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], + "keywords": ["compatibility", "polyfill", "portable", "shim"], "support": { "source": "https://github.com/symfony/polyfill-php81/tree/v1.31.0" }, @@ -13210,14 +12290,10 @@ "psr-4": { "Symfony\\Component\\Stopwatch\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -13274,22 +12350,16 @@ "require-dev": { "symfony/console": "^5.4|^6.0|^7.0" }, - "bin": [ - "Resources/bin/yaml-lint" - ], + "bin": ["Resources/bin/yaml-lint"], "type": "library", "autoload": { "psr-4": { "Symfony\\Component\\Yaml\\": "" }, - "exclude-from-classmap": [ - "/Tests/" - ] + "exclude-from-classmap": ["/Tests/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], + "license": ["MIT"], "authors": [ { "name": "Fabien Potencier", @@ -13343,14 +12413,10 @@ }, "type": "library", "autoload": { - "classmap": [ - "src/" - ] + "classmap": ["src/"] }, "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], + "license": ["BSD-3-Clause"], "authors": [ { "name": "Arne Blankerts", diff --git a/database/factories/TaxonomyFactory.php b/database/factories/TaxonomyFactory.php new file mode 100644 index 00000000..536a6e0d --- /dev/null +++ b/database/factories/TaxonomyFactory.php @@ -0,0 +1,54 @@ + $this->faker->unique()->lexify('????'), + 'name' => $this->faker->word, + 'description' => $this->faker->sentence, + 'properties' => json_encode([ + [ + 'code' => 'country_name', + 'name' => 'Country', + 'data_type' => 'string' + ], + [ + 'code' => 'country_code', + 'name' => 'Country Code', + 'data_type' => 'number' + ], + [ + 'code' => 'visible', + 'name' => 'Visibility', + 'data_type' => 'boolean' + ] + ]), + 'created_by' => 1, + 'updated_by' => 1, + 'created_at' => now(), + 'updated_at' => now(), + ]; + } +} diff --git a/database/factories/TaxonomyTermFactory.php b/database/factories/TaxonomyTermFactory.php new file mode 100644 index 00000000..117d2123 --- /dev/null +++ b/database/factories/TaxonomyTermFactory.php @@ -0,0 +1,47 @@ + $this->faker->unique()->lexify('????'), + 'name' => $this->faker->word, + 'taxonomy_id' => \App\Domains\Taxonomy\Models\Taxonomy::factory(), + 'parent_id' => null, + 'metadata' => json_encode([ + [ + 'code' => 'country_name', + 'value' => $this->faker->country + ], + [ + 'code' => 'country_code', + 'value' => $this->faker->optional()->randomNumber(2, true) + ], + [ + 'code' => 'visible', + 'value' => $this->faker->boolean + ] + ]), + 'created_by' => User::inRandomOrder()->first()->id, + 'updated_by' => User::inRandomOrder()->first()->id, + 'created_at' => now(), + 'updated_at' => now(), + ]; + } +} diff --git a/database/migrations/2024_10_11_120037_create_taxonomies_table.php b/database/migrations/2024_10_11_120037_create_taxonomies_table.php new file mode 100644 index 00000000..83a809ff --- /dev/null +++ b/database/migrations/2024_10_11_120037_create_taxonomies_table.php @@ -0,0 +1,37 @@ +id(); + $table->string('code', 32)->unique(); + $table->string('name', 191); + $table->string('description')->nullable(); + $table->json('properties'); + $table->foreignId('created_by')->nullable()->constrained('users')->onUpdate('cascade')->onDelete('set null'); + $table->foreignId('updated_by')->nullable()->constrained('users')->onUpdate('cascade')->onDelete('set null'); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('taxonomies'); + } +} diff --git a/database/migrations/2024_10_12_085403_create_taxonomy_terms_table.php b/database/migrations/2024_10_12_085403_create_taxonomy_terms_table.php new file mode 100644 index 00000000..d8f0f4df --- /dev/null +++ b/database/migrations/2024_10_12_085403_create_taxonomy_terms_table.php @@ -0,0 +1,38 @@ +id(); + $table->string('code', 32)->unique(); + $table->string('name', 191); + $table->foreignId('taxonomy_id')->constrained('taxonomies'); + $table->foreignId('parent_id')->nullable()->constrained('taxonomy_terms'); + $table->json('metadata'); + $table->foreignId('created_by')->nullable()->constrained('users')->onUpdate('cascade')->onDelete('set null'); + $table->foreignId('updated_by')->nullable()->constrained('users')->onUpdate('cascade')->onDelete('set null'); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('taxonomy_terms'); + } +} diff --git a/database/seeders/DatabaseSeeder.php b/database/seeders/DatabaseSeeder.php index eeeabdc4..8496c5f2 100644 --- a/database/seeders/DatabaseSeeder.php +++ b/database/seeders/DatabaseSeeder.php @@ -35,6 +35,8 @@ public function run() $this->call(EventSeeder::class); $this->call(SemesterSeeder::class); $this->call(CourseSeeder::class); + $this->call(TaxonomySeeder::class); + $this->call(TaxonomyTermSeeder::class); } Model::reguard(); diff --git a/database/seeders/TaxonomySeeder.php b/database/seeders/TaxonomySeeder.php new file mode 100644 index 00000000..c1ba8231 --- /dev/null +++ b/database/seeders/TaxonomySeeder.php @@ -0,0 +1,49 @@ + [ + 'code' => 'intranet', + 'name' => 'CE Intranet', + 'description' => 'This manages the intranet links shown in https://www.ce.pdn.ac.lk/intranet', + 'properties' => [ + ['code' => 'link', 'name' => 'Link', 'data_type' => 'url'] + ], + ], + 'students' => [ + 'code' => 'students', + 'name' => 'Students', + 'description' => 'This taxonomy manages the list of student batches in the Department', + 'properties' => [ + ['code' => 'start_date', 'name' => 'Academic Start Date', 'data_type' => 'date'], + ['code' => 'end_date', 'name' => 'Academic End Date', 'data_type' => 'date'], + ['code' => 'profiles_page', 'name' => 'Profiles Page', 'data_type' => 'url'], + ['code' => 'notes', 'name' => 'Notes', 'data_type' => 'string'] + ], + ] + ]; + + foreach ($taxonomies as $key => $taxonomy) { + Taxonomy::create([ + 'code' => $taxonomy['code'], + 'name' => $taxonomy['name'], + 'description' => $taxonomy['description'], + 'properties' => json_encode($taxonomy['properties']), + 'created_by' => 1, + 'updated_by' => 1 + ]); + } + } + +} \ No newline at end of file diff --git a/database/seeders/TaxonomyTermSeeder.php b/database/seeders/TaxonomyTermSeeder.php new file mode 100644 index 00000000..cc1d0b0b --- /dev/null +++ b/database/seeders/TaxonomyTermSeeder.php @@ -0,0 +1,201 @@ +first()->id; + $studentsId = Taxonomy::where('code', 'students')->first()->id; + + // Intranet taxonomy terms + $intranetTerms = [ + 'students' => [ + 'code' => 'students', + 'name' => 'For Students', + 'metadata' => [['code' => 'link', 'value' => null]], + 'children' => [ + [ + 'code' => 'academic_calendar', + 'name' => 'Academic Calendar', + 'metadata' => [['code' => 'link', 'value' => 'https://docs.google.com/document/d/e/2PACX-1vR-EkodNirStWpMfHr1pZcivrPJ_usJRJV2-36o0aa8F6VHgwbr0xZVswd8x5fk3RZN0uLGZILSjsdW/pub']] + ], + [ + 'code' => 'timetables', + 'name' => 'Timetables', + 'metadata' => [['code' => 'link', 'value' => 'https://docs.google.com/document/d/e/2PACX-1vRp4MEjiFOZuvkPFd3_emXj6pPTxM91RF6Ilhn5CX7fRaj_dG6hDKa17ykQ5thIFpmzLLUC78bxbkn1/pub']] + ], + [ + 'code' => 'examination_schedules', + 'name' => 'Examination Schedules', + 'metadata' => [['code' => 'link', 'value' => 'https://docs.google.com/document/d/e/2PACX-1vRULmmwk1-6KQQVYkBWmIJNOliC-H1O2DJGPqlfI2vyHgzjo9IHS7AoeVPW9RoxnQn8_cLqOmkXrkFy/pub']] + ], + [ + 'code' => 'advisor_advisee', + 'name' => 'Advisor-Advisee', + 'metadata' => [['code' => 'link', 'value' => 'https://docs.google.com/spreadsheets/d/1r0A0kh6xtSxPt3wkcKYsHQLoWKG_XNYEyvAtDBPM-Xs/edit#gid=652951330']] + ] + ] + ], + 'staff' => [ + 'code' => 'staff', + 'name' => 'For Staff', + 'metadata' => [['code' => 'link', 'value' => null]], + 'children' => [ + [ + 'code' => 'exam_claim', + 'name' => 'Exam Claim Application', + 'metadata' => [['code' => 'link', 'value' => 'https://docs.google.com/document/u/2/d/e/2PACX-1vRJh5v40ChLsmR1iAfFGMEnjtzs4nef19JI7OymUMCBca6ybFiUtk43EqDG3I26rUJz3xyOODECHZ-I/pub?urp=gmail_link']] + ], + [ + 'code' => 'examination_progress', + 'name' => 'Examination Progress', + 'metadata' => [['code' => 'link', 'value' => 'https://docs.google.com/document/d/1n0l0YJwfeVv9cCpcq2N1ptIoDCEE339CjWqCaOKYC0I/edit']] + ], + [ + 'code' => 'work_allocation', + 'name' => 'Work Allocation', + 'metadata' => [['code' => 'link', 'value' => 'https://docs.google.com/document/d/e/2PACX-1vQw6ubwr36kpNVleJQaanrM6c2yXTh6eF79BHw37bkqzgTXzMv4NKPdOTY4XoWfqkaduQLRAjQohFR6/pub']] + ], + [ + 'code' => 'department_meeting_minutes', + 'name' => 'Department Meeting Minutes', + 'metadata' => [['code' => 'link', 'value' => 'https://docs.google.com/document/d/1YG9-amXUAgHCmqfWU85pg35yPpeG5eBO-YHPADem7N8/edit?usp=sharing']] + ] + ] + ] + ]; + + // Students taxonomy terms + $studentsTerms = [ + 'undergraduate' => [ + 'code' => 'undergraduate', + 'name' => 'Undergraduate Students', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/'), + 'children' => [ + [ + 'code' => 'e20', + 'name' => 'E20', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e20/', null, '2022-05-30') + ], + [ + 'code' => 'e19', + 'name' => 'E19', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e19/') + ], + [ + 'code' => 'e18', + 'name' => 'E18', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e18/') + ] + ] + ], + 'postgraduate_students' => [ + 'code' => 'postgraduate_students', + 'name' => 'Postgraduate Students', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/postgraduate/') + ], + 'undergraduate_alumni' => [ + 'code' => 'undergraduate_alumni', + 'name' => 'Alumni Students', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/alumni/', 'Only undergraduate batches'), + 'children' => [ + [ + 'code' => 'e17', + 'name' => 'E17', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e17/') + ], + [ + 'code' => 'e16', + 'name' => 'E16', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e16/') + ], + [ + 'code' => 'e15', + 'name' => 'E15', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e15/', null, '2016-11-16', '2021-09-03') + ], + [ + 'code' => 'e14', + 'name' => 'E14', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e14/') + ], + [ + 'code' => 'e13', + 'name' => 'E13', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e13/') + ], + [ + 'code' => 'e12', + 'name' => 'E12', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e12/') + ], + [ + 'code' => 'e11', + 'name' => 'E11', + 'metadata' => $this->createStudentMetadata('https://people.ce.pdn.ac.lk/students/e11/') + ] + ] + ] + ]; + + $this->createTermsWithChildren($intranetTerms, $intranetId); + $this->createTermsWithChildren($studentsTerms, $studentsId); + } + + /** + * Helper function to create student metadata + */ + private function createStudentMetadata($profilesPage, $notes = null, $startDate = null, $endDate = null) + { + return [ + ['code' => 'start_date', 'value' => $startDate], + ['code' => 'end_date', 'value' => $endDate], + ['code' => 'profiles_page', 'value' => $profilesPage], + ['code' => 'notes', 'value' => $notes] + ]; + } + + /** + * Helper function to create terms with their children + */ + private function createTermsWithChildren($terms, $taxonomyId, $parentId = null) + { + foreach ($terms as $term) { + $createdTerm = TaxonomyTerm::create([ + 'code' => $term['code'], + 'name' => $term['name'], + 'taxonomy_id' => $taxonomyId, + 'parent_id' => $parentId, + 'metadata' => json_encode($term['metadata']), + 'created_by' => 1, + 'updated_by' => 1 + ]); + + if (isset($term['children'])) { + foreach ($term['children'] as $child) { + TaxonomyTerm::create([ + 'code' => $child['code'], + 'name' => $child['name'], + 'taxonomy_id' => $taxonomyId, + 'parent_id' => $createdTerm->id, + 'metadata' => json_encode($child['metadata']), + 'created_by' => 1, + 'updated_by' => 1 + ]); + } + } + } + } +} diff --git a/resources/sass/backend/app.scss b/resources/sass/backend/app.scss index 587d91b1..aa7b99db 100644 --- a/resources/sass/backend/app.scss +++ b/resources/sass/backend/app.scss @@ -117,3 +117,7 @@ .btn-w-150 { min-width: 150px !important; } + +[x-cloak] { + display: none !important; +} diff --git a/resources/views/backend/includes/sidebar.blade.php b/resources/views/backend/includes/sidebar.blade.php index 22c166e8..b83092db 100644 --- a/resources/views/backend/includes/sidebar.blade.php +++ b/resources/views/backend/includes/sidebar.blade.php @@ -127,6 +127,22 @@ class="c-sidebar-nav-dropdown {{ activeClass(Route::is('dashboard.semesters.*') @endif + + {{-- Taxonomies --}} + @if ($logged_in_user->hasAllAccess()) +
  • + + +
      +
    • + +
    • +
    +
  • + @endif + + @endif + + + + + +@endsection diff --git a/resources/views/backend/taxonomy/terms/create.blade.php b/resources/views/backend/taxonomy/terms/create.blade.php new file mode 100644 index 00000000..9f78eb7b --- /dev/null +++ b/resources/views/backend/taxonomy/terms/create.blade.php @@ -0,0 +1,150 @@ + + +@extends('backend.layouts.app') + +@section('title', __('Create Taxonomy Term')) + +@section('content') +
    + + + + +
    + @csrf + +
    + +
    + Term Configurations +
    + + +
    +
    + +
    + +
    + {!! Form::text('taxonomy_name', $taxonomy->name, ['class' => 'form-control', 'readonly']) !!} + {!! Form::hidden('taxonomy_id', $taxonomy->id, ['class' => 'form-control', 'readonly']) !!} +
    +
    + + +
    +
    + +
    + +
    + + +
    +
    + +
    +
    + {!! Form::text('code', '', ['class' => 'form-control']) !!} +
    +
    + + +
    +
    + +
    +
    + {!! Form::text('name', '', ['class' => 'form-control']) !!} +
    +
    +
    + + + + + + + {!! Form::submit('Create', ['class' => 'btn btn-primary btn-w-150 float-right', 'id' => 'submit-button']) !!} + + + + +
    +@endsection diff --git a/resources/views/backend/taxonomy/terms/delete.blade.php b/resources/views/backend/taxonomy/terms/delete.blade.php new file mode 100644 index 00000000..ff1c1252 --- /dev/null +++ b/resources/views/backend/taxonomy/terms/delete.blade.php @@ -0,0 +1,45 @@ +@extends('backend.layouts.app') + +@section('title', __('Delete Taxonomy Term')) + +@section('content') +
    + + + Taxonomy Term: Delete | {{ $term->id }} + + + +

    Are you sure you want to delete + "{{ $term->name }}" ? +

    + + @if ($term->children()->count() > 0) +

    The following terms are linked to this Taxonomy Term, and will be deleted with this.

    + + @endif + +
    + {!! Form::open([ + 'url' => route('dashboard.taxonomy.terms.destroy', ['taxonomy' => $taxonomy, 'term' => $term]), + 'method' => 'delete', + 'class' => 'container', + ]) !!} + + Back + {!! Form::submit('Delete', ['class' => 'btn btn-danger']) !!} + + {!! Form::close() !!} +
    +
    +
    +
    +@endsection diff --git a/resources/views/backend/taxonomy/terms/edit.blade.php b/resources/views/backend/taxonomy/terms/edit.blade.php new file mode 100644 index 00000000..ee49bd38 --- /dev/null +++ b/resources/views/backend/taxonomy/terms/edit.blade.php @@ -0,0 +1,180 @@ + + +@extends('backend.layouts.app') + +@section('title', __('Edit Taxonomy Term')) + +@section('content') +
    + + + + @csrf + @method('PUT') + +
    +
    + Term Configurations +
    + + +
    +
    + +
    +
    + {!! Form::text('taxonomy_name', $taxonomy->name, ['class' => 'form-control', 'readonly']) !!} + {!! Form::hidden('taxonomy_id', $taxonomy->id, ['class' => 'form-control', 'readonly']) !!} +
    +
    + + +
    +
    + +
    + + @error('parent_id') +
    {{ $message }}
    + @enderror +
    + + +
    +
    + +
    +
    + {!! Form::text('code', old('code', $term->code), ['class' => 'form-control']) !!} + @error('code') +
    {{ $message }}
    + @enderror +
    +
    + + +
    +
    + +
    +
    + {!! Form::text('name', old('name', $term->name), ['class' => 'form-control']) !!} + @error('name') +
    {{ $message }}
    + @enderror +
    +
    +
    + + + +
    + + + {!! Form::submit('Update', ['class' => 'btn btn-primary btn-w-150 float-right', 'id' => 'submit-button']) !!} + + +
    + +
    +@endsection diff --git a/resources/views/backend/taxonomy/terms/index-table-row.blade.php b/resources/views/backend/taxonomy/terms/index-table-row.blade.php new file mode 100644 index 00000000..769c6744 --- /dev/null +++ b/resources/views/backend/taxonomy/terms/index-table-row.blade.php @@ -0,0 +1,61 @@ + + + + {{ $row->name }} + + + + {{ $row->code }} + + + + @if ($row->parent_id != null) + + {{ $row->parent->name }} + + @else + N/A + @endif + + + + {{ $row->user_created->name ?? 'N/A' }} + + + + {{ $row->user_updated->name ?? 'N/A' }} + + + + {{ $row->created_at }} + + + + {{ $row->updated_at }} + + + +
    +
    + + @if ($row->parent_id == null) + + + + @endif + + + + + + + + + + + +
    +
    +
    diff --git a/resources/views/backend/taxonomy/terms/index.blade.php b/resources/views/backend/taxonomy/terms/index.blade.php new file mode 100644 index 00000000..f8a06992 --- /dev/null +++ b/resources/views/backend/taxonomy/terms/index.blade.php @@ -0,0 +1,31 @@ +@extends('backend.layouts.app') + +@section('title', __('Taxonomy Terms')) + +@section('content') +
    + + + Taxonomy Terms: {{ $taxonomy->name }} + + + + + + + + + @if (session('Success')) +
    + {{ session('Success') }} + +
    + @endif + + +
    +
    +
    +@endsection diff --git a/resources/views/backend/taxonomy/view.blade.php b/resources/views/backend/taxonomy/view.blade.php new file mode 100644 index 00000000..aec929f6 --- /dev/null +++ b/resources/views/backend/taxonomy/view.blade.php @@ -0,0 +1,23 @@ +@extends('backend.layouts.app') + +@section('title', __('View Taxonomy')) + +@section('content') + +
    + +

    Taxonomy: {{ $taxonomyData['name'] }} ({{ $taxonomyData['code'] }})

    + +

    API Endpoint: + + {{ route('api.taxonomy.get', ['taxonomy_code' => $taxonomyData['code']]) }} + +

    + +

    Terms:

    +
    +{{ json_encode($taxonomyData['terms'], JSON_PRETTY_PRINT) }}
    +        
    +
    + +@endsection diff --git a/resources/views/components/backend/taxonomy_property_adder.blade.php b/resources/views/components/backend/taxonomy_property_adder.blade.php new file mode 100644 index 00000000..cf2570ff --- /dev/null +++ b/resources/views/components/backend/taxonomy_property_adder.blade.php @@ -0,0 +1,187 @@ +@php + $propertyTypes = \App\Domains\Taxonomy\Models\Taxonomy::$propertyType; +@endphp +
    +
    + + + +
    + + + + + +
      + +
    +
    diff --git a/resources/views/frontend/pages/contributors.blade.php b/resources/views/frontend/pages/contributors.blade.php index 6ea70f55..f4580581 100644 --- a/resources/views/frontend/pages/contributors.blade.php +++ b/resources/views/frontend/pages/contributors.blade.php @@ -10,7 +10,7 @@ -

    Project {{ $key + 1 }} {{ $project['title'] }}

    +

    Project #{{ $key + 1 }} {{ $project['title'] }}

    {{ $project['description'] }}

      diff --git a/resources/views/livewire/backend/event-item-table.blade.php b/resources/views/livewire/backend/event-item-table.blade.php deleted file mode 100644 index 7a4f2102..00000000 --- a/resources/views/livewire/backend/event-item-table.blade.php +++ /dev/null @@ -1,3 +0,0 @@ -
      - {{-- Do your work, then step back. --}} -
      diff --git a/routes/api.php b/routes/api.php index 4b15fea4..4b8af9b2 100644 --- a/routes/api.php +++ b/routes/api.php @@ -4,6 +4,7 @@ use App\Http\Controllers\API\EventApiController; use App\Http\Controllers\API\CourseApiController; use App\Http\Controllers\API\SemesterApiController; +use App\Http\Controllers\API\TaxonomyApiController; Route::group(['prefix' => 'news/v1', 'as' => 'api.news.'], function () { Route::get('/', [NewsApiController::class, 'index']); @@ -22,4 +23,14 @@ Route::get('/semesters', [SemesterApiController::class, 'index']); }); -// TODO: Implement postgraduate courses API \ No newline at end of file +// TODO: Implement postgraduate courses API + + +Route::group(['prefix' => 'taxonomy/v1/', 'as' => 'api.taxonomy.'], function () { + Route::get('/', [TaxonomyApiController::class, 'index'])->name('index'); + Route::get('/{taxonomy_code}', [TaxonomyApiController::class, 'get_taxonomy'])->name('get'); + Route::get( + 'term/{term_code}', + [TaxonomyApiController::class, 'get_term'] + )->name('term.get'); +}); \ No newline at end of file diff --git a/routes/backend/taxonomy.php b/routes/backend/taxonomy.php new file mode 100644 index 00000000..57670b58 --- /dev/null +++ b/routes/backend/taxonomy.php @@ -0,0 +1,127 @@ +name('taxonomy.index') + ->breadcrumbs(function (Trail $trail) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')); + }); + + // Create + Route::get('taxonomy/create', [TaxonomyController::class, 'create']) + ->name('taxonomy.create') + ->breadcrumbs(function (Trail $trail) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')) + ->push(__('Create')); + }); + + // Store + Route::post('taxonomy', [TaxonomyController::class, 'store']) + ->name('taxonomy.store'); + + // Edit + Route::get('taxonomy/edit/{taxonomy}', [TaxonomyController::class, 'edit']) + ->name('taxonomy.edit') + ->breadcrumbs(function (Trail $trail, $taxonomy) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')) + ->push($taxonomy->name) + ->push(__('Edit'), route('dashboard.taxonomy.edit', $taxonomy)); + }); + + // Update + Route::put('taxonomy/{taxonomy}', [TaxonomyController::class, 'update']) + ->name('taxonomy.update'); + + // Delete + Route::get('taxonomy/delete/{taxonomy}', [TaxonomyController::class, 'delete']) + ->name('taxonomy.delete') + ->breadcrumbs(function (Trail $trail, $taxonomy) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')) + ->push($taxonomy->name) + ->push(__('Delete')); + }); + + + // View + Route::get('taxonomy/view/{taxonomy}', [TaxonomyController::class, 'view']) + ->name('taxonomy.view')->breadcrumbs(function (Trail $trail, $taxonomy) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')) + ->push($taxonomy->name) + ->push(__('View')); + }); + + // Destroy + Route::delete('taxonomy/{taxonomy}', [TaxonomyController::class, 'destroy']) + ->name('taxonomy.destroy'); + + //Taxonomy Term Routes + Route::group(['prefix' => 'taxonomy/{taxonomy}/terms'], function () { + + // Index (list terms for a taxonomy) + Route::get('/', [TaxonomyTermController::class, 'index'])->name('taxonomy.terms.index') + ->breadcrumbs(function (Trail $trail, $taxonomy) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')) + ->push($taxonomy->name, route('dashboard.taxonomy.edit', $taxonomy)) + ->push(__('Terms'), route('dashboard.taxonomy.terms.index', $taxonomy)); + }); + + // Create (show form for creating a new term) + Route::get('/create', [TaxonomyTermController::class, 'create']) + ->name('taxonomy.terms.create') + ->breadcrumbs(function (Trail $trail, $taxonomy) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')) + ->push($taxonomy->name, route('dashboard.taxonomy.edit', $taxonomy)) + ->push(__('Terms'), route('dashboard.taxonomy.terms.index', $taxonomy)) + ->push(__('Create Term')); + }); + + // Store (store a new term in the taxonomy) + Route::post('/', [TaxonomyTermController::class, 'store']) + ->name('taxonomy.terms.store'); + + // Edit (show form for editing a term) + Route::get('/edit/{term}', [TaxonomyTermController::class, 'edit']) + ->name('taxonomy.terms.edit') + ->breadcrumbs(function (Trail $trail, $taxonomy, $term) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')) + ->push($taxonomy->name, route('dashboard.taxonomy.edit', $taxonomy)) + ->push(__('Terms'), route('dashboard.taxonomy.terms.index', $taxonomy)) + ->push(__('Edit Term')); + }); + + // Update (update a term in the taxonomy) + Route::put('/{term}', [TaxonomyTermController::class, 'update']) + ->name('taxonomy.terms.update'); + + // Delete (show confirmation for deleting a term) + Route::get('/delete/{term}', [TaxonomyTermController::class, 'delete']) + ->name('taxonomy.terms.delete') + ->breadcrumbs(function (Trail $trail, $taxonomy, $term) { + $trail->push(__('Home'), route('dashboard.home')) + ->push(__('Taxonomy'), route('dashboard.taxonomy.index')) + ->push($taxonomy->name, route('dashboard.taxonomy.edit', $taxonomy)) + ->push(__('Terms'), route('dashboard.taxonomy.terms.index', $taxonomy)) + ->push(__('Delete Term')); + }); + + // Destroy (delete a term from the taxonomy) + Route::delete('/{term}', [TaxonomyTermController::class, 'destroy']) + ->name('taxonomy.terms.destroy'); + }); +}); \ No newline at end of file diff --git a/scripts/deploy-prod.sh b/scripts/deploy-prod.sh index b54955a8..845b2fea 100644 --- a/scripts/deploy-prod.sh +++ b/scripts/deploy-prod.sh @@ -34,10 +34,10 @@ php artisan view:cache echo "Running: Setting permissions" sudo chown -R www-data:www-data ./ -# Set directory permissions to 755 (rwxr-x--x) +# Set directory permissions to 751 (rwxr-x--x) sudo find ./ -type d -exec chmod 751 {} \; -# Set file permissions to 644 (rwxr-----) +# Set file permissions to 740 (rwxr-----) sudo find ./ -type f -exec chmod 740 {} \; # Ensure storage and cache directories are writable