I have model A - (Aggregate Model, with condition which is always off) and on Model B (Basic Model) there is a UI only formula field which is MODAL_LOOKUP to get the value for that specific row from the Model A.
Now, the scenario is in this way, the Model B is using the UI only field to show the sum of multiple child for each row, which is working as expected.
UI-only field on Model B-
ABS( MODEL_LOOKUP( ModelA, sumOfAllChildRecords, {{KeyFieldfromModelAId}}, {{KeyFieldfromModel2Id}} ) )
And, on Model B there is multi-select picklist filter based on type of the child, So, I have created a action based on the filter condition, that whenever the condition is applied run a JS Snippet.
JS Snippet
var params = argumentss0],$ = skuid.$;
var filterItems = params.newValues;
var ModelA = skuid.$M(‘ModelA’);
var ChildTypeCondtion = ModelA.getConditionByName(‘ChildTypeCondtion’);
ModelA.setCondition(ChildTypeCondtion,filterItems); ModelA.activateCondition(ChildTypeCondtion);
This snippet is running whenever I apply the filter, So, I am expecting that it should also update the rows of the Model A, if the condition is activated, and applied.
And the same if you turn on the condition intentionally by default from the Skuid Builder by hard-coding a value then it returns the expected result.
I want this to updated dynamically based on the filter applied on Model B