From 5ccbbf565c568d7d5e5afcdb53aab7e42d91563d Mon Sep 17 00:00:00 2001 From: Dedan Irungu Date: Sat, 12 Aug 2023 16:54:43 +0300 Subject: [PATCH] change relationship to an array from string --- Entities/Partner.php | 6 +++--- Entities/Slug.php | 6 +++--- Entities/TypeRelation.php | 12 ++++++------ 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/Entities/Partner.php b/Entities/Partner.php index 0a1f59c..4569b6b 100755 --- a/Entities/Partner.php +++ b/Entities/Partner.php @@ -55,7 +55,7 @@ public function listTable(): ListTable // listing view fields $fields = new ListTable(); - $fields->name('user_id')->type('recordpicker')->table('users')->ordering(true); + $fields->name('user_id')->type('recordpicker')->table([ 'users'])->ordering(true); return $fields; @@ -71,7 +71,7 @@ public function formBuilder(): FormBuilder // listing view fields $fields = new FormBuilder(); - $fields->name('user_id')->type('recordpicker')->table('users')->group('w-1/2'); + $fields->name('user_id')->type('recordpicker')->table([ 'users'])->group('w-1/2'); return $fields; @@ -88,7 +88,7 @@ public function filter(): FormBuilder // listing view fields $fields = new FormBuilder(); - $fields->name('user_id')->type('recordpicker')->table('users')->group('w-1/6'); + $fields->name('user_id')->type('recordpicker')->table([ 'users'])->group('w-1/6'); return $fields; diff --git a/Entities/Slug.php b/Entities/Slug.php index 0d8e42f..57731fc 100755 --- a/Entities/Slug.php +++ b/Entities/Slug.php @@ -48,7 +48,7 @@ public function listTable(): ListTable // listing view fields $fields = new ListTable(); - $fields->name('partner_id')->type('recordpicker')->table('partner')->ordering(true); + $fields->name('partner_id')->type('recordpicker')->table(['partner'])->ordering(true); $fields->name('slug')->type('text')->ordering(true); return $fields; @@ -65,7 +65,7 @@ public function formBuilder(): FormBuilder // listing view fields $fields = new FormBuilder(); - $fields->name('partner_id')->type('recordpicker')->table('partner')->group('w-1/2'); + $fields->name('partner_id')->type('recordpicker')->table(['partner'])->group('w-1/2'); $fields->name('slug')->type('text')->group('w-1/2'); return $fields; @@ -82,7 +82,7 @@ public function filter(): FormBuilder // listing view fields $fields = new FormBuilder(); - $fields->name('partner_id')->type('recordpicker')->table('partner')->group('w-1/6'); + $fields->name('partner_id')->type('recordpicker')->table(['partner'])->group('w-1/6'); $fields->name('slug')->type('text')->group('w-1/6'); return $fields; diff --git a/Entities/TypeRelation.php b/Entities/TypeRelation.php index 00dbb5d..d3b4a78 100755 --- a/Entities/TypeRelation.php +++ b/Entities/TypeRelation.php @@ -47,8 +47,8 @@ public function listTable(): ListTable // listing view fields $fields = new ListTable(); - $fields->name('partner_id')->type('recordpicker')->table('partner')->ordering(true); - $fields->name('partner_types_id')->type('recordpicker')->table('partner_types')->ordering(true); + $fields->name('partner_id')->type('recordpicker')->table(['partner'])->ordering(true); + $fields->name('partner_types_id')->type('recordpicker')->table(['partner', 'types'])->ordering(true); return $fields; @@ -64,8 +64,8 @@ public function formBuilder(): FormBuilder // listing view fields $fields = new FormBuilder(); - $fields->name('partner_id')->type('recordpicker')->table('partner')->group('w-1/2'); - $fields->name('partner_types_id')->type('recordpicker')->table('partner_types')->group('w-1/2'); + $fields->name('partner_id')->type('recordpicker')->table(['partner'])->group('w-1/2'); + $fields->name('partner_types_id')->type('recordpicker')->table(['partner', 'types'])->group('w-1/2'); return $fields; @@ -81,8 +81,8 @@ public function filter(): FormBuilder // listing view fields $fields = new FormBuilder(); - $fields->name('partner_id')->type('recordpicker')->table('partner')->group('w-1/6'); - $fields->name('partner_types_id')->type('recordpicker')->table('partner_types')->group('w-1/6'); + $fields->name('partner_id')->type('recordpicker')->table(['partner'])->group('w-1/6'); + $fields->name('partner_types_id')->type('recordpicker')->table(['partner', 'types'])->group('w-1/6'); return $fields;