[2025-05-29] How to pass parameters to Retool queries, dockerized Playwright / 如何向Retool中的query传递参数,docker化的Playwright使用

Retool

How to input parameters to queries

Finally got the method.
I am using an old version of retool. In this version, every query has an Additional Scope feature. Add parameters one by one here, and they can be used in current query just like normal variables (for example, {{ param_a }}).
And the query should be triggered with an additionalScope like:

my_query.trigger({
  additionalScope: {
    param_a: param_a,
    param_b: param_b
  } 
});

In this way, I don’t have to use Restful APIs for database access from ListView.
But I have already used the APIs… While, using APIs can be supportive for other clients or websites.
At least that was what I told myself.

Playwright

Using docker for Playwright is quite convenient.
But ChatGPT is a bit behind time, and recommended an old version which caused some problems.
Using the latest version is fine.
Continue tomorrow.

Related Platforms

(Github Issues) / (Notion) / (Blog)

Advertisement

(A website to optimize your resume and to boost your career: Nonpareil.me)

Retool

如何向query中传递参数

总算试明白了。
我用的retool版本有点旧。在这个版本中,query会有一个设置叫Additional Scope。在这里可以一个一个添加参数,添加之后,在这个query中,就可以像其它变量一样引用了(比如{{ param_a }})。
这个query在触发的时候也需要带一个additionalScope变量:

my_query.trigger({
  additionalScope: {
    param_a: param_a,
    param_b: param_b
  } 
});

这样,我就不用再写Restful API来专门实现ListView中的组件与数据库的交互了。
不过我已经用API实现了……至少,使用API可以为未来的扩展开发打个基础。
至少我是这么告诉自己的。

Playwright

用Docker模式运行Playwright很方便。
不过ChatGPT有点落后,推荐了个旧版本,产生了不少问题。
更新到新版本就解决了。
明天继续。

相关平台

(Github Issues) / (Notion) / (Blog)

推广

(优化简历,助力职场:Nonpareil.me)

发表评论

您的邮箱地址不会被公开。 必填项已用 * 标注

滚动至顶部