We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0a2a19e commit efec6e4Copy full SHA for efec6e4
README.md
@@ -24,8 +24,10 @@ use CodeWithDennis\FilamentSelectTree\SelectTree;
24
use App\Models\Category;
25
26
SelectTree::make('category_id')
27
- // It uses the Category model to build a select tree with 'category_id' as the parent column and 'name' as the node label.
28
- ->tree(Category::class, 'category_id', 'name')
+ // Creates a select tree with 'Category' model, using 'category_id' as parent and 'name' as label, allowing custom query modification.
+ ->tree(Category::class, 'category_id', 'name', function ($query) {
29
+ return $query;
30
+ })
31
32
// Here, the label 'Category' is assigned to the field.
33
->label(__('Category'))
0 commit comments