|  |  | @ -7,6 +7,7 @@ import com.glxp.api.admin.entity.basic.UdiCompanyEntity; | 
			
		
	
		
		
			
				
					
					|  |  |  | import com.glxp.api.admin.req.basic.UdiCompanyRequest; |  |  |  | import com.glxp.api.admin.req.basic.UdiCompanyRequest; | 
			
		
	
		
		
			
				
					
					|  |  |  | import com.glxp.api.admin.req.receipt.ProductInfoFilterRequest; |  |  |  | import com.glxp.api.admin.req.receipt.ProductInfoFilterRequest; | 
			
		
	
		
		
			
				
					
					|  |  |  | import com.glxp.api.admin.res.PageSimpleResponse; |  |  |  | import com.glxp.api.admin.res.PageSimpleResponse; | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  | import com.glxp.api.admin.util.RedisUtil; | 
			
		
	
		
		
			
				
					
					|  |  |  | import com.glxp.api.common.res.BaseResponse; |  |  |  | import com.glxp.api.common.res.BaseResponse; | 
			
		
	
		
		
			
				
					
					|  |  |  | import com.glxp.api.common.util.ResultVOUtils; |  |  |  | import com.glxp.api.common.util.ResultVOUtils; | 
			
		
	
		
		
			
				
					
					|  |  |  | import org.springframework.stereotype.Service; |  |  |  | import org.springframework.stereotype.Service; | 
			
		
	
	
		
		
			
				
					|  |  | @ -24,6 +25,9 @@ public class SyncUdiService { | 
			
		
	
		
		
			
				
					
					|  |  |  |     @Resource |  |  |  |     @Resource | 
			
		
	
		
		
			
				
					
					|  |  |  |     UdiCompanyService udiCompanyService; |  |  |  |     UdiCompanyService udiCompanyService; | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |     @Resource | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |     RedisUtil redisUtil; | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |     public BaseResponse filterUdi(ProductInfoFilterRequest productInfoFilterRequest) { |  |  |  |     public BaseResponse filterUdi(ProductInfoFilterRequest productInfoFilterRequest) { | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |         //过滤--1.参数不能全未空
 |  |  |  |         //过滤--1.参数不能全未空
 | 
			
		
	
	
		
		
			
				
					|  |  | @ -60,10 +64,12 @@ public class SyncUdiService { | 
			
		
	
		
		
			
				
					
					|  |  |  |                 return ResultVOUtils.error(500, "请输入医疗器械注册备案人名称"); |  |  |  |                 return ResultVOUtils.error(500, "请输入医疗器械注册备案人名称"); | 
			
		
	
		
		
			
				
					
					|  |  |  |             } |  |  |  |             } | 
			
		
	
		
		
			
				
					
					|  |  |  |         } |  |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |  |         if ( |  |  |  | 
 | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |                 StrUtil.isEmpty(productInfoFilterRequest.getYlqxzcrbarmc()) |  |  |  | 
 | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         if ((productInfoFilterRequest.getYlqxzcrbarmc() == null || productInfoFilterRequest.getYlqxzcrbarmc().equals("")) | 
			
		
	
		
		
			
				
					
					|  |  |  |                 && (productInfoFilterRequest.getNameCode() == null || productInfoFilterRequest.getNameCode().equals("")) |  |  |  |                 && (productInfoFilterRequest.getNameCode() == null || productInfoFilterRequest.getNameCode().equals("")) | 
			
		
	
		
		
			
				
					
					|  |  |  |                 && (productInfoFilterRequest.getCpmctymc() == null || productInfoFilterRequest.getCpmctymc().equals("")) |  |  |  |                 && (productInfoFilterRequest.getCpmctymc() == null || productInfoFilterRequest.getCpmctymc().equals("")) | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |         ) { |  |  |  |         ) { | 
			
		
	
		
		
			
				
					
					|  |  |  |             if (productInfoFilterRequest.getGgxh() != null && !productInfoFilterRequest.getGgxh().equals("")) { |  |  |  |             if (productInfoFilterRequest.getGgxh() != null && !productInfoFilterRequest.getGgxh().equals("")) { | 
			
		
	
		
		
			
				
					
					|  |  |  |                 return ResultVOUtils.error(500, "请输入医疗器械注册备案人名称"); |  |  |  |                 return ResultVOUtils.error(500, "请输入医疗器械注册备案人名称"); | 
			
		
	
	
		
		
			
				
					|  |  | @ -73,13 +79,28 @@ public class SyncUdiService { | 
			
		
	
		
		
			
				
					
					|  |  |  |             } |  |  |  |             } | 
			
		
	
		
		
			
				
					
					|  |  |  |         } |  |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         if (productInfoFilterRequest.getCpmctymc() != null && !productInfoFilterRequest.getCpmctymc().equals("") && productInfoFilterRequest.getCpmctymc().length() < 4) { | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             return ResultVOUtils.error(500, "请输入完整的产品通用名称!"); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |  |         productInfoFilterRequest.setIsNewest(1); |  |  |  |         productInfoFilterRequest.setIsNewest(1); | 
			
		
	
		
		
			
				
					
					|  |  |  |         productInfoFilterRequest.setDiType("1"); |  |  |  |         productInfoFilterRequest.setDiType("1"); | 
			
		
	
		
		
			
				
					
					|  |  |  |         List<ProductInfoEntity> productInfoEntityList = productInfoService.filterUdi(productInfoFilterRequest); |  |  |  | 
 | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         PageInfo<ProductInfoEntity> pageInfo; |  |  |  |         String keyCache = productInfoFilterRequest.toCacheKey(); | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         pageInfo = new PageInfo<>(productInfoEntityList); |  |  |  |         if (StrUtil.isEmpty(keyCache)) { | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             return ResultVOUtils.error(500, "查询条件不能为空!"); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         String totalStr = (String) redisUtil.get(keyCache); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         long total = 0; | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         if (StrUtil.isEmpty(totalStr)) { | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             total = productInfoService.filterUdiNoPageCount(productInfoFilterRequest); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             redisUtil.set(keyCache, total + ""); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         } else { | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             total = Long.parseLong(totalStr); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         List<ProductInfoEntity> productInfoEntityList = productInfoService.filterUdiNoPage(productInfoFilterRequest); | 
			
		
	
		
		
			
				
					
					|  |  |  |         PageSimpleResponse<ProductInfoEntity> pageSimpleResponse = new PageSimpleResponse<>(); |  |  |  |         PageSimpleResponse<ProductInfoEntity> pageSimpleResponse = new PageSimpleResponse<>(); | 
			
		
	
		
		
			
				
					
					|  |  |  |         pageSimpleResponse.setTotal(pageInfo.getTotal()); |  |  |  |         pageSimpleResponse.setTotal(total); | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					|  |  |  |         pageSimpleResponse.setList(productInfoEntityList); |  |  |  |         pageSimpleResponse.setList(productInfoEntityList); | 
			
		
	
		
		
			
				
					
					|  |  |  |         return ResultVOUtils.success(pageSimpleResponse); |  |  |  |         return ResultVOUtils.success(pageSimpleResponse); | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
	
		
		
			
				
					|  |  | 
 |