diff --git a/modules/pay/agropay/base.go b/modules/pay/agropay/base.go index 97021fc..b3873ee 100644 --- a/modules/pay/agropay/base.go +++ b/modules/pay/agropay/base.go @@ -80,6 +80,10 @@ func (s *Sub) GetResp() (proto.Message, error) { func (s *Sub) PackPayReq() interface{} { r := s.Base.PayReq + r.Amount /= 100 + if len(r.Phone) == 12 { + r.Phone = r.Phone[2:] + } send := &PayReq{ MchNo: mid, AppId: appID, @@ -105,6 +109,10 @@ func (s *Sub) PackPayReq() interface{} { func (s *Sub) PackWithdrawReq() interface{} { r := s.Base.WithdrawReq + r.Amount /= 100 + if len(r.Phone) == 12 { + r.Phone = r.Phone[2:] + } send := &WithdrawReq{ MchNo: mid, AppId: appID,