| | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.vci.ubcs.code.applyjtcodeservice.vo.BaseModelVO; |
| | | 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.dto.*; |
| | | import com.vci.ubcs.code.dto.datapush.BaseModelDTO; |
| | | import com.vci.ubcs.code.service.MdmEngineService; |
| | | import com.vci.ubcs.code.service.MdmIOService; |
| | |
| | | ControllerUtil.writeDataToResponse(response,msg.getBytes(StandardCharsets.UTF_8),null); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 下载批量申请的导入模板 |
| | | * @param codeClassifyOid 分类的主键 |
| | |
| | | } |
| | | ControllerUtil.writeDataToResponse(response,msg.getBytes(StandardCharsets.UTF_8),null); |
| | | } |
| | | |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | 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)); |
| | | } |
| | | |
| | | /** |
| | | * 下载批量申请的导入模板 |
| | | * @param codeClassifyOid 分类的主键 |
| | | * @param response 响应对象 |
| | | * @throws IOException 抛出异常 |
| | | */ |
| | | @GetMapping("/exportGroupCodeExcel") |
| | | @VciBusinessLog(operateName = "导出集团码") |
| | | public void exportGroupCodeExcel(String codeClassifyOid, HttpServletResponse response) throws IOException{ |
| | | String excelName = mdmIOService.createImportExcel(codeClassifyOid,false); |
| | | try { |
| | | ControllerUtil.writeFileToResponse(response,excelName); |
| | | } catch (Throwable e) { |
| | | //如果出错,把错误信息写到text |
| | | String msg = LangBaseUtil.getErrorMsg(e); |
| | | if(StringUtils.isBlank(msg)){ |
| | | msg = "未知错误"; |
| | | } |
| | | ControllerUtil.writeDataToResponse(response,msg.getBytes(StandardCharsets.UTF_8),null); |
| | | } |
| | | } |
| | | } |