diff --git a/app/mix/service/vasservice.go b/app/mix/service/vasservice.go index 37d04d02..be27129a 100644 --- a/app/mix/service/vasservice.go +++ b/app/mix/service/vasservice.go @@ -255,6 +255,9 @@ func (s *Service) chListCost(ctx *gin.Context, chList []*dbstruct.ConsumeHistory if chDB.GetChange() < 0 { item.Change = fmt.Sprintf("%d金币", chDB.GetChange()) } + case dbstruct.CHSTypeCostRefundMembership: + item.Desc = fmt.Sprintf("会员退款") + item.Change = fmt.Sprintf("%d金币", chDB.GetChange()) } list = append(list, item) } @@ -282,6 +285,9 @@ func (s *Service) chListCharge(ctx *gin.Context, chList []*dbstruct.ConsumeHisto case dbstruct.CHSTypeChargeRefund: item.Desc = "退款" item.Change = changeMark + fmt.Sprintf("%d金币", chDB.GetChange()) + case dbstruct.CHSTypeChargeRefundMembership: + item.Desc = "会员退款" + item.Change = fmt.Sprintf("%d金币", chDB.GetChange()) } list = append(list, item) } @@ -306,6 +312,9 @@ func (s *Service) chListIncome(ctx *gin.Context, chList []*dbstruct.ConsumeHisto case dbstruct.CHSTypeIncomeInvite: item.Desc = "邀请收益" item.Change = changeMark + fmt.Sprintf("%d钻石", chDB.GetChange()) + case dbstruct.CHSTypeIncomeRefund: + item.Desc = "会员退款" + item.Change = changeMark + fmt.Sprintf("%d钻石", chDB.GetChange()) } list = append(list, item) } diff --git a/library/payclients/wxpaycli/client_test.go b/library/payclients/wxpaycli/client_test.go index e8ac9b44..27dae206 100644 --- a/library/payclients/wxpaycli/client_test.go +++ b/library/payclients/wxpaycli/client_test.go @@ -117,8 +117,8 @@ func TestWxpayClient_H5Pay(t *testing.T) { func TestWxpayClient_RefundOne(t *testing.T) { cli := GetDefaultWxpayClient() resp, err := cli.RefundOne(context.Background(), &RefundOneParam{ - OutTradeNo: "1767889021582716928", - RefundAmount: 100, + OutTradeNo: "1767893922425614336", + RefundAmount: 4900, RefundReason: "发货D退款", }) if err != nil {