Resources are not rendered
"bezhansalleh/filament-shield": "^3.3",
"ibrahim-bougaoua/filaprogress": "^0.1.0"
"joaopaulolndev/filament-edit-profile": "^1.0"
"tomatophp/filament-simple-theme": "^1.0"
Hello, I created my project and everything is normal, but I installed some libraries as normal and it works normally, but when I create a new resource, it does not render in the dashboard.
Solution:Jump to solution
I really don't know what could have generated this, but I created a new project and started reconfiguring and now it's reading the new resources, thanks for the help.
12 Replies
Because your user doesn’t have permission to use them because of shield. You need to also generate the shield stuff for that resource and give your user permission to them.
I don't fully understand, I previously created the client model, configured it and finally executed migrations and created the resource and registered it in this segment but with the new model it didn't work, is that why you are telling me that it can fail? since I don't see in the documentation a command to register it and create a policy and it still doesn't show me the resource
It’s in the shield readme.
It still doesn't work, run the command "php artisan shield:generate --all" it generates the permissions but in the permissions assignment section I don't get the created models
and if you notice well the super_admin has all the permissions but they do not appear
I’m pretty sure it’s because of a policy / permissions issue. Maybe ask in the shield channel.
Or maybe you have cached views.
Solution
I really don't know what could have generated this, but I created a new project and started reconfiguring and now it's reading the new resources, thanks for the help.
After working a lot with this plugin I saw that the cache can greatly affect the final to solve run these commands
"php artisan filament:optimize"
"php artisan filament:optimize-clear"
@omar, you just need clear. Optimizing then clearing makes no sense
After deleting and redoing the project, the same thing happened, it did not load the new resources, so it was not a solution, that was where I saw the commands to clear the filament cache and with these the problem was solved.