Breaking Change in Rockaway: Field from another model conditions cannot be overidden in table filters or action sequences.

  • 5
  • Announcement
  • Updated 2 years ago
  • (Edited)
Hi Guys

I want to have a filter with the source rows in a model and filterable default on. As I created this filter, everything worked fine. Probably it stopped working with the upgrade to Rockaway. I'm working on a sandbox with version 8.8.
On my dev org, I had Banzai version 7.31, so I tried it there - worked fine. After upgrading this org to Rockaway, it stopped working again.

XML:


   
       
           
               
               
           
           
           
       
       
           
               
               
               
           
           
               
           
           
       
   
   
       
           
               
               
           
           
               
               
           
           
               
               
           
           
               
           
           
               
                   
                       
                            {{{Name}}}
                            {{Id}}
                       
                   
               
           
       
   
   
       
       
       
   
   
       
   

Photo of JG GBC

JG GBC

  • 694 Points 500 badge 2x thumb

Posted 2 years ago

  • 5
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,006 Points 20k badge 2x thumb
Ok.  There is a breaking change in Rockaway. 

"Field from another model" conditions can no longer have values over-riden by injected values. 

We are trying to make "FFAM" conditions more powerful - so that they listen to changes made in parent models. 
But a downstream impact of this feature is that we've taken away the ability for table filters and action framework sequences to inject specific values into those conditions.  You can activate or deactivate "FFAM" conditions,  but you cannot override thier values. 

The workaround for this is to create a second condition that is "filterable default off" and has a blank value.  Then your filter has 2 steps.  Deactivate the FFAM condition and activate the second one - and pass the appropriate value into it. 

With all the salesforce patch silliness from last week,  we haven't appropriately gotten this word out.  That's our task this week...
Photo of Craig Rosenbaum

Craig Rosenbaum

  • 4,776 Points 4k badge 2x thumb
Rob,

This might explain an issue I was having with a Distance condition that is a single specified value but the "Comparison Location Source" is FFAM. I was trying to follow the advice from this thread with deferred promise and $.when calls to update the comparison location value, save it, update the FFAM model, and then update the model with the distance condition on it - all in that order.

My code seems to be working and running in the correct order, but the condition is not updated until I refresh the page. I was going to continue fiddling with my code but if the issue is related to what you said, I can stop and wait for a better option. Do you see an issue in the logic in my code or is this behavior only from the Rockaway change?

Relevant Code:

       $.when(model.updateRow(        { Id: row.Id },
        { CheetahBMS__GeoLocation__Longitude__s: obj.results[0].geometry.location.lng,
          CheetahBMS__GeoLocation__Latitude__s: obj.results[0].geometry.location.lat}
      )
      
      )
      
      .done(function(){
          console.log("row updated");
          $.when(model.save())
          .done(function(){
              console.log("model saved");
               $.when(model.updateData())
              .done(function(){
                  
                  console.log("Res: "+model.data[0].CheetahBMS__GeoLocation__Latitude__s +", "+model.data[0].CheetahBMS__GeoLocation__Longitude__s);
                  var condition = Contact.getConditionByName('MailingAddress');
                  console.log(condition);
                  Contact.setCondition(condition,row.distanceFilter);
              $.when(Contact.updateData())
              .done(function(){
                  
                  console.log("Contact: "+Contact.conditions[4].latitudeValue +", "+Contact.conditions[4].longitudeValue);
                  dfd.resolve();
              });
                  
              });
          });
         
      
      })
Photo of Joseph Ortiz

Joseph Ortiz

  • 594 Points 500 badge 2x thumb
Does this workaround apply for External REST Data sources?
Photo of Ben Hubbard

Ben Hubbard, Employee

  • 12,490 Points 10k badge 2x thumb
Update: We're planning on making an update to Rockaway that would return this functionality so that your pages work as they did in Banzai. We hope to have this fix available in the next few weeks.