Skip to content
This repository was archived by the owner on Feb 14, 2026. It is now read-only.

Commit 4268213

Browse files
Add methods to retrieve flat fields for resource info and form
1 parent 68583dc commit 4268213

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/Concerns/Resources/InteractsWithSchemas.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,14 @@ public function getResourceInfolist(): Schema
1515
{
1616
return $this->getResource()->infolist(new Schema);
1717
}
18+
19+
public function getResourceInfolistFields(): array
20+
{
21+
return $this->getResourceInfolist()->getFlatFields();
22+
}
23+
24+
public function getResourceFormFields(): array
25+
{
26+
return $this->getResourceForm()->getFlatFields();
27+
}
1828
}

0 commit comments

Comments
 (0)