Idea: models with two objects

  • 7
  • Idea
  • Updated 2 years ago
  • Planned
  • (Edited)
I have come across 5 to 10 use cases where I want to display data from two models in the same table. There are some work arounds, but it seems like a home run if Skuid allowed a single model to draw from two or more objects. I realize there are some complexities there, but it seems like if you have two "sister" objects that are related to the same parent, you could fairly easily join them together in the same table by having fields from both objects added to the model and declaring ID field of the first object as the primary ID for the model for things like context.
Photo of Skuidward Tentacles (Raymond)

Skuidward Tentacles (Raymond), Champion

  • 17,500 Points 10k badge 2x thumb

Posted 2 years ago

  • 7
Photo of Stephen Sells

Stephen Sells

  • 17,326 Points 10k badge 2x thumb
You can display data from two models in the same table using MODEL_LOOKUP. Are you familiar with this function and how it works?
Photo of Skuidward Tentacles (Raymond)

Skuidward Tentacles (Raymond), Champion

  • 17,500 Points 10k badge 2x thumb
Yep. Thanks Stephen. I have used that and it works great. My explanation of what I was trying to accomplish was a bit flawed. Instead of showing data from two models in the same row, I want to show Rows from two different models in the same table.
Say I have a custom object called "incoming mail" . I have a separate custom object called "outgoing mail". They are both children of Contact.
I would like to display rows from both and sort by the created date field in a single table.
There are other examples like displaying tasks and custom object records in the same table for a given contact.
The idea would be for records from both objects to appear in the same table and be sortable by some common criteria like created date or a Ui only formula field.
Photo of Stephen Sells

Stephen Sells

  • 17,326 Points 10k badge 2x thumb
I see. Thanks for clarifying. 
Photo of Zach McElrath

Zach McElrath, Employee

  • 50,362 Points 50k badge 2x thumb
@Raymond Internally we are referring to this feature request as "Union Models", and it is on our Roadmap. 
Photo of Skuidward Tentacles (Raymond)

Skuidward Tentacles (Raymond), Champion

  • 17,500 Points 10k badge 2x thumb
Great! Thanks!
Photo of Stephen Chilcoat

Stephen Chilcoat

  • 764 Points 500 badge 2x thumb
I have several use cases for this as well.