xiejun
2023-11-29 54036dc2ebc591f891f452b3b248594d60fc583e
Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/controller/MdmEngineController.java
@@ -5,16 +5,13 @@
import com.alibaba.nacos.common.utils.StringUtils;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.vci.ubcs.code.dto.CodeDeleteBatchDTO;
import com.vci.ubcs.code.dto.CodeExportAttrDTO;
import com.vci.ubcs.code.dto.CodeOrderDTO;
import com.vci.ubcs.code.dto.CodeOrderSecDTO;
import com.vci.ubcs.code.applyjtcodeservice.vo.BaseModelVO;
import com.vci.ubcs.code.dto.*;
import com.vci.ubcs.code.dto.datapush.BaseModelDTO;
import com.vci.ubcs.code.service.MdmEngineService;
import com.vci.ubcs.code.service.MdmIOService;
import com.vci.ubcs.code.vo.pagemodel.*;
import com.vci.ubcs.flow.core.feign.IMDMIFlowAttrClient;
import com.vci.ubcs.omd.vo.BtmTypeVO;
import com.vci.ubcs.flow.core.dto.FlowStatusDTO;
import com.vci.ubcs.starter.annotation.VciBusinessLog;
import com.vci.ubcs.starter.revision.model.BaseModel;
import com.vci.ubcs.starter.revision.model.TreeQueryObject;
@@ -35,6 +32,7 @@
import java.io.File;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.rmi.ServerException;
import java.util.*;
@RestController
@@ -80,6 +78,7 @@
         ControllerUtil.writeDataToResponse(response,msg.getBytes(StandardCharsets.UTF_8),null);
      }
   }
   /**
    * 下载批量申请的导入模板
    * @param codeClassifyOid 分类的主键
@@ -100,8 +99,6 @@
         }
         ControllerUtil.writeDataToResponse(response,msg.getBytes(StandardCharsets.UTF_8),null);
      }
   }
   /**
@@ -238,6 +235,7 @@
         file1.delete();
      }
   }
   /**
    * 导入历史数据
    * @param codeClassifyOid 分类的主键
@@ -279,7 +277,6 @@
         R r = R.fail("导入失败");
         r.setData(codeImProtRusultVO);
         return r;
      }finally {
         file1.delete();
@@ -297,7 +294,6 @@
      return R.success("操作成功!");
   }
   /**
    * 申请编码保存
    * @param orderDTO 编码申请相关的信息,需要有属性和码段相关的信息
@@ -308,7 +304,6 @@
   public R addSaveCode(@RequestBody CodeOrderDTO orderDTO) throws Exception {
      return R.success(engineService.addSaveCode(orderDTO));
   }
   /**
    * 使用模板的主键获取表单的定义
@@ -390,7 +385,6 @@
      //TODO后续可以定义查询模板来查询
      return engineService.gridTableDataByClassifyOid(codeClassifyOid,templateOid,queryObject.getConditionMap(),queryObject.getPageHelper());
   }
   /***
    * 获取分类对象
@@ -658,7 +652,6 @@
      return engineService.getFlowUIInfoByClassifyOid(codeClassifyOid,functionId,templateId,taskId,modelKey);
   }
   @GetMapping("/thisistest")
   @ResponseBody
   public Integer thisistest(String codeClassifyOid, String functionId) throws Exception {
@@ -726,8 +719,8 @@
    * @param referConfigVO 参照的配置信息
    * @return 执行的结果
    */
   @GetMapping("/defaultReferDataGrid")
   public IPage<BaseModel> defaultReferDataGrid(UIFormReferVO referConfigVO, BaseQueryObject baseQueryObject){
   @RequestMapping(value = "/defaultReferDataGrid",method = {RequestMethod.POST, RequestMethod.GET})
   public IPage<BaseModelVO> defaultReferDataGrid(UIFormReferVO referConfigVO, BaseQueryObject baseQueryObject){
      return engineService.referDataGrid(referConfigVO,baseQueryObject);
   }
@@ -741,4 +734,24 @@
      return engineService.referTree(referConfigVO,queryObject);
   }
   /**
    * 流程中变更状态的简易接口
    * @param flowDTO 流程中携带的body
    * @return
    */
   @PostMapping("/processChangeStatus")
   public R processChangeStatus(@RequestBody FlowStatusDTO flowDTO){
      return engineService.processChangeStatus(flowDTO);
   }
   /**
    * 标准申请和修订用
    * @param codeBZApplyDTO 编码申请相关的信息,需要有属性和码段相关的信息
    * @return 执行结果
    */
   @PostMapping("/addSaveBZ")
   @VciBusinessLog(operateName = "申请单个编码")
   public R addSaveBZ (@RequestBody CodeBZApplyDTO codeBZApplyDTO) throws Exception {
      return R.success(engineService.addSaveBZ(codeBZApplyDTO));
   }
}