fix: 已领取的玩家添加gotAmount 字段

This commit is contained in:
chenkai 2023-12-22 21:23:13 +08:00
parent 4a6a40403d
commit c304a6d8cc
3 changed files with 5 additions and 6 deletions

View File

@ -36,14 +36,14 @@ export async function playerCanReceive(call: ApiCall, callError : boolean = true
const price = activityInfo.data['price']; const price = activityInfo.data['price'];
if (!vipScore) { if (!vipScore) {
return { return {
payNum: 0, remaining, result: false, activityInfo, showOffList, price payNum: 0, remaining, result: false, activityInfo, showOffList, price, gotAmount: 0
}; };
} }
const payNum = vipScore; const payNum = vipScore;
// 玩家充值未达标或者奖池余额耗尽则不能领取 // 玩家充值未达标或者奖池余额耗尽则不能领取
if (payNum < price || remaining <= 0) { if (payNum < price || remaining <= 0) {
return { return {
payNum, remaining, result: false, activityInfo, showOffList, price payNum, remaining, result: false, activityInfo, showOffList, price, gotAmount: 0
} }
} }
// 检查玩家今日是否已经领取 // 检查玩家今日是否已经领取
@ -56,7 +56,7 @@ export async function playerCanReceive(call: ApiCall, callError : boolean = true
} }
} }
return { return {
payNum, remaining, result: true, activityInfo, showOffList, price payNum, remaining, result: true, activityInfo, showOffList, price, gotAmount: 0
}; };
} }

View File

@ -8,5 +8,5 @@ export type ResCanReceive = {
result: boolean; result: boolean;
price: number; price: number;
showOffList: any[]; showOffList: any[];
gotAmount?: number; gotAmount: number;
}; };

View File

@ -10165,8 +10165,7 @@ export const serviceProto: ServiceProto<ServiceType> = {
"name": "gotAmount", "name": "gotAmount",
"type": { "type": {
"type": "Number" "type": "Number"
}, }
"optional": true
} }
] ]
}, },