Merge branch 'feat-IRONFANS-70' into test

This commit is contained in:
lwl0608 2024-04-25 15:12:35 +08:00
commit 4439f43169
1 changed files with 7 additions and 12 deletions

View File

@ -2380,19 +2380,14 @@ func (s *Service) ApiGetZoneListByUserIdFromOutside(ctx *gin.Context, req *zonep
}
zid := list[0].GetId()
zidZuMap, _ := _DefaultVas.GetZoneUnlockMapByMidZids(ctx, mid, []int64{zid})
if zu, ok := zidZuMap[zid]; ok && (time.Now().Unix()-zu.GetAdmissionCt() < 3600*2) {
if zu, ok := zidZuMap[zid]; ok {
if time.Now().Unix()-zu.GetAdmissionCt() < 3600*2 {
refundEnable = 1
}
// 退款状态
if _, ok := zidZuMap[zid]; !ok {
return
}
admissionOrderId := zidZuMap[zid].GetAdmissionOrderId()
order, _ := _DefaultVas.GetOrderById(ctx, nil, admissionOrderId)
if order.GetOrderStatus() == dbstruct.VasOrderStatusRefund {
if zu.GetAdmissionUnlockType() == dbstruct.ZoneUnlockTypeRefund {
refundStatus = zoneproto.AdmissionRefundStatusFinish
}
}
return
}