diff --git a/common/model/approval_payment.go b/common/model/approval_payment.go index 12adcb6..6366197 100644 --- a/common/model/approval_payment.go +++ b/common/model/approval_payment.go @@ -9,15 +9,15 @@ import ( ) type ApprovalPayment struct { - Id int64 - CorpId int64 - Username string - Month string - SpNo string - ApplyTime string - CreateTime int64 - UpdateTime int64 - + Id int64 + CorpId int64 + Username string + Month string + SpNo string + ApplyTime string + CreateTime int64 + UpdateTime int64 + CostSubject string PaymentType string PaymentDate string PaymentAmount float64 @@ -34,6 +34,7 @@ func (a *ApprovalPayment) From(d *qyweixin.ApproveDetail) { paymentTime := cast.ToInt64(d.GetValue("付款日期")) a.Month = time.Unix(paymentTime, 0).Format("200601") + a.CostSubject = d.GetValue("成本主体") a.PaymentType = d.GetValue("付款类型") a.PaymentPayer = d.GetValue("付款主体") a.PaymentDate = goutil.TimeToDateTime(paymentTime) diff --git a/common/model/approval_refund.go b/common/model/approval_refund.go index 8e8f236..3b3086e 100644 --- a/common/model/approval_refund.go +++ b/common/model/approval_refund.go @@ -22,6 +22,7 @@ type ApprovalRefund struct { Username string Month string SpNo string + CostSubject string RefundType string RefundDate string RefundAmount float64 @@ -38,6 +39,7 @@ func (refund *ApprovalRefund) From(d *qyweixin.ApproveDetail) { refund.ApplyTime = goutil.TimeToDateTime(d.ApplyTime) refund.Status = ApprovalRefundStatusCreated refund.RefundType = d.GetValue("报销类型") + refund.CostSubject = d.GetValue("成本主体") refundTime := cast.ToInt64(d.GetValue("发生时间")) refund.Month = time.Unix(refundTime, 0).Format("200601") refund.RefundDate = goutil.TimeToDateTime(refundTime)