将活动的奖励结果改成数组
This commit is contained in:
parent
fe417b99c7
commit
4c2afbff6e
16
doc/api.md
16
doc/api.md
@ -98,13 +98,6 @@
|
||||
"gameResult": 0 // 当局的游戏结果, 单人的话和上一层gameResult相同
|
||||
}
|
||||
},
|
||||
"rewards": [{
|
||||
coupon: '优惠券的id',
|
||||
name: '优惠券名',
|
||||
count: 1, //数量
|
||||
couponUrl: '优惠券详情图的url',
|
||||
ids: ['获取记录的短id']
|
||||
}]
|
||||
}
|
||||
```
|
||||
### 3. 开始匹配
|
||||
@ -292,7 +285,14 @@
|
||||
"gameResult": 0, // 当局的游戏结果, 单人的话和上一层gameResult相同
|
||||
"timeLast": 1620973155307 //上次回答时间
|
||||
}
|
||||
}
|
||||
},
|
||||
"rewards": [{
|
||||
coupon: '优惠券的id',
|
||||
name: '优惠券名',
|
||||
count: 1, //数量
|
||||
couponUrl: '优惠券详情图的url',
|
||||
ids: ['获取记录的短id']
|
||||
}]
|
||||
}
|
||||
```
|
||||
|
||||
|
@ -143,7 +143,7 @@ export async function sendReward(history: any) {
|
||||
continue
|
||||
}
|
||||
const data = await UserReward.addOneRecord(history, members[i].accountId, adata.id, adata.coupon, adata.count)
|
||||
await sendMsg(history.room, members[i].sessionId, 'rewords', data)
|
||||
await sendMsg(history.room, members[i].sessionId, 'rewords', [data])
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user