Merge branch 'dev' of http://gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway into dev
正在显示
7 个修改的文件
包含
15 行增加
和
10 行删除
@@ -20,12 +20,12 @@ type CreditAccountItem struct { | @@ -20,12 +20,12 @@ type CreditAccountItem struct { | ||
20 | UserType int `json:"userType"` // 用户类型,1员工,2共创用户,3公开 | 20 | UserType int `json:"userType"` // 用户类型,1员工,2共创用户,3公开 |
21 | } `json:"participator"` // 参与人 | 21 | } `json:"participator"` // 参与人 |
22 | ParticipateType string `json:"participateType"` // 参与类型 | 22 | ParticipateType string `json:"participateType"` // 参与类型 |
23 | - PaymentDocumentAttachment domain.Attachment `json:"paymentDocumentAttachment"` // 支付凭证附件 | 23 | + PaymentDocumentAttachment *domain.Attachment `json:"paymentDocumentAttachment"` // 支付凭证附件 |
24 | Org struct { | 24 | Org struct { |
25 | OrgID int `json:"orgId,string"` | 25 | OrgID int `json:"orgId,string"` |
26 | OrgName string `json:"orgName"` | 26 | OrgName string `json:"orgName"` |
27 | } `json:"org"` // 数据所属组织机构 | 27 | } `json:"org"` // 数据所属组织机构 |
28 | - Company domain.CompanyData `json:"company11"` // TODO:暂时不需要公司 | 28 | + Company domain.CompanyData `json:"-"` // TODO:暂时不需要公司 |
29 | CreatedAt int64 `json:"createdAt"` // 创建时间 | 29 | CreatedAt int64 `json:"createdAt"` // 创建时间 |
30 | UpdatedAt int64 `json:"updatedAt"` // 更新时间 | 30 | UpdatedAt int64 `json:"updatedAt"` // 更新时间 |
31 | AccountDetail []struct { | 31 | AccountDetail []struct { |
@@ -57,7 +57,7 @@ func ToCreditAccountItem(param *allied_creation_cooperation.CreditAccount) *Cred | @@ -57,7 +57,7 @@ func ToCreditAccountItem(param *allied_creation_cooperation.CreditAccount) *Cred | ||
57 | SettlementTime: 0, | 57 | SettlementTime: 0, |
58 | CooperationContractNumber: param.CooperationContractNumber, | 58 | CooperationContractNumber: param.CooperationContractNumber, |
59 | ParticipateType: param.ParticipateType, // 参与类型 | 59 | ParticipateType: param.ParticipateType, // 参与类型 |
60 | - PaymentDocumentAttachment: param.PaymentDocumentAttachment, // 支付凭证附件 | 60 | + PaymentDocumentAttachment: nil, // 支付凭证附件 |
61 | Company: param.Company, // 公司 | 61 | Company: param.Company, // 公司 |
62 | CreatedAt: param.CreatedAt.UnixNano() / 1e6, // 创建时间 | 62 | CreatedAt: param.CreatedAt.UnixNano() / 1e6, // 创建时间 |
63 | UpdatedAt: param.UpdatedAt.UnixNano() / 1e6, // 更新时间 | 63 | UpdatedAt: param.UpdatedAt.UnixNano() / 1e6, // 更新时间 |
@@ -69,6 +69,9 @@ func ToCreditAccountItem(param *allied_creation_cooperation.CreditAccount) *Cred | @@ -69,6 +69,9 @@ func ToCreditAccountItem(param *allied_creation_cooperation.CreditAccount) *Cred | ||
69 | if !param.SettlementTime.IsZero() { | 69 | if !param.SettlementTime.IsZero() { |
70 | data.SettlementTime = param.PaymentTime.UnixNano() / 1e6 | 70 | data.SettlementTime = param.PaymentTime.UnixNano() / 1e6 |
71 | } | 71 | } |
72 | + if len(param.PaymentDocumentAttachment.Url) > 0 { | ||
73 | + data.PaymentDocumentAttachment = ¶m.PaymentDocumentAttachment | ||
74 | + } | ||
72 | data.Org.OrgID = param.Org.OrgID | 75 | data.Org.OrgID = param.Org.OrgID |
73 | data.Org.OrgName = param.Org.OrgName | 76 | data.Org.OrgName = param.Org.OrgName |
74 | data.Participator.UserName = param.Participator.UserName | 77 | data.Participator.UserName = param.Participator.UserName |
@@ -8,7 +8,7 @@ type UpdateDividendsOrderCommand struct { | @@ -8,7 +8,7 @@ type UpdateDividendsOrderCommand struct { | ||
8 | //操作人 | 8 | //操作人 |
9 | Operator domain.Operator `json:"-"` | 9 | Operator domain.Operator `json:"-"` |
10 | //分红订单 | 10 | //分红订单 |
11 | - DividendsOrderID int `json:"dividendsOrderId"` | 11 | + DividendsOrderID int `json:"-"` |
12 | //客户名称 | 12 | //客户名称 |
13 | CustomerName string `json:"customerName"` | 13 | CustomerName string `json:"customerName"` |
14 | //分红订单金额 | 14 | //分红订单金额 |
@@ -23,6 +23,7 @@ type UpdateDividendsOrderCommand struct { | @@ -23,6 +23,7 @@ type UpdateDividendsOrderCommand struct { | ||
23 | RegionName string `json:"regionName"` | 23 | RegionName string `json:"regionName"` |
24 | //订单产品列表 | 24 | //订单产品列表 |
25 | OrderGoods []struct { | 25 | OrderGoods []struct { |
26 | + OrderGoodId int `json:"orderGoodId,string"` | ||
26 | CooperationContractNumber string `json:"cooperationContractNumber"` //关联的共创合约编号 | 27 | CooperationContractNumber string `json:"cooperationContractNumber"` //关联的共创合约编号 |
27 | DividendsOrderNumber string `json:"dividendsOrderNumber"` //关联分红订单号 | 28 | DividendsOrderNumber string `json:"dividendsOrderNumber"` //关联分红订单号 |
28 | // OrderGoodAmount float64 `json:"orderGoodAmount"` //订单产品金额 | 29 | // OrderGoodAmount float64 `json:"orderGoodAmount"` //订单产品金额 |
@@ -109,9 +109,10 @@ func (dividendsOrderService *DividendsOrderService) UpdateDividendsOrder(updateD | @@ -109,9 +109,10 @@ func (dividendsOrderService *DividendsOrderService) UpdateDividendsOrder(updateD | ||
109 | // if err := updateDividendsOrderCommand.ValidateCommand(); err != nil { | 109 | // if err := updateDividendsOrderCommand.ValidateCommand(); err != nil { |
110 | // return nil, application.ThrowError(application.ARG_ERROR, err.Error()) | 110 | // return nil, application.ThrowError(application.ARG_ERROR, err.Error()) |
111 | // } | 111 | // } |
112 | - orderGoods := []allied_creation_cooperation.DividendsOrderGoods{} | 112 | + orderGoods := []allied_creation_cooperation.DividendsOrderGoodAdd{} |
113 | for _, v := range updateDividendsOrderCommand.OrderGoods { | 113 | for _, v := range updateDividendsOrderCommand.OrderGoods { |
114 | - good := allied_creation_cooperation.DividendsOrderGoods{ | 114 | + good := allied_creation_cooperation.DividendsOrderGoodAdd{ |
115 | + OrderGoodId: int64(v.OrderGoodId), | ||
115 | CooperationContractNumber: v.CooperationContractNumber, | 116 | CooperationContractNumber: v.CooperationContractNumber, |
116 | DividendsOrderNumber: v.DividendsOrderNumber, | 117 | DividendsOrderNumber: v.DividendsOrderNumber, |
117 | OrderGoodExpense: v.OrderGoodExpense, | 118 | OrderGoodExpense: v.OrderGoodExpense, |
@@ -146,7 +146,7 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) SelectorDivi | @@ -146,7 +146,7 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) SelectorDivi | ||
146 | "dividendsOrderNumber": v.DividendsOrderNumber, | 146 | "dividendsOrderNumber": v.DividendsOrderNumber, |
147 | "dividendsOriginalOrderNum": v.DividendsOriginalOrderNum, | 147 | "dividendsOriginalOrderNum": v.DividendsOriginalOrderNum, |
148 | "dividendsOrderId": strconv.Itoa(v.DividendsOrderID), | 148 | "dividendsOrderId": strconv.Itoa(v.DividendsOrderID), |
149 | - "orderTime": v.OrderTime.Unix(), | 149 | + "orderTime": v.OrderTime.UnixNano() / 1e6, |
150 | } | 150 | } |
151 | listData = append(listData, m) | 151 | listData = append(listData, m) |
152 | } | 152 | } |
@@ -350,7 +350,7 @@ func (usersService *UsersService) CooperationUserGet(cooperationUserGetQuery *qu | @@ -350,7 +350,7 @@ func (usersService *UsersService) CooperationUserGet(cooperationUserGetQuery *qu | ||
350 | } | 350 | } |
351 | var deadline int64 | 351 | var deadline int64 |
352 | if !result.CooperationInfo.CooperationDeadline.IsZero() { | 352 | if !result.CooperationInfo.CooperationDeadline.IsZero() { |
353 | - deadline = result.CooperationInfo.CooperationDeadline.Unix() | 353 | + deadline = result.CooperationInfo.CooperationDeadline.UnixNano() / 1e6 |
354 | } | 354 | } |
355 | userInfo := dto.CooperationUserInfo{ | 355 | userInfo := dto.CooperationUserInfo{ |
356 | UserId: strconv.Itoa(result.UserId), | 356 | UserId: strconv.Itoa(result.UserId), |
@@ -165,7 +165,7 @@ type ( | @@ -165,7 +165,7 @@ type ( | ||
165 | // 共创项目合约编号,自生成,生成规则:XM+6位年月日+#+3位流水,例XM210601#001 | 165 | // 共创项目合约编号,自生成,生成规则:XM+6位年月日+#+3位流水,例XM210601#001 |
166 | CooperationContractNumber string `json:"cooperationContractNumber"` | 166 | CooperationContractNumber string `json:"cooperationContractNumber"` |
167 | // 分红用户(共创参与) | 167 | // 分红用户(共创参与) |
168 | - DividendsUser *struct { | 168 | + DividendsUser struct { |
169 | // 用户ID,通过集成REST上下文获取,可翻译成发起人、承接人、推荐人、业务员 | 169 | // 用户ID,通过集成REST上下文获取,可翻译成发起人、承接人、推荐人、业务员 |
170 | UserId int64 `json:"userId,string"` | 170 | UserId int64 `json:"userId,string"` |
171 | // 用户基本id | 171 | // 用户基本id |
@@ -108,7 +108,7 @@ type ( | @@ -108,7 +108,7 @@ type ( | ||
108 | DividendsOrderNumber string `json:"dividendsOrderNumber"` //分红订单号 | 108 | DividendsOrderNumber string `json:"dividendsOrderNumber"` //分红订单号 |
109 | DividendsOriginalOrderNum string `json:"dividendsOriginalOrderNum"` //分红订单原单号 | 109 | DividendsOriginalOrderNum string `json:"dividendsOriginalOrderNum"` //分红订单原单号 |
110 | OperatorUid int `json:"operatorUid,string"` //订单操作人id | 110 | OperatorUid int `json:"operatorUid,string"` //订单操作人id |
111 | - OrderGoods []DividendsOrderGoods `json:"orderGoods"` //订单产品列表 | 111 | + OrderGoods []DividendsOrderGoodAdd `json:"orderGoods"` //订单产品列表 |
112 | OrderTime string `json:"orderTime"` //订单日期,13位长度字符串类型时间戳 | 112 | OrderTime string `json:"orderTime"` //订单日期,13位长度字符串类型时间戳 |
113 | Remarks string `json:"remarks"` //备注 | 113 | Remarks string `json:"remarks"` //备注 |
114 | SalesmanUid string `json:"salesmanUid"` //订单业务员uid | 114 | SalesmanUid string `json:"salesmanUid"` //订单业务员uid |
-
请 注册 或 登录 后发表评论