pay
This commit is contained in:
@@ -305,16 +305,16 @@ func CancelWayOrder(ctx *jxcontext.Context, userId string, param *bida.CancelOrd
|
||||
return FailCode, err
|
||||
}
|
||||
/////////////
|
||||
mixPayInfo1, err := dao.GetMixPayDetail(orderWay.OrderID)
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
globals.SugarLogger.Debug("输出mixPayInfo1的status", mixPayInfo1.Status)
|
||||
userBill1, err := dao.GetUserBill(db, orderWay.UserID, "")
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
globals.SugarLogger.Debug("输出userBill", userBill1.AccountBalance)
|
||||
//mixPayInfo1, err := dao.GetMixPayDetail(orderWay.OrderID)
|
||||
//if err != nil {
|
||||
// return 0, err
|
||||
//}
|
||||
//globals.SugarLogger.Debug("输出mixPayInfo1的status", mixPayInfo1.Status)
|
||||
//userBill1, err := dao.GetUserBill(db, orderWay.UserID, "")
|
||||
//if err != nil {
|
||||
// return 0, err
|
||||
//}
|
||||
//globals.SugarLogger.Debug("输出userBill", userBill1.AccountBalance)
|
||||
////////////////
|
||||
globals.SugarLogger.Debug("回调进入微信退款")
|
||||
globals.SugarLogger.Debug("orderWay==============", orderWay)
|
||||
@@ -494,12 +494,14 @@ func RefundOrderByTL(ctx *jxcontext.Context, orderPay *model.Order, order *model
|
||||
dao.WrapAddIDCULDEntity(orderPayRefund, ctx.GetUserName())
|
||||
db := dao.GetDB()
|
||||
if result.TrxStatus == tonglianpayapi.TrxStatusSuccess {
|
||||
globals.SugarLogger.Debug("dfjiaojfiaojfa")
|
||||
orderPayRefund.Status = model.RefundStatusYes
|
||||
} else {
|
||||
globals.SugarLogger.Debug("gedgsedgresgwagwg")
|
||||
orderPayRefund.Status = model.RefundStatusFailed
|
||||
}
|
||||
orderPayRefund.OriginalData = utils.Format4Output(result, true)
|
||||
|
||||
globals.SugarLogger.Debug("saferhgtrhew", orderPayRefund.OriginalData)
|
||||
tx, _ := dao.Begin(db)
|
||||
defer func() {
|
||||
if r := recover(); r != nil {
|
||||
@@ -517,11 +519,13 @@ func RefundOrderByTL(ctx *jxcontext.Context, orderPay *model.Order, order *model
|
||||
dao.Rollback(db, tx)
|
||||
return nil, err
|
||||
}
|
||||
globals.SugarLogger.Debug("rtryjyttyejrthg")
|
||||
orderPay.Status = model.OrderStatusCancel
|
||||
if _, err := dao.UpdateEntityTx(tx, orderPay); err != nil {
|
||||
dao.Rollback(db, tx)
|
||||
return nil, err
|
||||
}
|
||||
globals.SugarLogger.Debug("ferbdebere")
|
||||
dao.Commit(db, tx)
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user