| | |
| | | import com.ruoyi.basic.service.StandardMethodListService; |
| | | import com.ruoyi.basic.service.StandardProductListService; |
| | | import com.ruoyi.basic.service.StandardProductListUpdateRecordService; |
| | | import com.ruoyi.common.config.MinioConfig; |
| | | import com.ruoyi.common.core.domain.MinioResult; |
| | | import com.ruoyi.common.exception.base.BaseException; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | |
| | | @Resource |
| | | private MinioUtils minioUtils; |
| | | |
| | | @Value("${minio.bucketName}") |
| | | private String bucketName; |
| | | @Autowired |
| | | private MinioConfig minioConfig; |
| | | |
| | | /** |
| | | * 标准树下检验项修改记录分页查询 |
| | |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<StandardProductListUpdateRecordDto> standardProductListRecordPage(Page page, StandardProductListUpdateRecord record) { |
| | | return standardProductListUpdateRecordMapper.standardProductListRecordPage(page,QueryWrappers.queryWrappers(record)); |
| | | public IPage<StandardProductListUpdateRecordDto> standardProductListRecordPage(Page page, StandardProductListUpdateRecordDto record) { |
| | | return standardProductListUpdateRecordMapper.standardProductListRecordPage(page,record); |
| | | } |
| | | |
| | | /** |
| | | * 标准树下检验项修改记录分页查询 |
| | | * @param page |
| | | * 标准树下检验项修改记录查询 |
| | | * @param standardProductListUpdateRecordRel |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<StandardProductListUpdateRecordRel> standardProductListRecordRelPage(Page page, StandardProductListUpdateRecordRel standardProductListUpdateRecordRel) { |
| | | return standardProductListUpdateRecordRelMapper.standardProductListRecordRelPage(page,QueryWrappers.queryWrappers(standardProductListUpdateRecordRel)); |
| | | public Map<String,Object> standardProductListRecordRelPage(StandardProductListUpdateRecordRel standardProductListUpdateRecordRel) { |
| | | Map<String, Object> resultMap = new HashMap<>(); |
| | | List<StandardProductListUpdateRecordRel> recordRelList = standardProductListUpdateRecordRelMapper.standardProductListRecordRelPage(QueryWrappers.queryWrappers(standardProductListUpdateRecordRel)); |
| | | resultMap.put("productList",recordRelList); |
| | | resultMap.put("total",recordRelList.size()); |
| | | return resultMap; |
| | | } |
| | | |
| | | /** |
| | |
| | | @Override |
| | | public void uploadRecordFile(MultipartFile file, Long id) { |
| | | try { |
| | | MinioResult result = minioUtils.upload(bucketName, file, true); |
| | | MinioResult result = minioUtils.upload(minioConfig.getBucketName(), file, true); |
| | | // 保存路径 |
| | | StandardProductListUpdateRecord standardProductListUpdateRecord = new StandardProductListUpdateRecord(); |
| | | standardProductListUpdateRecord.setId(id); |