You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@CoolRpcService({
entity: DemoGoodsEntity,
method: ['add', 'delete', 'update', 'info', 'list', 'page'],
})
中使用
let result = await this.rpc.call('goods', 'DemoGoodsService', 'info', {
id: 1
});
报错误
{
"code": 1001,
"message": "You must provide selection conditions in order to find a single row."
}
请修改一下
@cool-midway/rpc/base.js 中的async info() 中的 const info = await this.entity.findOne({ id });为 const info = await this.entity.createQueryBuilder().where({id}).getOne();
The text was updated successfully, but these errors were encountered:
微服务
@CoolRpcService({
entity: DemoGoodsEntity,
method: ['add', 'delete', 'update', 'info', 'list', 'page'],
})
中使用
let result = await this.rpc.call('goods', 'DemoGoodsService', 'info', {
id: 1
});
报错误
{
"code": 1001,
"message": "You must provide selection conditions in order to find a single row."
}
请修改一下
@cool-midway/rpc/base.js 中的async info() 中的 const info = await this.entity.findOne({ id });为 const info = await this.entity.createQueryBuilder().where({id}).getOne();
The text was updated successfully, but these errors were encountered: