审查视图

pkg/infrastructure/service_gateway/allied_creation_cooperation/param_credit_account.go 6.0 KB
1 2
package allied_creation_cooperation
Your Name authored
3 4 5 6 7 8 9
import (
	"time"

	"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/domain"
)

type CreditAccount struct {
tangxuhui authored
10
	CreditAccountId           int       `json:"creditAccountId,string,"`   // 账期结算单ID
Your Name authored
11 12 13 14 15 16 17
	ActuallyPaidAmount        float64   `json:"actuallyPaidAmount"`        // 账期结算实付金额
	CreditAccountOrderNum     string    `json:"creditAccountOrderNum"`     // 账期结算单号
	PaymentStatus             int       `json:"paymentStatus"`             // 账期结算支付状态,1待支付,2已支付
	PaymentTime               time.Time `json:"paymentTime"`               // 共创账期结算支付时间
	SettlementAmount          float64   `json:"settlementAmount"`          // 账期结算金额
	SettlementTime            time.Time `json:"settlementTime"`            // 共创账期结算时间
	CooperationContractNumber string    `json:"cooperationContractNumber"` // 关联共创合约编号
tangxuhui authored
18
	Participator              struct {
tangxuhui authored
19 20 21 22 23 24 25
		UserId     int             `json:"userId,string,"`     // 用户ID,
		UserBaseId int             `json:"userBaseId,string,"` // 用户基本id
		UserInfo   domain.UserInfo `json:"userInfo"`           //
		UserName   string          `json:"userName"`           // 用户姓名
		UserPhone  string          `json:"userPhone"`          // 用户手机号
		UserType   int             `json:"userType"`           // 用户类型,1员工,2共创用户,3公开
		Status     int             `json:"status"`             // 状态
tangxuhui authored
26
	} `json:"participator"` // 参与人
tangxuhui authored
27 28 29 30 31 32 33 34
	// 操作人
	Operator struct {
		UserId     int             `json:"userId,string,"`     // 用户ID,
		UserBaseId int             `json:"userBaseId,string,"` // 用户基本id
		UserName   string          `json:"userName"`           // 用户姓名
		UserPhone  string          `json:"userPhone"`          // 用户手机号
		UserInfo   domain.UserInfo `json:"userInfo"`           //
	} `json:"operator"`
35 36 37
	ParticipateType            string              `json:"participateType"`            // 参与类型
	PaymentDocumentAttachments []domain.Attachment `json:"paymentDocumentAttachments"` // 支付凭证附件
	Org                        struct {
tangxuhui authored
38 39 40
		OrgID   int    `json:"orgId,string"`
		OrgName string `json:"orgName"`
	} `json:"org"` // 数据所属组织机构
yangfu authored
41
	Company       domain.CompanyData `json:"company1"`  // 公司
tangxuhui authored
42 43
	CreatedAt     time.Time          `json:"createdAt"` // 创建时间
	UpdatedAt     time.Time          `json:"updatedAt"` // 更新时间
yangfu authored
44
	AccountDetail []struct {
tangxuhui authored
45
		DividendsEstimateOrderNumber string  `json:"dividendsEstimateOrderNumber"`
tangxuhui authored
46
		DividendsType                int     `json:"dividendsType"`
tangxuhui authored
47 48
		DividendsAmount              float64 `json:"dividendsAmount"`
	} `json:"accountDetail"` //结算明细
49 50
	//备注
	Remarks string `json:"remarks"`
Your Name authored
51
}
yangfu authored
52
53 54 55
//支付账期结算
type (
	ReqCreditAccountsPay struct {
56 57 58 59
		CreditAccountId           int                 `json:"creditAccountId,string"`
		ActuallyPaidAmount        float64             `json:"actuallyPaidAmount"` //实际支付金额
		Remarks                   string              `json:"remarks"`
		PaymentDocumentAttachment []domain.Attachment `json:"paymentDocumentAttachment"` //附件
60 61 62 63 64 65 66 67 68
	}

	DataCreditAccountsPay struct {
	}
)

