In Odoo, If we want to trigger a python function, it can be done with the help of _rpc calls.

1
2
3
4
5
6
7
this._rpc({
            model: this.model,
            method: 'quick_publish_products',
            args: [this.res_id],
        }).then(function (result) {
            self.do_action(result);
        });

  

posted @ 2023-09-21 18:58  CrossPython  阅读(13)  评论(0)    收藏  举报
点击右上角即可分享
微信分享提示