|
@@ -86,34 +86,36 @@ public class TableFileController extends BladeController {
|
|
|
|
|
|
// 删除数据
|
|
|
tableFileService.delDataById(ids, null);
|
|
|
-
|
|
|
- List<TableFileVO> fileVOList = tableFileService.selectTableFileList(Long.parseLong(tableFile.getTabId()));
|
|
|
- // 该文本无附件
|
|
|
- if (fileVOList == null || fileVOList.size() <= 0) {
|
|
|
- UpdateWrapper<WbsTreeContract> updateWrapper = new UpdateWrapper<>();
|
|
|
- updateWrapper.in("p_key_id", tableFile.getTabId());
|
|
|
- updateWrapper.set("tab_file_type", 1);
|
|
|
- wbsTreeContractService.update(updateWrapper);
|
|
|
- }
|
|
|
- Long pkeyId = Long.parseLong(tableFile.getTabId() + "");
|
|
|
- excelTabService.getBussPdfInfo(pkeyId);
|
|
|
-
|
|
|
- WbsTreeContract wbsTreeContract = wbsTreeContractService.getBaseMapper().selectOne(Wrappers.<WbsTreeContract>query().lambda()
|
|
|
- .eq(WbsTreeContract::getPKeyId, pkeyId));
|
|
|
-
|
|
|
- WbsTreeContract wbsTreeContractP = wbsTreeContractService.getBaseMapper().selectOne(Wrappers.<WbsTreeContract>query().lambda()
|
|
|
- .eq(WbsTreeContract::getContractId, wbsTreeContract.getContractId())
|
|
|
- .eq(WbsTreeContract::getProjectId, wbsTreeContract.getProjectId())
|
|
|
- .eq(WbsTreeContract::getId, wbsTreeContract.getParentId())
|
|
|
- );
|
|
|
- String classfy = "1";
|
|
|
- String dataInfo = wbsTreeContract.getTableOwner();
|
|
|
- if (dataInfo.equals("1") || dataInfo.equals("2") || dataInfo.equals("3")) {
|
|
|
- classfy = "1";
|
|
|
- } else if (dataInfo.equals("4") || dataInfo.equals("5") || dataInfo.equals("6")) {
|
|
|
- classfy = "2";
|
|
|
+ //如果为节点附件,则不去做其他处理,只删除
|
|
|
+ if (tableFile.getType() == 1 || tableFile.getType() == 2) {
|
|
|
+ List<TableFileVO> fileVOList = tableFileService.selectTableFileList(Long.parseLong(tableFile.getTabId()));
|
|
|
+ // 该文本无附件
|
|
|
+ if (fileVOList == null || fileVOList.size() <= 0) {
|
|
|
+ UpdateWrapper<WbsTreeContract> updateWrapper = new UpdateWrapper<>();
|
|
|
+ updateWrapper.in("p_key_id", tableFile.getTabId());
|
|
|
+ updateWrapper.set("tab_file_type", 1);
|
|
|
+ wbsTreeContractService.update(updateWrapper);
|
|
|
+ }
|
|
|
+ Long pkeyId = Long.parseLong(tableFile.getTabId() + "");
|
|
|
+ excelTabService.getBussPdfInfo(pkeyId);
|
|
|
+
|
|
|
+ WbsTreeContract wbsTreeContract = wbsTreeContractService.getBaseMapper().selectOne(Wrappers.<WbsTreeContract>query().lambda()
|
|
|
+ .eq(WbsTreeContract::getPKeyId, pkeyId));
|
|
|
+
|
|
|
+ WbsTreeContract wbsTreeContractP = wbsTreeContractService.getBaseMapper().selectOne(Wrappers.<WbsTreeContract>query().lambda()
|
|
|
+ .eq(WbsTreeContract::getContractId, wbsTreeContract.getContractId())
|
|
|
+ .eq(WbsTreeContract::getProjectId, wbsTreeContract.getProjectId())
|
|
|
+ .eq(WbsTreeContract::getId, wbsTreeContract.getParentId())
|
|
|
+ );
|
|
|
+ String classfy = "1";
|
|
|
+ String dataInfo = wbsTreeContract.getTableOwner();
|
|
|
+ if (dataInfo.equals("1") || dataInfo.equals("2") || dataInfo.equals("3")) {
|
|
|
+ classfy = "1";
|
|
|
+ } else if (dataInfo.equals("4") || dataInfo.equals("5") || dataInfo.equals("6")) {
|
|
|
+ classfy = "2";
|
|
|
+ }
|
|
|
+ excelTabService.getBussPdfs(wbsTreeContractP.getPKeyId() + "", classfy, wbsTreeContract.getContractId(), wbsTreeContract.getProjectId());
|
|
|
}
|
|
|
- excelTabService.getBussPdfs(wbsTreeContractP.getPKeyId() + "", classfy, wbsTreeContract.getContractId(), wbsTreeContract.getProjectId());
|
|
|
return R.status(true);
|
|
|
}
|
|
|
|