| | |
| | | return safeMaterialInfo; |
| | | } |
| | | |
| | | /** |
| | | * 根据类型统计数据 |
| | | */ |
| | | @Override |
| | | public int getCountByClassify(Long classifyId){ |
| | | if(null == classifyId){ |
| | | throw new EquipmentException(ResultCodes.CLIENT_PARAM_NULL); |
| | | } |
| | | return repository.getCountByClassify(classifyId); |
| | | } |
| | | |
| | | @Override |
| | | public int deleteBatch(List<Long> ids) { |
| | | if(null == ids || ids.size() == 0){ |
| | |
| | | return materialInfoList; |
| | | } |
| | | |
| | | @Override |
| | | public int getCountBySmallClassifyId(Long smallClassifyId) { |
| | | if(null == smallClassifyId){ |
| | | throw new EquipmentException(ResultCodes.CLIENT_PARAM_NULL); |
| | | } |
| | | return repository.getCountBySmallClassifyId(smallClassifyId); |
| | | } |
| | | |
| | | @Override |
| | | public boolean checkMaterial(Long smallClassifyId, Long depId, Long id) { |
| | | if(null == depId || null == smallClassifyId){ |
| | | throw new EquipmentException(ResultCodes.CLIENT_PARAM_NULL); |
| | | } |
| | | boolean flag = false; |
| | | int i = repository.checkMatrial(smallClassifyId,depId,id); |
| | | if (i>0){ |
| | | flag = true; |
| | | } |
| | | return flag; |
| | | } |
| | | |
| | | |
| | | } |