exc3ss.
Associating Support Service to Attached Products in Customer Resource
Hello everyone,
I'm working on a Filament project that currently uses three tables/models: a Customer model (which extends User), a Product model, and a SupportPacket model. At the moment, I have a relation manager in the Customer resource (created using the --attach command) that links products to a customer.
Now, I need to add another relation manager within the Customer resource that allows me to associate a support service (i.e., a SupportPacket) to a product that is already attached to that user. In other words, on the Customer's page, I want a new list where I can select one of the user's attached products and then assign a corresponding support service to it.
I haven't created a dedicated pivot model for this association yet. Would it be better to create a custom pivot model that handles this three-key relationship (user, product, support_packet), or is there a simpler way to set up such a relation manager using Filament's built-in functionalities?
Any guidance, examples, or best practices would be greatly appreciated!
2 replies