|  |  | 
 |  |  | import com.dy.pmsGlobal.pojoPlt.PltProductFile; | 
 |  |  | import jakarta.servlet.http.HttpServletResponse; | 
 |  |  | import lombok.extern.slf4j.Slf4j; | 
 |  |  | import org.apache.commons.collections4.CollectionUtils; | 
 |  |  | import org.apache.dubbo.common.utils.PojoUtils; | 
 |  |  | import org.springframework.beans.factory.annotation.Autowired; | 
 |  |  | import org.springframework.beans.factory.annotation.Value; | 
 |  |  | 
 |  |  |  | 
 |  |  |     private void saveRel(PltProduct p, List<PltProductFile> docs) { | 
 |  |  |         docs.forEach(doc -> { | 
 |  |  |             if(doc.id == null){ | 
 |  |  |                 doc.proId = p.id; | 
 |  |  |                 pfDao.insertSelective(doc); | 
 |  |  |             } | 
 |  |  |         }); | 
 |  |  |     } | 
 |  |  |  | 
 |  |  | 
 |  |  |  | 
 |  |  |             pro.proFiles.stream().forEach(doc -> { | 
 |  |  |                  OthFile file = othFileMapper.selectByPrimaryKey(doc.fileId); | 
 |  |  |                  if (file == null) { | 
 |  |  |                      return; | 
 |  |  |                  } | 
 |  |  |                  FileRestVo fileRestVo = fileOperate.parseHashcode(fmUrl, file.hash); | 
 |  |  |  | 
 |  |  |                  doc.webUrl = fileRestVo.fileWebUrl + file.filePath; | 
 |  |  | 
 |  |  |         rsVo.calculateAndSet(itemTotal, params); | 
 |  |  |         //查询符合条件的记录 | 
 |  |  |         rsVo.obj = dao.selectSome(params) ; | 
 |  |  |         if(CollectionUtils.isNotEmpty(rsVo.obj)){ | 
 |  |  |             rsVo.obj.forEach(pro->{ | 
 |  |  |                 pro = addWebUrl(pro); | 
 |  |  |             }); | 
 |  |  |         } | 
 |  |  |         return rsVo ; | 
 |  |  |     } | 
 |  |  |  |