Merge branch 'feature/yuandan' into dev

This commit is contained in:
dy 2023-12-27 17:00:30 +08:00
commit 1292156a9d
3 changed files with 22 additions and 4 deletions

View File

@ -19,8 +19,9 @@ export default async function (call: ApiCall<ReqDMRec, ResDMRec>) {
await PlayerFun.cutNeed(call, _hd.data.gameneed); await PlayerFun.cutNeed(call, _hd.data.gameneed);
} }
let prize = []
if (call.req.id) { if (call.req.id) {
let prize = PublicShared.randomDropGroup('1', 1, {'1': _hd.data.game}); prize = PublicShared.randomDropGroup('1', 1, {'1': _hd.data.game});
await PlayerFun.sendPrize(call, prize); await PlayerFun.sendPrize(call, prize);
} }
@ -28,7 +29,7 @@ export default async function (call: ApiCall<ReqDMRec, ResDMRec>) {
$inc: {[`gameNum`]: 1}, $inc: {[`gameNum`]: 1},
}, {upsert: true}) }, {upsert: true})
call.succ({}) call.succ({prize})
HongDianChange.sendChangeKey(call.uid, ['yuandan']); HongDianChange.sendChangeKey(call.uid, ['yuandan']);
} }

View File

@ -1,3 +1,5 @@
import {prizeType} from "../../type";
/** /**
* *
*/ */
@ -5,4 +7,6 @@ export type ReqDMRec = {
id: 1 | 0 id: 1 | 0
} }
export type ResDMRec = {} export type ResDMRec = {
prize: prizeType[]
}

View File

@ -11427,7 +11427,20 @@ export const serviceProto: ServiceProto<ServiceType> = {
] ]
}, },
"event/yuandan/PtlDMRec/ResDMRec": { "event/yuandan/PtlDMRec/ResDMRec": {
"type": "Interface" "type": "Interface",
"properties": [
{
"id": 0,
"name": "prize",
"type": {
"type": "Array",
"elementType": {
"type": "Reference",
"target": "type/prizeType"
}
}
}
]
}, },
"event/yuandan/PtlDZRec/ReqDZRec": { "event/yuandan/PtlDZRec/ReqDZRec": {
"type": "Interface", "type": "Interface",