fix code
This commit is contained in:
parent
81ee19a92f
commit
96325994ea
|
@ -3800,6 +3800,11 @@ func (v *Vas) payRefund(ctx *gin.Context, tx *sqlx.Tx, order *dbstruct.Order) er
|
||||||
logger.Error("wxpayCli.RefundOne fail, orderId: %v, resp: %v, err: %v", orderId, util.ToJson(resp), err)
|
logger.Error("wxpayCli.RefundOne fail, orderId: %v, resp: %v, err: %v", orderId, util.ToJson(resp), err)
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
if resp.Code >= 400 {
|
||||||
|
err = fmt.Errorf(resp.Error)
|
||||||
|
logger.Error("wxpayCli.RefundOne fail, invalid code, orderId: %v, resp: %v, err: %v", orderId, util.ToJson(resp), err)
|
||||||
|
return err
|
||||||
|
}
|
||||||
case vasproto.PayTypeCoin:
|
case vasproto.PayTypeCoin:
|
||||||
err := v.store.IncCoins(ctx, tx, order.GetMid(), order.GetPayAmount())
|
err := v.store.IncCoins(ctx, tx, order.GetMid(), order.GetPayAmount())
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in New Issue