From c1140adb217db57a323f44e7a52fa019157b5063 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andrei=20Ioni=C8=9B=C4=83?= Date: Wed, 18 Oct 2023 12:08:14 +0100 Subject: [PATCH] fix: remove profile relation managers (#113) * fix: remove profile relation managers * update resource label --- app/Filament/Resources/ProfileResource.php | 16 +--------------- .../DocumentsRelationManager.php | 16 ---------------- .../ResourcesRelationManager.php | 16 ---------------- .../RelationManagers/UsersRelationManager.php | 16 ---------------- .../VolunteersRelationManager.php | 16 ---------------- lang/ro/organisation.php | 1 + 6 files changed, 2 insertions(+), 79 deletions(-) delete mode 100644 app/Filament/Resources/ProfileResource/RelationManagers/DocumentsRelationManager.php delete mode 100644 app/Filament/Resources/ProfileResource/RelationManagers/ResourcesRelationManager.php delete mode 100644 app/Filament/Resources/ProfileResource/RelationManagers/UsersRelationManager.php delete mode 100644 app/Filament/Resources/ProfileResource/RelationManagers/VolunteersRelationManager.php diff --git a/app/Filament/Resources/ProfileResource.php b/app/Filament/Resources/ProfileResource.php index eef37ed..cad2dea 100644 --- a/app/Filament/Resources/ProfileResource.php +++ b/app/Filament/Resources/ProfileResource.php @@ -5,10 +5,6 @@ namespace App\Filament\Resources; use App\Filament\Resources\ProfileResource\Pages; -use App\Filament\Resources\ProfileResource\RelationManagers\DocumentsRelationManager; -use App\Filament\Resources\ProfileResource\RelationManagers\ResourcesRelationManager; -use App\Filament\Resources\ProfileResource\RelationManagers\UsersRelationManager; -use App\Filament\Resources\ProfileResource\RelationManagers\VolunteersRelationManager; use App\Models\Organisation; use Filament\Resources\Form; use Filament\Resources\Resource; @@ -25,7 +21,7 @@ class ProfileResource extends Resource public static function getModelLabel(): string { - return __('organisation.label.singular'); + return __('organisation.label.profile'); } public static function getPluralModelLabel(): string @@ -38,16 +34,6 @@ public static function form(Form $form): Form return OrganisationResource::form($form); } - public static function getRelations(): array - { - return [ - VolunteersRelationManager::class, - ResourcesRelationManager::class, - UsersRelationManager::class, - DocumentsRelationManager::class, - ]; - } - public static function getPages(): array { return [ diff --git a/app/Filament/Resources/ProfileResource/RelationManagers/DocumentsRelationManager.php b/app/Filament/Resources/ProfileResource/RelationManagers/DocumentsRelationManager.php deleted file mode 100644 index c278a06..0000000 --- a/app/Filament/Resources/ProfileResource/RelationManagers/DocumentsRelationManager.php +++ /dev/null @@ -1,16 +0,0 @@ -with('organisation:id,name,city_id,county_id'); - } -} diff --git a/app/Filament/Resources/ProfileResource/RelationManagers/ResourcesRelationManager.php b/app/Filament/Resources/ProfileResource/RelationManagers/ResourcesRelationManager.php deleted file mode 100644 index ab7d65d..0000000 --- a/app/Filament/Resources/ProfileResource/RelationManagers/ResourcesRelationManager.php +++ /dev/null @@ -1,16 +0,0 @@ -with('organisation:id,name,city_id,county_id'); - // } -} diff --git a/app/Filament/Resources/ProfileResource/RelationManagers/UsersRelationManager.php b/app/Filament/Resources/ProfileResource/RelationManagers/UsersRelationManager.php deleted file mode 100644 index 716d667..0000000 --- a/app/Filament/Resources/ProfileResource/RelationManagers/UsersRelationManager.php +++ /dev/null @@ -1,16 +0,0 @@ -with('organisation:id,name,city_id,county_id'); - } -} diff --git a/app/Filament/Resources/ProfileResource/RelationManagers/VolunteersRelationManager.php b/app/Filament/Resources/ProfileResource/RelationManagers/VolunteersRelationManager.php deleted file mode 100644 index 7454566..0000000 --- a/app/Filament/Resources/ProfileResource/RelationManagers/VolunteersRelationManager.php +++ /dev/null @@ -1,16 +0,0 @@ -with('organisation:id,name,city_id,county_id'); - } -} diff --git a/lang/ro/organisation.php b/lang/ro/organisation.php index da8c75b..319d077 100644 --- a/lang/ro/organisation.php +++ b/lang/ro/organisation.php @@ -6,6 +6,7 @@ 'label' => [ 'singular' => 'Organizație', 'plural' => 'Organizații', + 'profile' => 'Profil organizație', ], 'modal' => [