Any chance you can share what you are trying to pass into the query?
Here's what I have done with an onClick event on a button for adding Terms into a table:
This is the additionalScope trigger fired when clicking on the button
for(i=0;i<terms.value.length; i++){
This would work if it was in a JS query but not in a custom component. With a component I need to call (afaik) triggerQuery which is available in the window.Retool object.
This works for example: window.Retool.triggerQuery('save_new_print') but unable to pass any additionalScope to that call. I'm probably missing the formatting here (how the data gets passed to the function)
Hey minijohn, I'm happy to offer a suggestion here In our docs on how to trigger queries from your custom component it suggests that you pass the data you want to be used in your query to your app separately using modelUpdate() and then reference that value in the query that is triggered. Could that work for your use case?
Hey minijohn, Unfortunately, no, triggerQuery doesn't accept parameters. Hopefully, you can make this work by passing your parameters with model and modelUpdate!
Hey @p0wl! Unfortunately, there aren't many updates to share here. The ticket hasn't been on the roadmap so far, it was recently bumped to get more eyes on it but I can't say when support will be added. For now, the best route is to have queries reference the custom component's model as mentioned above.