Skip to Content
Menu
This question has been flagged
1468 Views

I have several modules that include a customer field. I want to be able to list all the records from these modules associated with each customer. For instance, suppose I have two modules: module A and module B. Also, suppose I have a customer named John Doe. John Doe has two records in module A and one record in module B. When I search the name "John Doe" in my master search, I should get a list like this:

CustomerModule Type
John Doemodule A
John Doemodule A
John Doemodule B
Here are my ideas for solving this:

  • I could create a new module that gets a list of all the records in my different modules and create a search view by customer on it. I'm mainly worried that I'd have to create a new model and store tons of new records. Is there a way to create a module that doesn't actually store any records but instead just displays a list of records across multiple modules?

  • I could extend the customer module so that the records of each module get associated with the customer. For instance, using the example above, the customer John Doe would have two One2many fields, one for a list of module A records and one for a list of module B records. However, I'm worried that these fields may get out of sync with what's actually in the database.

Does anyone have a better idea of how to do this?


Avatar
Discard
Related Posts Replies Views Activity
4
May 24
10074
1
Apr 24
1564
0
Nov 23
525
1
Sep 23
568
2
Aug 23
2427