|
@@ -6,6 +6,7 @@ import com.ruoyi.common.utils.document.ZipUtil;
|
|
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
|
|
import com.ruoyi.framework.aspectj.lang.annotation.Log;
|
|
|
import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
|
|
|
+import com.ruoyi.framework.config.RuoYiConfig;
|
|
|
import com.ruoyi.framework.web.controller.BaseController;
|
|
|
import com.ruoyi.framework.web.domain.AjaxResult;
|
|
|
import com.ruoyi.framework.web.page.TableDataInfo;
|
|
@@ -387,6 +388,9 @@ public class TPssrApproveController extends BaseController {
|
|
|
@Autowired
|
|
|
private TPssrTorchvocController torchvocController;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private TPssrSubcontentController subcontentController;
|
|
|
+
|
|
|
@PutMapping("/handleConfirm")
|
|
|
public AjaxResult handleConfirm(@RequestBody TPssrApproveDto dto) {
|
|
|
TPssrSubcontent tPssrSubcontent = tPssrSubcontentService.selectTPssrSubcontentById(dto.getSubId());
|
|
@@ -1601,6 +1605,16 @@ public class TPssrApproveController extends BaseController {
|
|
|
queryParams.setAboveallId(id);
|
|
|
List<TPssrSubcontent> tPssrSubcontents = tPssrSubcontentService.selectTPssrSubcontentList(queryParams);//子表集合
|
|
|
this.createSubitemDirectory(rootPath);//创建子表目录
|
|
|
+
|
|
|
+ subTitle = "00主清单/";//主清单
|
|
|
+ TPssrSubcontent subcontent = new TPssrSubcontent();
|
|
|
+ subcontent.setAboveallId(aboveall.getId());
|
|
|
+ result = subcontentController.export(subcontent);
|
|
|
+ msg = (String) result.get("msg");
|
|
|
+ path = getProfile() + msg.replace("/profile", "");
|
|
|
+ Files.copy(Paths.get(path), Paths.get(rootPath + subTitle + msg.replace("/profile/pssr/", "")), StandardCopyOption.REPLACE_EXISTING);//拷贝导出的文件
|
|
|
+ files.add(new File(rootPath + subTitle + msg));
|
|
|
+
|
|
|
for (TPssrSubcontent tPssrSubcontent : tPssrSubcontents) {
|
|
|
TPssrPatrol patrol = new TPssrPatrol();
|
|
|
patrol.setSubId(tPssrSubcontent.getId());
|
|
@@ -2241,6 +2255,7 @@ public class TPssrApproveController extends BaseController {
|
|
|
}
|
|
|
|
|
|
private void createSubitemDirectory(String rootPath) {
|
|
|
+ boolean mkdir0 = new File(rootPath + "00主清单").mkdirs();//子项文件目录
|
|
|
boolean mkdir1 = new File(rootPath + "01检修项目").mkdirs();//子项文件目录
|
|
|
boolean mkdir2 = new File(rootPath + "02开工方案").mkdirs();
|
|
|
boolean mkdir3 = new File(rootPath + "03设计变更").mkdirs();
|