Merge branch 'feat-IRONFANS-70' into test

This commit is contained in:
lwl0608 2024-04-25 15:28:32 +08:00
commit 85d20b02a9
2 changed files with 12 additions and 14 deletions

View File

@ -2263,18 +2263,16 @@ func (s *Service) ApiGetZoneListByMid(ctx *gin.Context, req *zoneproto.ApiListBy
return return
} }
zid := list[0].GetId() zid := list[0].GetId()
if zu, ok := zidZuMap[zid]; ok && (time.Now().Unix()-zu.GetAdmissionCt() < 3600*2) { zidZuMapTmp, _ := _DefaultVas.GetZoneUnlockMapByMidZids(ctx, req.BaseRequest.Mid, []int64{zid})
refundEnable = 1 logger.Info("_ZU mid: %v, zid: %v, zidZuMapTmp: %v", req.BaseRequest.Mid, zid, util.ToJson(zidZuMapTmp))
} if zu, ok := zidZuMapTmp[zid]; ok {
logger.Info("_ZU mid: %v, zid: %v, zu: %v", req.BaseRequest.Mid, zid, util.ToJson(zu))
// 退款状态 if time.Now().Unix()-zu.GetAdmissionCt() < 3600*2 {
if _, ok := zidZuMap[zid]; !ok { refundEnable = 1
return }
} if zu.GetAdmissionUnlockType() == dbstruct.ZoneUnlockTypeRefund {
admissionOrderId := zidZuMap[zid].GetAdmissionOrderId() refundStatus = zoneproto.AdmissionRefundStatusFinish
order, _ := _DefaultVas.GetOrderById(ctx, nil, admissionOrderId) }
if order.GetOrderStatus() == dbstruct.VasOrderStatusRefund {
refundStatus = zoneproto.AdmissionRefundStatusFinish
} }
return return

View File

@ -271,7 +271,7 @@ func (s *Service) chListCharge(ctx *gin.Context, chList []*dbstruct.ConsumeHisto
Ct: util.DerefInt64(chDB.Ct), Ct: util.DerefInt64(chDB.Ct),
} }
changeMark := "-" changeMark := "-"
if chDB.GetChange() > 0 { if chDB.GetChange() >= 0 {
changeMark = "+" changeMark = "+"
} }
switch chDB.GetSType() { switch chDB.GetSType() {
@ -320,7 +320,7 @@ func (s *Service) chListIncome(ctx *gin.Context, chList []*dbstruct.ConsumeHisto
Ct: util.DerefInt64(chDB.Ct), Ct: util.DerefInt64(chDB.Ct),
} }
changeMark := "-" changeMark := "-"
if chDB.GetChange() > 0 { if chDB.GetChange() >= 0 {
changeMark = "+" changeMark = "+"
} }
switch chDB.GetSType() { switch chDB.GetSType() {