This repository was archived by the owner on Feb 14, 2026. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +10
-4
lines changed
Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Original file line number Diff line number Diff line change 22
33namespace CodeWithDennis \FilamentTests \Concerns \Resources ;
44
5+ use Filament \Resources \Pages \EditRecord ;
6+ use Filament \Resources \Pages \ViewRecord ;
57use Filament \Schemas \Schema ;
68
79trait InteractsWithSchemas
810{
911 public function getResourceForm (): Schema
1012 {
11- return $ this ->getResource ()->form (new Schema );
13+ return $ this ->getResource ()->form (new Schema (
14+ app ('livewire ' )->new (EditRecord::class)
15+ ));
1216 }
1317
1418 public function getResourceInfolist (): Schema
1519 {
16- return $ this ->getResource ()->infolist (new Schema );
20+ return $ this ->getResource ()->infolist (new Schema (
21+ app ('livewire ' )->new (ViewRecord::class)
22+ ));
1723 }
1824
1925 public function getResourceInfolistFields (): array
2026 {
21- return $ this ->getResourceInfolist ()->getFlatFields ();
27+ return $ this ->getResourceInfolist ()->getFlatFields (true );
2228 }
2329
2430 public function getResourceFormFields (): array
2531 {
26- return $ this ->getResourceForm ()->getFlatFields ();
32+ return $ this ->getResourceForm ()->getFlatFields (true );
2733 }
2834}
You can’t perform that action at this time.
0 commit comments