File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 4949 run : composer show -D
5050
5151 - name : Execute tests
52- run : vendor/bin/pest --ci --bail --compact --memory --coverage --parallel
52+ run : vendor/bin/pest --ci --bail --compact --memory --coverage
Original file line number Diff line number Diff line change @@ -281,7 +281,10 @@ public function mapTableFilter(BaseFilter $filter): array
281281 $ baseInfo ['usage ' ] = 'Please use the form schema to filter the data. ' ;
282282 $ baseInfo ['type ' ] = 'form ' ;
283283 $ baseInfo ['form ' ] = collect ($ filter ->getFormSchema ())
284+ ->reject (fn (Component $ component ) => $ component instanceof Grid || $ component instanceof Fieldset)
284285 ->map (fn (Component $ component ) => $ this ->mapFormComponent ($ component ))
286+ ->filter ()
287+ ->values ()
285288 ->all ();
286289 }
287290
Original file line number Diff line number Diff line change @@ -32,6 +32,8 @@ public function build(): PrismTool
3232 try {
3333 $ listPageClass = $ resource ::getPages ()['index ' ];
3434 $ component = $ listPageClass ->getPage ();
35+
36+ /** @var InteractsWithTable $listPage */
3537 $ listPage = new $ component ;
3638 $ listPage ->bootedInteractsWithTable ();
3739 $ table = $ listPage ->getTable ();
@@ -44,6 +46,8 @@ public function build(): PrismTool
4446 $ listPage ->tableSearch = $ filters [$ column ->getName ()];
4547 });
4648
49+ $ listPage ->resetTableFiltersForm ();
50+
4751 foreach ($ listPage ->getTable ()->getFilters () as $ filter ) {
4852 if (method_exists ($ filter , 'isMultiple ' ) && $ filter ->isMultiple ()) {
4953 $ listPage ->tableFilters [$ filter ->getName ()] = [
@@ -65,8 +69,6 @@ public function build(): PrismTool
6569 }
6670 }
6771
68- dump ($ listPage ->tableFilters , $ filters );
69-
7072 // TODO: Allow the tool to specify the number of results to return with a max
7173 $ results = $ listPage ->getFilteredTableQuery ()->take (10 )->get ();
7274
You can’t perform that action at this time.
0 commit comments