Merge branch 'dev' of http://gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway into dev
正在显示
15 个修改的文件
包含
123 行增加
和
26 行删除
@@ -161,6 +161,7 @@ func (srv CooperationApplicationsService) PersonSearchCooperationApplications(ap | @@ -161,6 +161,7 @@ func (srv CooperationApplicationsService) PersonSearchCooperationApplications(ap | ||
161 | CompanyId: int(applicationQuery.Operator.CompanyId), | 161 | CompanyId: int(applicationQuery.Operator.CompanyId), |
162 | CooperationApplicationStatus: applicationQuery.Status, | 162 | CooperationApplicationStatus: applicationQuery.Status, |
163 | UserBaseId: applicationQuery.Operator.UserBaseId, | 163 | UserBaseId: applicationQuery.Operator.UserBaseId, |
164 | + IsCanceled: 1, | ||
164 | }) | 165 | }) |
165 | if err != nil { | 166 | if err != nil { |
166 | return nil, application.ThrowError(application.BUSINESS_ERROR, err.Error()) | 167 | return nil, application.ThrowError(application.BUSINESS_ERROR, err.Error()) |
@@ -70,6 +70,7 @@ func (cooperationApplicationService *CooperationApplicationService) ListCooperat | @@ -70,6 +70,7 @@ func (cooperationApplicationService *CooperationApplicationService) ListCooperat | ||
70 | PageNumber: listCooperationApplicationQuery.PageNumber, | 70 | PageNumber: listCooperationApplicationQuery.PageNumber, |
71 | PageSize: listCooperationApplicationQuery.PageSize, | 71 | PageSize: listCooperationApplicationQuery.PageSize, |
72 | CompanyId: int(listCooperationApplicationQuery.Operator.CompanyId), | 72 | CompanyId: int(listCooperationApplicationQuery.Operator.CompanyId), |
73 | + IsCanceled: 3, | ||
73 | }) | 74 | }) |
74 | if err != nil { | 75 | if err != nil { |
75 | return 0, nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) | 76 | return 0, nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) |
@@ -94,11 +94,11 @@ type ContractUndertaker struct { | @@ -94,11 +94,11 @@ type ContractUndertaker struct { | ||
94 | Department domain.Department `json:"department"` | 94 | Department domain.Department `json:"department"` |
95 | HasReferrer bool `json:"hasReferrer"` | 95 | HasReferrer bool `json:"hasReferrer"` |
96 | HasSalesman bool `json:"hasSalesman"` | 96 | HasSalesman bool `json:"hasSalesman"` |
97 | - ReferrerUser struct { | 97 | + ReferrerUser *struct { |
98 | UserId int `json:"userId,string,"` | 98 | UserId int `json:"userId,string,"` |
99 | UserInfo domain.UserInfo `json:"userInfo"` | 99 | UserInfo domain.UserInfo `json:"userInfo"` |
100 | } `json:"referrerUser"` | 100 | } `json:"referrerUser"` |
101 | - SalesmanUser struct { | 101 | + SalesmanUser *struct { |
102 | UserId int `json:"userId,string,"` | 102 | UserId int `json:"userId,string,"` |
103 | UserInfo domain.UserInfo `json:"userInfo"` | 103 | UserInfo domain.UserInfo `json:"userInfo"` |
104 | } `json:"salesmanUser"` | 104 | } `json:"salesmanUser"` |
@@ -189,14 +189,26 @@ func ToCooperationContractInfo(param *allied_creation_cooperation.CooperationCon | @@ -189,14 +189,26 @@ func ToCooperationContractInfo(param *allied_creation_cooperation.CooperationCon | ||
189 | UserCode: v.UserInfo.UserCode, | 189 | UserCode: v.UserInfo.UserCode, |
190 | }, | 190 | }, |
191 | } | 191 | } |
192 | - u.SalesmanUser.UserId = v.Salesman.UserId | ||
193 | - u.SalesmanUser.UserInfo.UsersId = v.Salesman.UserId | ||
194 | - u.SalesmanUser.UserInfo.UsersName = v.Salesman.UserName | ||
195 | - u.SalesmanUser.UserInfo.Phone = v.Salesman.UserPhone | ||
196 | - u.ReferrerUser.UserId = v.Referrer.UserId | ||
197 | - u.ReferrerUser.UserInfo.UsersId = v.Referrer.UserId | ||
198 | - u.ReferrerUser.UserInfo.UsersName = v.Referrer.UserName | ||
199 | - u.ReferrerUser.UserInfo.Phone = v.Referrer.UserPhone | 192 | + if v.Salesman.UserId > 0 { |
193 | + u.SalesmanUser = &struct { | ||
194 | + UserId int `json:"userId,string,"` | ||
195 | + UserInfo domain.UserInfo `json:"userInfo"` | ||
196 | + }{} | ||
197 | + u.SalesmanUser.UserId = v.Salesman.UserId | ||
198 | + u.SalesmanUser.UserInfo.UsersId = v.Salesman.UserId | ||
199 | + u.SalesmanUser.UserInfo.UsersName = v.Salesman.UserName | ||
200 | + u.SalesmanUser.UserInfo.Phone = v.Salesman.UserPhone | ||
201 | + } | ||
202 | + if v.Referrer.UserId > 0 { | ||
203 | + u.ReferrerUser = &struct { | ||
204 | + UserId int `json:"userId,string,"` | ||
205 | + UserInfo domain.UserInfo `json:"userInfo"` | ||
206 | + }{} | ||
207 | + u.ReferrerUser.UserId = v.Referrer.UserId | ||
208 | + u.ReferrerUser.UserInfo.UsersId = v.Referrer.UserId | ||
209 | + u.ReferrerUser.UserInfo.UsersName = v.Referrer.UserName | ||
210 | + u.ReferrerUser.UserInfo.Phone = v.Referrer.UserPhone | ||
211 | + } | ||
200 | contractUndertaker = append(contractUndertaker, u) | 212 | contractUndertaker = append(contractUndertaker, u) |
201 | } | 213 | } |
202 | undertakerTypesUncheckedAvailable := param.UndertakerTypesUncheckedAvailable | 214 | undertakerTypesUncheckedAvailable := param.UndertakerTypesUncheckedAvailable |
1 | +package query | ||
2 | + | ||
3 | +import ( | ||
4 | + "gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/domain" | ||
5 | +) | ||
6 | + | ||
7 | +type ListContractSelectorQuery struct { | ||
8 | + //操作人 | ||
9 | + Operator domain.Operator `json:"-"` | ||
10 | + // 查询偏离量 | ||
11 | + PageNumber int `json:"pageNumber"` | ||
12 | + // 查询限制 | ||
13 | + PageSize int `json:"pageSize" valid:"Required"` | ||
14 | + CooperationContractNumber string `json:"cooperationContractNumber"` | ||
15 | + SponsorName string `json:"sponsorName"` | ||
16 | +} |
@@ -118,6 +118,7 @@ func (cooperationContractService *CooperationContractService) ListCooperationCon | @@ -118,6 +118,7 @@ func (cooperationContractService *CooperationContractService) ListCooperationCon | ||
118 | PageSize: listCooperationContractQuery.PageSize, | 118 | PageSize: listCooperationContractQuery.PageSize, |
119 | SponsorName: listCooperationContractQuery.SponsorName, | 119 | SponsorName: listCooperationContractQuery.SponsorName, |
120 | CooperationContractNumber: listCooperationContractQuery.CooperationContractNumber, | 120 | CooperationContractNumber: listCooperationContractQuery.CooperationContractNumber, |
121 | + OrgIds: listCooperationContractQuery.Operator.OrgIds, | ||
121 | }) | 122 | }) |
122 | if err != nil { | 123 | if err != nil { |
123 | return 0, nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) | 124 | return 0, nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) |
@@ -214,6 +215,7 @@ func (cooperationContractService *CooperationContractService) SearchCooperationC | @@ -214,6 +215,7 @@ func (cooperationContractService *CooperationContractService) SearchCooperationC | ||
214 | PageNumber: queryParam.PageNumber, | 215 | PageNumber: queryParam.PageNumber, |
215 | PageIndex: queryParam.PageSize, | 216 | PageIndex: queryParam.PageSize, |
216 | CompanyId: queryParam.Operator.CompanyId, | 217 | CompanyId: queryParam.Operator.CompanyId, |
218 | + OrgIds: queryParam.Operator.OrgIds, | ||
217 | }) | 219 | }) |
218 | 220 | ||
219 | return result.Grid.Total, result.Grid.List, err | 221 | return result.Grid.Total, result.Grid.List, err |
@@ -231,3 +233,27 @@ func (cooperationContractService *CooperationContractService) RemoveCooperationC | @@ -231,3 +233,27 @@ func (cooperationContractService *CooperationContractService) RemoveCooperationC | ||
231 | 233 | ||
232 | return removeCooperationContractCommand, nil | 234 | return removeCooperationContractCommand, nil |
233 | } | 235 | } |
236 | + | ||
237 | +// 分红单,分红退货单 返回共创合约下拉选择列表 | ||
238 | +func (cooperationContractService *CooperationContractService) ContractSelectorForDividendsOrder( | ||
239 | + listCooperationContractQuery *query.ListContractSelectorQuery) (int, interface{}, error) { | ||
240 | + creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation(listCooperationContractQuery.Operator) | ||
241 | + result, err := creationCooperationGateway.CooperationContractSearch(allied_creation_cooperation.ReqCooperationContractSearch{ | ||
242 | + PageNumber: listCooperationContractQuery.PageNumber, | ||
243 | + PageSize: listCooperationContractQuery.PageSize, | ||
244 | + SponsorName: listCooperationContractQuery.SponsorName, | ||
245 | + CooperationContractNumber: listCooperationContractQuery.CooperationContractNumber, | ||
246 | + OrgId: listCooperationContractQuery.Operator.OrgId, | ||
247 | + IncentivesType: 1, | ||
248 | + }) | ||
249 | + if err != nil { | ||
250 | + return 0, nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) | ||
251 | + } | ||
252 | + data := []dto.CooperationContractItem{} | ||
253 | + for i := range result.Grid.List { | ||
254 | + item := dto.ToCooperationContractItem(&result.Grid.List[i], listCooperationContractQuery.Operator.OrgId) | ||
255 | + data = append(data, *item) | ||
256 | + } | ||
257 | + | ||
258 | + return result.Grid.Total, data, nil | ||
259 | +} |
@@ -28,13 +28,16 @@ func (dividendsEstimateService *DividendsEstimateService) CancelDividendsEstimat | @@ -28,13 +28,16 @@ func (dividendsEstimateService *DividendsEstimateService) CancelDividendsEstimat | ||
28 | func (dividendsEstimateService *DividendsEstimateService) EstimateDividendsIncentives(estimateDividendsIncentivesCommand *command.EstimateDividendsIncentivesCommand) (interface{}, error) { | 28 | func (dividendsEstimateService *DividendsEstimateService) EstimateDividendsIncentives(estimateDividendsIncentivesCommand *command.EstimateDividendsIncentivesCommand) (interface{}, error) { |
29 | creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation( | 29 | creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation( |
30 | estimateDividendsIncentivesCommand.Operator) | 30 | estimateDividendsIncentivesCommand.Operator) |
31 | - _, err := creationCooperationGateway.DividendsEstimateDividendsIncentives(allied_creation_cooperation.ReqDividendsEstimateDividendsIncentives{ | 31 | + result, err := creationCooperationGateway.DividendsEstimateDividendsIncentives(allied_creation_cooperation.ReqDividendsEstimateDividendsIncentives{ |
32 | OrderGoodIds: estimateDividendsIncentivesCommand.OrderGoodIds, | 32 | OrderGoodIds: estimateDividendsIncentivesCommand.OrderGoodIds, |
33 | }) | 33 | }) |
34 | if err != nil { | 34 | if err != nil { |
35 | return nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) | 35 | return nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) |
36 | } | 36 | } |
37 | - return estimateDividendsIncentivesCommand, nil | 37 | + respData := map[string]string{ |
38 | + "result": result.Report, | ||
39 | + } | ||
40 | + return respData, nil | ||
38 | } | 41 | } |
39 | 42 | ||
40 | // 确定预算金额激励分红 | 43 | // 确定预算金额激励分红 |
@@ -221,11 +224,11 @@ func (dividendsEmmateService *DividendsEstimateService) MoneyIncentivesSelector( | @@ -221,11 +224,11 @@ func (dividendsEmmateService *DividendsEstimateService) MoneyIncentivesSelector( | ||
221 | //ConfimDividendsEstimate 确定分红预算 | 224 | //ConfimDividendsEstimate 确定分红预算 |
222 | func (dividendsEstimateService *DividendsEstimateService) ConfimDividendsEstimate(confimDividendsEstimateCommand *command.ConfimDividendsEstimateCommand) (interface{}, error) { | 225 | func (dividendsEstimateService *DividendsEstimateService) ConfimDividendsEstimate(confimDividendsEstimateCommand *command.ConfimDividendsEstimateCommand) (interface{}, error) { |
223 | creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation(confimDividendsEstimateCommand.Operator) | 226 | creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation(confimDividendsEstimateCommand.Operator) |
224 | - _, err := creationCooperationGateway.CreditAccountsAdd(allied_creation_cooperation.ReqCreditAccountsAdd{ | 227 | + result, err := creationCooperationGateway.CreditAccountsAdd(allied_creation_cooperation.ReqCreditAccountsAdd{ |
225 | DividendsEstimateIds: confimDividendsEstimateCommand.DividendsEstimateId, | 228 | DividendsEstimateIds: confimDividendsEstimateCommand.DividendsEstimateId, |
226 | }) | 229 | }) |
227 | if err != nil { | 230 | if err != nil { |
228 | return nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) | 231 | return nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) |
229 | } | 232 | } |
230 | - return confimDividendsEstimateCommand, nil | 233 | + return result, nil |
231 | } | 234 | } |
@@ -126,7 +126,7 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) UpdateDivide | @@ -126,7 +126,7 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) UpdateDivide | ||
126 | return updateDividendsReturnedOrderCommand, nil | 126 | return updateDividendsReturnedOrderCommand, nil |
127 | } | 127 | } |
128 | 128 | ||
129 | -// 更新分红退货单服务 | 129 | +// 分红单下拉选择列表 |
130 | func (dividendsReturnedOrderService *DividendsReturnedOrderService) SelectorDividendsOrder(selectorDividendsOrderQuery *query.SelectorDividendsOrderQuery) ( | 130 | func (dividendsReturnedOrderService *DividendsReturnedOrderService) SelectorDividendsOrder(selectorDividendsOrderQuery *query.SelectorDividendsOrderQuery) ( |
131 | int, interface{}, error) { | 131 | int, interface{}, error) { |
132 | creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation(selectorDividendsOrderQuery.Operator) | 132 | creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation(selectorDividendsOrderQuery.Operator) |
@@ -134,6 +134,7 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) SelectorDivi | @@ -134,6 +134,7 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) SelectorDivi | ||
134 | DividendsOrderNumber: selectorDividendsOrderQuery.DividendsOrderNumber, | 134 | DividendsOrderNumber: selectorDividendsOrderQuery.DividendsOrderNumber, |
135 | PageNumber: 1, | 135 | PageNumber: 1, |
136 | PageSize: 999, | 136 | PageSize: 999, |
137 | + OrgId: selectorDividendsOrderQuery.Operator.OrgId, | ||
137 | }) | 138 | }) |
138 | if err != nil { | 139 | if err != nil { |
139 | return 0, nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) | 140 | return 0, nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error()) |
@@ -171,6 +171,7 @@ type ( | @@ -171,6 +171,7 @@ type ( | ||
171 | OrgId int64 `json:"orgId"` // 组织机构ID | 171 | OrgId int64 `json:"orgId"` // 组织机构ID |
172 | UserId int64 `json:"userId"` | 172 | UserId int64 `json:"userId"` |
173 | UserBaseId int64 `json:"userBaseId"` | 173 | UserBaseId int64 `json:"userBaseId"` |
174 | + IsCanceled int `json:"isCanceled"` //1正常,2取消,3所有 | ||
174 | } | 175 | } |
175 | 176 | ||
176 | DataCooperationApplicationSearch struct { | 177 | DataCooperationApplicationSearch struct { |
@@ -235,6 +235,9 @@ type ( | @@ -235,6 +235,9 @@ type ( | ||
235 | OrgId int64 ` json:"orgId"` | 235 | OrgId int64 ` json:"orgId"` |
236 | // 用户基础数据id | 236 | // 用户基础数据id |
237 | UserBaseId int64 `json:"userBaseId"` | 237 | UserBaseId int64 `json:"userBaseId"` |
238 | + // 组织机构ID | ||
239 | + OrgIds []int64 ` json:"orgIds"` | ||
240 | + IncentivesType int `json:"incentivesType"` //作为合约激励方式的判断,1业绩分红激励,2金额激励 | ||
238 | } | 241 | } |
239 | 242 | ||
240 | DataCooperationContractSearch struct { | 243 | DataCooperationContractSearch struct { |
@@ -248,13 +251,14 @@ type ( | @@ -248,13 +251,14 @@ type ( | ||
248 | //根据承接人查询并返回共创项目合约 | 251 | //根据承接人查询并返回共创项目合约 |
249 | type ( | 252 | type ( |
250 | ReqCooperationContractSearchByUndertaker struct { | 253 | ReqCooperationContractSearchByUndertaker struct { |
251 | - CooperationContractName string `json:"cooperationContractName"` //合约名称 | ||
252 | - SponsorName string `json:"sponsorName"` //项目发起人姓名 | ||
253 | - PageNumber int `json:"pageNumber"` | ||
254 | - PageIndex int `json:"pageIndex"` | ||
255 | - CompanyId int64 ` json:"companyId"` | ||
256 | - OrgId int64 ` json:"orgId"` | ||
257 | - UserBaseId int64 `json:"userBaseId"` | 254 | + CooperationContractName string `json:"cooperationContractName"` //合约名称 |
255 | + SponsorName string `json:"sponsorName"` //项目发起人姓名 | ||
256 | + PageNumber int `json:"pageNumber"` | ||
257 | + PageIndex int `json:"pageIndex"` | ||
258 | + CompanyId int64 ` json:"companyId"` | ||
259 | + OrgId int64 ` json:"orgId"` | ||
260 | + UserBaseId int64 `json:"userBaseId"` | ||
261 | + OrgIds []int64 ` json:"orgIds"` | ||
258 | } | 262 | } |
259 | 263 | ||
260 | DataCooperationContractSearchByUndertaker struct { | 264 | DataCooperationContractSearchByUndertaker struct { |
@@ -7,12 +7,12 @@ type ( | @@ -7,12 +7,12 @@ type ( | ||
7 | ReqContractChangeLogsSearch struct { | 7 | ReqContractChangeLogsSearch struct { |
8 | OperationType int `json:"operationType,"` // 合约变更操作类型,1编辑、2暂停、3恢复 | 8 | OperationType int `json:"operationType,"` // 合约变更操作类型,1编辑、2暂停、3恢复 |
9 | CooperationContractNumber string `json:"cooperationContractNumber"` // 共创合约编号 | 9 | CooperationContractNumber string `json:"cooperationContractNumber"` // 共创合约编号 |
10 | - PageNumber int ` json:"pageNumber,"` // 页码 | 10 | + PageNumber int `json:"pageNumber,"` // 页码 |
11 | PageSize int `json:"pageSize,"` // 页面大小 | 11 | PageSize int `json:"pageSize,"` // 页面大小 |
12 | CompanyId int `json:"companyId"` //公司ID | 12 | CompanyId int `json:"companyId"` //公司ID |
13 | OrgId int64 `json:"orgId"` // 组织机构ID | 13 | OrgId int64 `json:"orgId"` // 组织机构ID |
14 | OrgIds []int64 `json:"orgIds"` // 关联的组织机构ID列表 | 14 | OrgIds []int64 `json:"orgIds"` // 关联的组织机构ID列表 |
15 | - UserId int64 ` json:"userId"` // 用户ID, | 15 | + UserId int64 `json:"userId"` // 用户ID, |
16 | UserBaseId int64 `json:"userBaseId"` // 用户基础数据id | 16 | UserBaseId int64 `json:"userBaseId"` // 用户基础数据id |
17 | } | 17 | } |
18 | 18 |
@@ -138,6 +138,20 @@ type ( | @@ -138,6 +138,20 @@ type ( | ||
138 | DividendsEstimateIds []string `json:"dividendsEstimateIds"` | 138 | DividendsEstimateIds []string `json:"dividendsEstimateIds"` |
139 | } | 139 | } |
140 | 140 | ||
141 | - DataCreditAccountsAdd []struct { | 141 | + DataCreditAccountsAdd struct { |
142 | + // 账期结算单ID | ||
143 | + CreditAccountId int64 `json:"creditAccountId,string"` | ||
144 | + // 账期结算实付金额 | ||
145 | + ActuallyPaidAmount float64 `json:"actuallyPaidAmount"` | ||
146 | + // 账期结算单号 | ||
147 | + CreditAccountOrderNum string `json:"creditAccountOrderNum"` | ||
148 | + // 账期结算支付状态,1待支付,2已支付 | ||
149 | + PaymentStatus int32 `json:"paymentStatus"` | ||
150 | + // 共创账期结算支付时间 | ||
151 | + PaymentTime time.Time `json:"paymentTime"` | ||
152 | + // 账期结算金额 | ||
153 | + SettlementAmount float64 `json:"settlementAmount"` | ||
154 | + // 共创账期结算时间 | ||
155 | + SettlementTime time.Time `json:"settlementTime"` | ||
142 | } | 156 | } |
143 | ) | 157 | ) |
@@ -244,6 +244,7 @@ type ( | @@ -244,6 +244,7 @@ type ( | ||
244 | OrderGoodIds []string `json:"orderGoodIds"` | 244 | OrderGoodIds []string `json:"orderGoodIds"` |
245 | } | 245 | } |
246 | 246 | ||
247 | - DataDividendsEstimateDividendsIncentives []struct { | 247 | + DataDividendsEstimateDividendsIncentives struct { |
248 | + Report string `json:"report"` | ||
248 | } | 249 | } |
249 | ) | 250 | ) |
@@ -127,6 +127,7 @@ type ( | @@ -127,6 +127,7 @@ type ( | ||
127 | CompanyId int `json:"companyId"` | 127 | CompanyId int `json:"companyId"` |
128 | CustomerName string `json:"customerName"` | 128 | CustomerName string `json:"customerName"` |
129 | DividendsOrderNumber string `json:"dividendsOrderNumber"` | 129 | DividendsOrderNumber string `json:"dividendsOrderNumber"` |
130 | + OrgId int64 `json:"orgId"` | ||
130 | OrgIds []int64 `json:"orgIds"` | 131 | OrgIds []int64 `json:"orgIds"` |
131 | PageNumber int `json:"pageNumber"` | 132 | PageNumber int `json:"pageNumber"` |
132 | PageSize int `json:"pageSize"` | 133 | PageSize int `json:"pageSize"` |
@@ -106,3 +106,18 @@ func (controller *CooperationContractController) RemoveCooperationContract() { | @@ -106,3 +106,18 @@ func (controller *CooperationContractController) RemoveCooperationContract() { | ||
106 | data, err := cooperationContractService.RemoveCooperationContract(removeCooperationContractCommand) | 106 | data, err := cooperationContractService.RemoveCooperationContract(removeCooperationContractCommand) |
107 | controller.Response(data, err) | 107 | controller.Response(data, err) |
108 | } | 108 | } |
109 | + | ||
110 | +//分红订单,分红退货单获取关联合约选择列表 | ||
111 | +func (controller *CooperationContractController) SelectorContractForDividendsOrder() { | ||
112 | + cooperationContractService := service.NewCooperationContractService(nil) | ||
113 | + listCooperationContractQuery := &query.ListContractSelectorQuery{} | ||
114 | + err := controller.Unmarshal(listCooperationContractQuery) | ||
115 | + if err != nil { | ||
116 | + log.Logger.Debug("json err:" + err.Error()) | ||
117 | + controller.Response(nil, err) | ||
118 | + return | ||
119 | + } | ||
120 | + listCooperationContractQuery.Operator = controller.GetOperator() | ||
121 | + cnt, data, err := cooperationContractService.ContractSelectorForDividendsOrder(listCooperationContractQuery) | ||
122 | + controller.ReturnPageListData(int64(cnt), data, err, listCooperationContractQuery.PageNumber) | ||
123 | +} |
@@ -11,4 +11,5 @@ func init() { | @@ -11,4 +11,5 @@ func init() { | ||
11 | web.Router("/v1/web/dividends-order/remove", &web_client.DividendsOrderController{}, "Post:RemoveDividendsOrder") | 11 | web.Router("/v1/web/dividends-order/remove", &web_client.DividendsOrderController{}, "Post:RemoveDividendsOrder") |
12 | web.Router("/v1/web/dividends-order/:orderId", &web_client.DividendsOrderController{}, "Get:GetDividendsOrder") | 12 | web.Router("/v1/web/dividends-order/:orderId", &web_client.DividendsOrderController{}, "Get:GetDividendsOrder") |
13 | web.Router("/v1/web/dividends-order/search", &web_client.DividendsOrderController{}, "Post:SearchDividendsOrder") | 13 | web.Router("/v1/web/dividends-order/search", &web_client.DividendsOrderController{}, "Post:SearchDividendsOrder") |
14 | + web.Router("/v1/web/dividends-order/selector/contract", &web_client.CooperationContractController{}, "Post:SelectorContractForDividendsOrder") | ||
14 | } | 15 | } |
-
请 注册 或 登录 后发表评论