Render Model Rows Based on Values of Rows in Another Model

Ben KnechtBen Knecht Member
edited June 25 in Questions
I'm trying to create a drawer in a table (Model A) that drops down records in Model B ONLY if the records in Model B have a Date AFTER the record in Model A.

The scenario is: I have a Table (Model A) with a date field associated with each record. I want to create a Drawer that shows records from Model B, ONLY IF the Date of each record on Model B are after the Date of the record in Model A. 

Is this possible to do without any coding/Javascript?

Thank you!

Comments

  • Pat VachonPat Vachon Member 💎💎💎
    edited June 25
    Use the context option for the table in the drawer.
  • Ben KnechtBen Knecht Member
    edited December 2017
    Hey Pat,

    I tried that out, but the Operator only gives me options of Equal or Not Equal to. I need a "Greater than or Equal" to option. Any ideas?image
  • Pat VachonPat Vachon Member 💎💎💎
    edited December 2017
    Yup. Forgot about that UI restriction. Context is simply a component specific condition. You can create the condition on the model and the copy/paste into the place where this context/condition is in XML.
  • Ben KnechtBen Knecht Member
    edited December 2017
    Ahh, I see. I'll give that a go but not sure I'm competent enough to do it haha. Do you think a subquery on the model would work?
  • Pat VachonPat Vachon Member 💎💎💎
    edited December 2017
    No. It needs to be contextual to the row in which you clicked the row action. Must be hacked in.
  • Ben KnechtBen Knecht Member
    edited December 2017
    Thanks Pat, I appreciate the help. I'll try to hack it through.
Sign In or Register to comment.