作者 陈志颖

合并分支 'dev' 到 'test'

fix:去除批量操作查询限制



查看合并请求 !56
... ... @@ -24,6 +24,8 @@ type OneClickApprovalCooperationApplicationCommand struct {
Action int32 `cname:"审核动作" json:"action" valid:"Required"`
// 审核状态
CooperationApplicationStatus int32 `cname:"共创申请审核状态" json:"cooperationApplicationStatus"`
// 查询限制
OffsetLimit bool `cname:"查询限制" json:"offsetLimit"`
}
func (oneClickApprovalCooperationApplicationCommand *OneClickApprovalCooperationApplicationCommand) Valid(validation *validation.Validation) {
... ...
... ... @@ -371,6 +371,7 @@ func (cooperationApplicationService *CooperationApplicationService) BatchApprova
// 获取共创申请
if count, cooperationApplications, err := cooperationApplicationRepository.Find(map[string]interface{}{
"cooperationApplicationIds": cooperationApplicationIds,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ... @@ -451,6 +452,7 @@ func (cooperationApplicationService *CooperationApplicationService) OneClickAppr
// 查询共创申请
oneClickApprovalCooperationApplicationCommand.CooperationApplicationStatus = 1 // 待审核
oneClickApprovalCooperationApplicationCommand.OffsetLimit = false
if count, cooperationApplications, err := cooperationApplicationRepository.Find(tool_funs.SimpleStructToMap(oneClickApprovalCooperationApplicationCommand)); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ...
... ... @@ -561,6 +561,7 @@ func (cooperationContractService *CooperationContractService) BatchRemoveCoopera
cooperationContractIds, _ := utils.SliceAtoi(batchRemoveCooperationContractCommand.CooperationContractIds)
if count, cooperationContracts, err := cooperationContractRepository.Find(map[string]interface{}{
"cooperationContractIds": cooperationContractIds,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ... @@ -737,6 +738,7 @@ func (cooperationContractService *CooperationContractService) BatchOperateCooper
}
if count, cooperationContracts, err := cooperationContractRepository.Find(map[string]interface{}{
"cooperationContractIds": cooperationContractIds,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ...
... ... @@ -328,6 +328,7 @@ func (cooperationModeService *CooperationModeService) BatchRemoveCooperationMode
// 获取共创模式
if count, cooperationModes, err := cooperationModeRepository.Find(map[string]interface{}{
"cooperationModeIds": cooperationModeIds,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ...
... ... @@ -766,6 +766,7 @@ func (cooperationProjectService *CooperationProjectService) BatchEndCooperationP
}
if count, cooperationProjects, err := cooperationProjectRepository.Find(map[string]interface{}{
"cooperationProjectIds": cooperationProjectIds,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ...
... ... @@ -343,6 +343,7 @@ func (dividendsEstimateService *DividendsEstimateService) BatchCancelDividendsEs
// 获取分红预算
if count, dividendsEstimates, err := dividendsEstimateRepository.Find(map[string]interface{}{
"dividendsEstimateIds": dividendsEstimateIds,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ... @@ -660,6 +661,7 @@ func (dividendsEstimateService *DividendsEstimateService) ConfirmDividendsIncent
// 获取订单产品
if _, orderGoods, err := orderGoodRepository.Find(map[string]interface{}{
"orderGoodIds": orderGoodIds,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ... @@ -810,6 +812,7 @@ func (dividendsEstimateService *DividendsEstimateService) ConfirmDividendsIncent
if len(orderGoodSavedIds) > 0 {
if countOrderGood, orderGoodsFound, err := orderGoodRepository.Find(map[string]interface{}{
"orderGoodIds": orderGoodSavedIds,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ... @@ -854,6 +857,7 @@ func (dividendsEstimateService *DividendsEstimateService) ConfirmDividendsIncent
"dividendsOrderNumbers": dividendsOrderNumbers,
"companyId": confirmDividendsIncentivesEstimateCommand.CompanyId,
"orgId": confirmDividendsIncentivesEstimateCommand.OrgId,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ... @@ -897,6 +901,7 @@ func (dividendsEstimateService *DividendsEstimateService) ConfirmDividendsIncent
"dividendsReturnedOrderNumbers": dividendsReturnedOrderNumbers,
"companyId": confirmDividendsIncentivesEstimateCommand.CompanyId,
"orgId": confirmDividendsIncentivesEstimateCommand.OrgId,
"offsetLimit": false,
}); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
} else {
... ...