|
@@ -1887,6 +1887,17 @@ public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract>
|
|
if(dto.getDocumentarySearch()==2&&ObjectUtil.isNotEmpty(dto.getDocumentaryType())){//无记录
|
|
if(dto.getDocumentarySearch()==2&&ObjectUtil.isNotEmpty(dto.getDocumentaryType())){//无记录
|
|
wrapper.gt("t1.documentaryCount",0);
|
|
wrapper.gt("t1.documentaryCount",0);
|
|
}
|
|
}
|
|
|
|
+ if (StringUtils.isNotEmpty(dto.getKeyword())) {
|
|
|
|
+ //归属公司
|
|
|
|
+ List<Long> corporationIds = corporationService.listObject(Corporation::getId, q -> q.like(Corporation::getName, dto.getKeyword()));
|
|
|
|
+ List<Long> customerIds = customerService.listObject(Customer::getId, q -> q.like(Customer::getName, dto.getKeyword()));
|
|
|
|
+ wrapper.and(q -> q
|
|
|
|
+ .like("t1", Contract::getCode, dto.getKeyword())
|
|
|
|
+ .or().like("t1", Contract::getUserName, dto.getUserName())
|
|
|
|
+ .or().in("t1", Contract::getSellCorporationId, corporationIds)
|
|
|
|
+ .or().in("t1", Contract::getBuyCorporationId, customerIds)
|
|
|
|
+ );
|
|
|
|
+ }
|
|
Page<ContractVo> page = baseMapper.getExportCopyList(dto.getPage(), wrapper,dto.getDocumentaryType());
|
|
Page<ContractVo> page = baseMapper.getExportCopyList(dto.getPage(), wrapper,dto.getDocumentaryType());
|
|
List<ContractVo> list = page.getRecords();
|
|
List<ContractVo> list = page.getRecords();
|
|
if(CollectionUtils.isNotEmpty(list)){
|
|
if(CollectionUtils.isNotEmpty(list)){
|