| | |
| | | package com.vci.web.controller; |
| | | |
| | | import com.vci.corba.common.PLException; |
| | | import com.vci.corba.omd.ltm.LinkType; |
| | | import com.vci.corba.omd.qtm.QTD; |
| | | import com.vci.dto.QTInfoDTO; |
| | | import com.vci.pagemodel.OsBtmTypeAttributeVO; |
| | | import com.vci.pagemodel.OsBtmTypeVO; |
| | | import com.vci.pagemodel.OsLinkTypeAttributeVO; |
| | | import com.vci.pagemodel.OsLinkTypeVO; |
| | | import com.vci.starter.web.annotation.controller.VciUnCheckRight; |
| | | import com.vci.starter.web.annotation.log.VciBusinessLog; |
| | | import com.vci.starter.web.exception.VciBaseException; |
| | | import com.vci.starter.web.pagemodel.BaseQueryObject; |
| | | import com.vci.starter.web.pagemodel.BaseResult; |
| | | import com.vci.starter.web.pagemodel.DataGrid; |
| | | import com.vci.starter.web.util.VciBaseUtil; |
| | | import com.vci.web.service.OsLinkTypeServiceI; |
| | | import com.vci.web.service.OsQuereyTemplateServiceI; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.dom4j.DocumentException; |
| | | import org.slf4j.Logger; |
| | | import org.slf4j.LoggerFactory; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.util.CollectionUtils; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.IOException; |
| | | import java.util.Arrays; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * 查询模板的控制器 |
| | |
| | | public BaseResult queryTemplateList(String btmName,Boolean linkFlag){ |
| | | try { |
| | | return quereyTemplateServiceI.queryTemplateList(btmName,linkFlag); |
| | | } catch (PLException e) { |
| | | BaseResult objectBaseResult = new BaseResult<>(); |
| | | objectBaseResult.setCode(Integer.parseInt(e.code)); |
| | | objectBaseResult.setMsg(Arrays.toString(e.messages)); |
| | | return objectBaseResult; |
| | | } |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 查询模板的列表添加了字段的相关属性 |
| | | * @param btmName 类型 |
| | | * @param linkFlag 是否链接类型 :true 链接类型 ,false 业务类型 |
| | | * @return 查询模板的列表 |
| | | */ |
| | | @GetMapping("/queryTemplateListByAttr") |
| | | public BaseResult queryTemplateListByAttr(String btmName,Boolean linkFlag, String direction){ |
| | | try { |
| | | return quereyTemplateServiceI.queryTemplateListByAttr(btmName,linkFlag,direction); |
| | | } catch (PLException e) { |
| | | BaseResult objectBaseResult = new BaseResult<>(); |
| | | objectBaseResult.setCode(Integer.parseInt(e.code)); |
| | |
| | | |
| | | /** |
| | | * 查询方案删除 |
| | | * @param templateNames 查询方案名 |
| | | * @param names 查询方案名 |
| | | * @return 操作结果 |
| | | */ |
| | | @DeleteMapping("/deleteLinkTemplate") |
| | | public BaseResult deleteLinkTemplate(@RequestBody List<String> templateNames){ |
| | | public BaseResult deleteLinkTemplate(String names){ |
| | | try { |
| | | return quereyTemplateServiceI.deleteLinkTemplate(templateNames); |
| | | return quereyTemplateServiceI.deleteLinkTemplate(names); |
| | | } catch (PLException e) { |
| | | BaseResult objectBaseResult = new BaseResult<>(); |
| | | objectBaseResult.setCode(Integer.parseInt(e.code)); |