|
@@ -103,8 +103,8 @@ class UserService extends CrudService {
|
|
|
|
|
|
// 其他用户绑定
|
|
|
async userbind(data) {
|
|
|
- const { openid, uid, type } = data;
|
|
|
- assert(openid && uid, '缺少部分信息项');
|
|
|
+ const { openid, uid, qucode } = data;
|
|
|
+ assert(openid && uid && qucode, '缺少部分信息项');
|
|
|
const user = await this.model.findById(uid);
|
|
|
if (!user) {
|
|
|
throw new BusinessError(ErrorCode.USER_NOT_EXIST);
|
|
@@ -119,10 +119,11 @@ class UserService extends CrudService {
|
|
|
durable: true,
|
|
|
headers: {
|
|
|
userid: uid,
|
|
|
+ openid,
|
|
|
} };
|
|
|
console.log(parm);
|
|
|
console.log(msg);
|
|
|
- await mq.topic('user_bind', uid, msg, parm);
|
|
|
+ await mq.topic('qrcode.bind', qucode, msg, parm);
|
|
|
} else {
|
|
|
this.ctx.logger.error('!!!!!!没有配置MQ插件!!!!!!');
|
|
|
}
|