作者 陈志颖

fix:修复分红订单新增错误

... ... @@ -130,10 +130,11 @@ func (dividendsOrderService *DividendsOrderService) CreateDividendsOrder(createD
}
// 查找合约
var cooperationContractsMap map[string]*domain.CooperationContract
cooperationContractsMap := make(map[string]*domain.CooperationContract)
if count, cooperationContracts, err := cooperationContractRepository.Find(map[string]interface{}{
"companyId": createDividendsOrderCommand.CompanyId,
"orgId": createDividendsOrderCommand.OrgId,
"offsetLimit": false,
"companyId": createDividendsOrderCommand.CompanyId,
"orgId": createDividendsOrderCommand.OrgId,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ... @@ -317,7 +318,7 @@ func (dividendsOrderService *DividendsOrderService) ImportDividendsOrder(importD
}
// 查找合约
var cooperationContractsMap map[string]*domain.CooperationContract
cooperationContractsMap := make(map[string]*domain.CooperationContract)
countContracts, cooperationContracts, err := cooperationContractRepository.Find(map[string]interface{}{
"offsetLimit": false,
"companyId": importDividendsOrderCommand.CompanyId,
... ...
... ... @@ -143,10 +143,11 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) CreateDivide
}
// 查找合约
var cooperationContractsMap map[string]*domain.CooperationContract
cooperationContractsMap := make(map[string]*domain.CooperationContract)
if count, cooperationContracts, err := cooperationContractRepository.Find(map[string]interface{}{
"companyId": createDividendsReturnedOrderCommand.CompanyId,
"orgId": createDividendsReturnedOrderCommand.OrgId,
"offsetLimit": false,
"companyId": createDividendsReturnedOrderCommand.CompanyId,
"orgId": createDividendsReturnedOrderCommand.OrgId,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ... @@ -366,7 +367,7 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) ImportDivide
}
// 查找合约
var cooperationContractsMap map[string]*domain.CooperationContract
cooperationContractsMap := make(map[string]*domain.CooperationContract)
countContracts, cooperationContracts, err := cooperationContractRepository.Find(map[string]interface{}{
"offsetLimit": false,
"companyId": importDividendsReturnedOrderCommand.CompanyId,
... ...