sql—如何在javascript中使用rpc查询和读取方法,以便从表中获取所有行在奥多13?

9gm1akwq  于 2021-07-29  发布在  Java
关注(0)|答案(1)|浏览(317)

我和奥多13一起工作。我试着从我的table上取下所有的行。我应该在arg中传递什么,以便一次获取所有字符串?
我的代码:

var res = rpc.query({
            model: 'my model',
            method: 'read',
            args: [????]
        }).then(function (data) {
            console.log(data); });
        };
brjng4g3

brjng4g31#

павел храпун
打电话给 method 关于(python) model 通过rpc访问记录数据。

var id = this.id; // (pass the record of ID which you want to read the data)
var res = rpc.query({
        model: 'Your Model',
        method: 'read', // method which you wanna call
        args: [[id], ['name']], // First argument to pass the ID along with second args pass fields
    }).then(function (data) {
        console.log(data); });
    };

相关问题