//查询账期结算单
type (
	ReqCreditAccountsSearch struct {
yangfu authored
69
		// 页面大小
Your Name authored
70
		PageNumber int64 `json:"pageNumber,omitempty"`
yangfu authored
71
		// 页面大小
Your Name authored
72
		PageSize int64 `json:"pageSize,omitempty"`
yangfu authored
73
		// 账期结算单号
Your Name authored
74
		CreditAccountOrderNum string `json:"creditAccountOrderNum" valid:"Required"`
yangfu authored
75
		// 参与人姓名
Your Name authored
76
		ParticipatorName string ` json:"participatorName,omitempty"`
yangfu authored
77
		// 账期结算支付状态,1待支付,2已支付,APP端结算记录返回已结算的账期结算单
Your Name authored
78
		PaymentStatus int32 `json:"paymentStatus" valid:"Required"`
yangfu authored
79
		// 结算周期,按年“2021”或者按月结算”2021-07“
Your Name authored
80
		Period time.Time `json:"period,omitempty"`
yangfu authored
81 82 83 84 85 86 87 88 89
		// 公司ID,通过集成REST上下文获取
		CompanyId int64 `cname:"公司ID" json:"companyId"`
		// 组织机构ID
		OrgId int64 `cname:"组织机构ID" json:"orgId"`
		// 关联的组织机构ID列表
		OrgIds []int64 `cname:"关联的组织机构ID列表" json:"orgIds"`
		// 用户ID,通过集成REST上下文获取,可翻译成发起人、承接人、推荐人、业务员
		UserId int64 `cname:"用户ID" json:"userId"`
		// 用户基础数据id
yangfu authored
90 91 92
		UserBaseId int64     `cname:"用户基础数据ID" json:"userBaseId"`
		BeginTime  time.Time `json:"beginTime"`
		EndTime    time.Time `json:"endTime"`
yangfu authored
93 94 95 96
		// 支付开始时间
		PaymentBeginTime time.Time `json:"paymentBeginTime"`
		// 支付结束时间
		PaymentEndTime time.Time `json:"paymentEndTime"`
97 98
		// 合约编号列表
		CooperationContractNumbers []string `json:"cooperationContractNumbers"`
99 100 101
	}

	DataCreditAccountsSearch struct {
Your Name authored
102 103 104 105
		Grid struct {
			Total int             `json:"total"`
			List  []CreditAccount `json:"list"`
		} `json:"grid"`
106 107 108 109 110 111
	}
)

//移除账期结算单
type (
	ReqCreditAccountRemove struct {
Your Name authored
112
		CreditAccountId int `json:"creditAccountId"`
113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130
	}

	DataCreditAccountRemove struct {
	}
)

//返回账期结算单列表
type (
	ReqCreditAccountList struct {
	}

	DataCreditAccountList struct {
	}
)

//返回账期结算单详情
type (
	ReqCreditAccountGet struct {
131
		CreditAccountId int `json:"creditAccountId,string"`
132 133 134
	}

	DataCreditAccountGet struct {
Your Name authored
135
		CreditAccount
136 137
	}
)
138 139 140 141

//创建账期结算
type (
	ReqCreditAccountsAdd struct {
Your Name authored
142
		DividendsEstimateIds []string `json:"dividendsEstimateIds"`
143 144
	}
tangxuhui authored
145 146 147 148 149 150 151 152 153 154 155 156 157 158 159
	DataCreditAccountsAdd struct {
		// 账期结算单ID
		CreditAccountId int64 `json:"creditAccountId,string"`
		// 账期结算实付金额
		ActuallyPaidAmount float64 `json:"actuallyPaidAmount"`
		// 账期结算单号
		CreditAccountOrderNum string `json:"creditAccountOrderNum"`
		// 账期结算支付状态,1待支付,2已支付
		PaymentStatus int32 `json:"paymentStatus"`
		// 共创账期结算支付时间
		PaymentTime time.Time `json:"paymentTime"`
		// 账期结算金额
		SettlementAmount float64 `json:"settlementAmount"`
		// 共创账期结算时间
		SettlementTime time.Time `json:"settlementTime"`
160 161
	}
)