From e51b66b8a4a502e31f3f0056012e4eb4863f3d8e Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期五, 06 十二月 2024 16:12:44 +0800
Subject: [PATCH] UI数据查询接口添加支持自定义类查询方式查询的代码逻辑
---
Source/plt-web/plt-web-parent/plt-web/src/main/java/com/vci/web/service/OsBtmServiceI.java | 219 +++++++++++++++++++++++++++++++++++++++++++++++++++---
1 files changed, 207 insertions(+), 12 deletions(-)
diff --git a/Source/plt-web/plt-web-parent/plt-web/src/main/java/com/vci/web/service/OsBtmServiceI.java b/Source/plt-web/plt-web-parent/plt-web/src/main/java/com/vci/web/service/OsBtmServiceI.java
index 85b5146..9e10ef7 100644
--- a/Source/plt-web/plt-web-parent/plt-web/src/main/java/com/vci/web/service/OsBtmServiceI.java
+++ b/Source/plt-web/plt-web-parent/plt-web/src/main/java/com/vci/web/service/OsBtmServiceI.java
@@ -1,13 +1,19 @@
package com.vci.web.service;
+import com.vci.corba.common.PLException;
import com.vci.corba.omd.btm.BizType;
-import com.vci.pagemodel.OsBtmTypeAttributeVO;
-import com.vci.pagemodel.OsBtmTypeVO;
-import com.vci.pagemodel.OsERVO;
-import com.vci.pagemodel.OsUsedAttributeVO;
+import com.vci.dto.OsBtmTypeDTO;
+import com.vci.model.IndexObject;
+import com.vci.pagemodel.*;
+import com.vci.starter.web.pagemodel.BaseResult;
import com.vci.starter.web.pagemodel.DataGrid;
import com.vci.starter.web.pagemodel.PageHelper;
+import com.vci.starter.web.pagemodel.Tree;
+import org.springframework.web.multipart.MultipartFile;
+import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
+import java.text.ParseException;
import java.util.Collection;
import java.util.List;
import java.util.Map;
@@ -20,10 +26,48 @@
public interface OsBtmServiceI extends OsBaseServiceI{
/**
+ * 淇敼涓氬姟绫诲瀷涓搴斿睘鎬у悕鐨勫睘鎬�
+ * @param apName
+ * @return
+ * @throws PLException
+ */
+ boolean alterAp(String apName) throws PLException;
+
+ /**
+ * 鍒ゆ柇璇ュ睘鎬ф槸鍚﹀凡缁忓湪涓氬姟绫诲瀷涓骇鐢熶簡鏁版嵁
+ * @param abName
+ * @return
+ * @throws PLException
+ */
+ boolean hasInstance(String abName) throws PLException;
+
+ /**
* 鏌ヨ鎵�鏈夌殑涓氬姟绫诲瀷
* @return 涓氬姟绫诲瀷瀵硅薄
*/
List<OsBtmTypeVO> selectAllBtm();
+ /**
+ * 鏌ヨ鎵�鏈夌殑涓氬姟绫诲瀷
+ * @return 涓氬姟绫诲瀷瀵硅薄
+ */
+ List<OsBtmTypeVO> selectAllBtm(Map<String, OsAttributeVO> attributeVOMap);
+
+ /**
+ * 鑾峰彇鍚嶅瓧浠ilter寮�濮嬬殑涓氬姟绫诲瀷(for 鏌ヨ)锛屼富瑕佺敤浜庡睘鎬ф睜鐨勪笟鍔$被鍨嬮�夋嫨瀵硅瘽妗�
+ * 鑾峰彇鍏ㄩ儴涓氬姟绫诲瀷锛屼紶鍙俧ilter涓�""
+ * @param btmName
+ * @return
+ * @throws PLException
+ */
+ BizType[] getBizTypes(String btmName) throws PLException;
+
+ /**
+ * 涓氬姟绫诲瀷鍒楄〃鏌ヨ锛岄潪鏍戠粨鏋勶細鐢ㄤ簬UI瀹氫箟宸︿晶涓氬姟绫诲瀷鏌ヨ锛屽彧杩斿洖name鍜宭able
+ * @param btmName
+ * @return
+ * @throws PLException
+ */
+ Tree getBizTree(String btmName) throws PLException;
/**
* 鏌ヨ鎵�鏈夌殑涓氬姟绫诲瀷鏄犲皠
@@ -32,18 +76,24 @@
Map<String,OsBtmTypeVO> selectAllBtmMap();
/**
+ * 鏌ヨ鎵�鏈夌殑涓氬姟绫诲瀷鏄犲皠
+ * @return key 鏄笟鍔$殑鑻辨枃鍚嶇О鐨勫皬鍐�
+ */
+ Map<String,OsBtmTypeVO> selectAllBtmMap(Map<String, OsAttributeVO> attributeVOMap);
+
+ /**
* 鏁版嵁瀵硅薄杞崲涓烘樉绀哄璞�
* @param btmItems 鏁版嵁瀵硅薄
* @return 鏄剧ず瀵硅薄
*/
- List<OsBtmTypeVO> btmDO2VOs(Collection<BizType> btmItems);
+ List<OsBtmTypeVO> btmDO2VOs(Collection<BizType> btmItems,Map<String, OsAttributeVO> attributeVOMap);
/**
* 鏁版嵁瀵硅薄杞崲涓烘樉绀哄璞�
* @param btmItem 鏁版嵁瀵硅薄
* @return 鏄剧ず瀵硅薄
*/
- OsBtmTypeVO btmDO2VO(BizType btmItem);
+ OsBtmTypeVO btmDO2VO(BizType btmItem, Map<String, OsAttributeVO> attributeVOMap);
/**
* 浣跨敤缂栧彿鑾峰彇涓氬姟绫诲瀷
@@ -53,11 +103,27 @@
List<OsBtmTypeVO> listBtmByIds(Collection<String> btmIds);
/**
+ * TODO:灏介噺鍒敤杩欎釜鏂规硶寰堟參锛屽仛浜嗕竴娆″叏鏌ュ啀杞潵杞幓
* 浣跨敤缂栧彿鑾峰彇涓氬姟绫诲瀷
* @param id 缂栧彿
* @return 涓氬姟绫诲瀷
*/
- OsBtmTypeVO getBtmById(String id);
+ OsBtmTypeVO getBtmById(String id) throws PLException;
+
+ /**
+ * 浣跨敤绫诲瀷鍚嶈幏鍙栦笟鍔$被鍨�,鏌ヤ笉鍒扮洿鎺ユ姤閿�
+ * @param btmName 绫诲瀷鍚�
+ * @return 涓氬姟绫诲瀷
+ * @throws
+ */
+ OsBtmTypeVO getBtmByName(String btmName) throws PLException;
+
+ /**
+ * 浣跨敤缂栧彿鑾峰彇涓氬姟绫诲瀷
+ * @param id 缂栧彿
+ * @return 涓氬姟绫诲瀷
+ */
+ OsBtmTypeVO getBtmById(String id, Map<String, OsAttributeVO> attributeVOMap);
/**
* 鑾峰彇涓氬姟绫诲瀷鐨勫湪鍝釜灞炴�т腑浣跨敤
@@ -80,14 +146,14 @@
* @param btmId 涓氬姟绫诲瀷鐨勭紪鍙�
* @return 灞炴�х殑鍐呭
*/
- List<OsBtmTypeAttributeVO> listAttributeByBtmId(String btmId);
+ List<OsBtmTypeAttributeVO> listAttributeByBtmId(String btmId) throws PLException;
/**
* 鏍规嵁涓氬姟绫诲瀷鑾峰彇鍖呭惈鐨勫睘鎬�--鍖呭惈鍩虹灞炴��
* @param btmId 涓氬姟绫诲瀷鐨勭紪鍙�
* @return 灞炴�х殑鍐呭
*/
- List<OsBtmTypeAttributeVO> listAttributeByBtmIdHasDefault(String btmId);
+ List<OsBtmTypeAttributeVO> listAttributeByBtmIdHasDefault(String btmId) throws PLException;
/**
* 鍙傜収涓氬姟绫诲瀷
@@ -110,18 +176,147 @@
* @param id 鏋氫妇鐨勮嫳鏂�
* @return 鏋氫妇鐨勫悕绉�
*/
- String getNameById(String id);
+ String getNameById(String id) throws PLException;
/**
* 鏍规嵁涓氬姟绫诲瀷鍜岄摼鎺ョ被鍨嬬敓鎴怑R鍥�
* @param btmId 涓氬姟绫诲瀷涓婚敭
*/
- OsERVO createERDiagram(String btmId);
+ OsERVO createERDiagram(String btmId) throws PLException;
/**
* 鑾峰彇浣跨敤杩欎釜涓氬姟绫诲瀷鐨凟-R鍥�
* @param btmId 涓氬姟绫诲瀷缂栧彿
* @return 鎵ц缁撴灉
*/
- OsERVO createERUsed(String btmId);
+ OsERVO createERUsed(String btmId) throws PLException;
+
+ /**
+ * 鑾峰彇鎵�鏈変笟鍔$被鍨嬶紙鏍戝舰缁撴瀯锛�
+ * @return 鏌ヨ缁撴灉
+ */
+ List<Tree> getTreeBizTypes() throws PLException;
+
+ /**
+ * 鑾峰彇鎵�鏈変笟鍔$被鍨嬪悕绉伴泦鍚�
+ * @return
+ */
+ List<String> getAllBtmName() throws PLException;
+
+ /**
+ * 鑾峰彇涓氬姟鍏ㄩ儴灞炴�х被鍨�
+ * @param btmName 涓氬姟绫诲瀷鍚嶇О
+ * @return 灞炴�х殑淇℃伅
+ */
+ List<OsBtmTypeAttributeVO> getBizTypeQTDs(String btmName) throws PLException, ParseException;
+
+ /**
+ * 鍒涘缓鏂扮殑涓氬姟绫诲瀷
+ * @return
+ * @throws PLException
+ */
+ boolean addBtmType(OsBtmTypeDTO btmTypeDTO) throws PLException;
+
+ /**
+ * 鎵归噺鏂板涓氬姟绫诲瀷
+ * @param bizTypes
+ * @return
+ */
+ //boolean addBtmTypes(List<BizType> bizTypes);
+
+ /**
+ * 淇敼涓氬姟绫诲瀷
+ * @param btmTypeDTO
+ * @return
+ * @throws PLException
+ */
+ boolean updateBtmType(OsBtmTypeDTO btmTypeDTO) throws PLException;
+
+ /**
+ * 鍒犻櫎涓氬姟绫诲瀷
+ * @param btmTypeDTO
+ * @return
+ * @throws PLException
+ */
+ boolean deleteBtmType(OsBtmTypeDTO btmTypeDTO) throws PLException;
+
+ /**
+ * 涓�鑷存�ф鏌�
+ * @return
+ * @throws PLException
+ */
+ BaseResult checkBtmConsistency() throws PLException;
+
+ /**
+ * 涓�鑷存�ф鏌ヤ慨澶嶅姛鑳�
+ * @param repairData
+ * @return
+ */
+ BaseResult executeRepair(String repairData) throws Exception;
+
+ /**
+ * 鍒涘缓瑙嗗浘
+ * @return
+ * @throws PLException
+ */
+ boolean createView() throws PLException;
+
+ /**
+ * 鍒犻櫎鏁版嵁鐣岄潰鐨勬煡璇�
+ * @return 涓氬姟绫诲瀷锛岄摼鎺ョ被鍨�
+ */
+ BaseResult getObjectData() throws PLException;
+
+ /**
+ * 鍒犻櫎鏁版嵁
+ * @param btmNames 涓氬姟绫诲瀷鍚�
+ * @param linkNames 閾炬帴绫诲瀷鍚�
+ * @return
+ * @throws PLException
+ */
+ List<Map> truncateTable(String[] btmNames,String[] linkNames) throws PLException;
+
+ /**
+ * 鍒犻櫎鍏ㄩ儴绫诲瀷
+ * @return
+ * @throws PLException
+ */
+ BaseResult deleteAllType() throws PLException;
+
+ /**
+ * 鏍规嵁涓氬姟绫诲瀷鍚嶇О鍜岀储寮曞悕绉版煡璇㈣幏鍙栧凡鏈夌殑绱㈠紩
+ * @param conditionMap 鏍规嵁鏌ヨ鏉′欢浼犲弬: typename:涓氬姟绫诲瀷鍚�;indexname:绱㈠紩鍚�
+ * @return
+ */
+ List<IndexObject> getIndexByCondition(Map<String,String> conditionMap) throws PLException;
+
+ /**
+ * 鏍规嵁涓氬姟绫诲瀷鍚嶇О鍜屽叾涓嬬殑灞炴�у悕绉板垹闄ょ储寮�
+ * @param btmName
+ * @param indexName
+ * @return
+ */
+ boolean delIndex(String btmName,String indexName) throws PLException;
+
+ /**
+ * 缁欎笟鍔$被鍨嬩笅鐨勬寚瀹氬睘鎬ф柊澧炵储寮�
+ * @param indexObjectList
+ * @return
+ */
+ boolean addIndex(List<IndexObject> indexObjectList) throws PLException;
+
+ /**
+ * 瀵煎嚭涓氬姟绫诲瀷
+ * oid 涓氬姟绫诲瀷鍚嶇О
+ * @return
+ */
+ void expData(String oid, HttpServletResponse response) throws PLException, IOException;
+
+ /**
+ * 瀵煎叆涓氬姟绫诲瀷
+ * @param file 涓婁紶鐨勬枃浠�
+ * @return
+ */
+ BaseResult impData(MultipartFile file) throws Exception;
+
}
--
Gitblit v1.9.3