Saasli / saasli-backend

Documentation
https://saasli.github.io/docs/
0 stars 0 forks source link

[Events] Handle Standard vs. Custom Object Polymorphic Names #50

Closed godd9170 closed 7 years ago

godd9170 commented 7 years ago

As it stands, we slap '__c' on the end of the name of the triggering record object type assuming that there will exist a field called that.

%s__c' % request.triggeringrecordobjecttype : request.triggeringrecord.sfid, #polymorphic relating id

Two options I can think of for overcoming this hacky solution are.

1) Check to see if there is a 'c' on the sf_object_id parameter, and only add it if there is NOT__.

2) Add an additional param sf_event_object_id (or something) that denotes the field that should contain the associating id.

godd9170 commented 7 years ago

Same goes for the event endpoint too.

godd9170 commented 7 years ago

This was fixed above ^