@uwascan
Reuse the same Resources in multiple panels
See Here: https://laraveldaily.com/post/simple-laravel-multi-tenancy-with-single-trait
and https://laraveldaily.com/post/multi-tenancy-laravel-filament-simple
10 replies
Filament exception handling
Take a look at your Relation manager's base class and find out the method that handles saving the relationship. override this method in your sub class and handle the error there using Patrick's idea above. Let the documentation guide you.
5 replies
Selective Multi-tenancy
Here is what I did. Create a marker interface to Identify Models that are multitenant.
Create a new Base Class for your resources
You may create a base class for your Create Pages as shown below:
Make sure to extend the base classes above for any Resource that you add to a multitenant Panel. This will allow but multitenant Models and other models that are not multitenant to be used in all panels
17 replies
Some resources do not require tenant scope queries ,how to skip
Try this:
Create a Marker Interface as show below
create a Base Resource Class that all Your Filament Resource classes will extend as shown below:
Make sure all your Multitenant Models implements the interface. Also make sure all your CreatePages extends from the class below:
You can put theses classes any where in your project that makes sense to you. I am in the process of testing this out myself.
3 replies