Wrong panel route name for resource

I have two panels: finance and orders. I have an OrderResource in the order panel. I defined the resource in the OrderPanelProvider via the discoverResources (->discoverResources(in: app_path('Filament/Order/Resources'), for: 'App\\Filament\\Order\\Resources') and the OrderResource is in the right namespace: namespace App\Filament\Order\Resources;. When I call the command OrderResource::getUrl('index') or for testing Livewire::test(OrderResource\Pages\ListOrders::class) then I get the Exception Illuminate\View\ViewException: Route [filament.finance.resources.orders.index] not defined.. Is there anything i am doing wrong?
Solution:
Found the solution: `` Filament::setCurrentPanel( Filament::getPanel('order'), // Where app` is the ID of the panel you want to test....
Jump to solution
1 Reply
Solution
Gert Timmerman
Found the solution:
Filament::setCurrentPanel(
Filament::getPanel('order'), // Where `app` is the ID of the panel you want to test.
);
Filament::setCurrentPanel(
Filament::getPanel('order'), // Where `app` is the ID of the panel you want to test.
);
Was during tests

Did you find this page helpful?