Horizons
Best practice to inject additional attributes into my Laravel model to persist in state
Hello, I have an Application model (paper form converted to digital) where I retreive extra attributes from an external table and append them to my model. Currently, after a preform an action on my Infolist page the extra attributes are lost on the page refresh when the action is called. So I'm retreiving them again with afterActionCalled(). This seems very inefficient as the same query is being called multiple times on same page. What is the best practice to append these extra attributes to my Infolist state?
2 replies
Persisting Model Data between Form Updates
I'm using the mount method to load extra data attributes to my model to present on the form in a View component. When I trigger a form input to become visible the model refreshes and I lose my extra data. Is there a way to stop the model from being refreshed or is there another method I could use to re-inject my data attributes?
2 replies
Panel Issues
I am running into some issues working with a panel. The help functions route() and auth() are giving me errors. The route() helper states the named route doesn't exist when it does. And the auth() helper is stating a user provider isn't defined. Are these helper methods not useable within the Filament environment?
5 replies
How to modify a model before form fill?
Hello. I have a laravel form I'm trying to convert into Filament. Before loading the create page I would reach out to an external database for info about the user. Is this possible to do with a filament resource?
This function sets attributes on my Application model so I have access to them on the create page.
3 replies