From 8de1acde3345df9e2dd66a7ed707f8260fd07d76 Mon Sep 17 00:00:00 2001 From: 13693261870 <252740454@qq.com> Date: 星期五, 02 六月 2023 17:08:19 +0800 Subject: [PATCH] 3.删除bs、bd、si、md架构下的文件 --- src/main/java/com/lf/server/service/all/TestService.java | 84 +----------------------------------------- 1 files changed, 2 insertions(+), 82 deletions(-) diff --git a/src/main/java/com/lf/server/service/all/TestService.java b/src/main/java/com/lf/server/service/all/TestService.java index 8522655..907351e 100644 --- a/src/main/java/com/lf/server/service/all/TestService.java +++ b/src/main/java/com/lf/server/service/all/TestService.java @@ -1,21 +1,14 @@ package com.lf.server.service.all; -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; -import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; -import com.baomidou.mybatisplus.core.metadata.OrderItem; -import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.lf.server.entity.all.MenusAuthEntity; import com.lf.server.entity.all.PermsAuthEntity; import com.lf.server.entity.all.ResAuthEntity; -import com.lf.server.entity.bd.DlgagnpEntity; +import com.lf.server.entity.data.CoordEntity; import com.lf.server.entity.data.MetaEntity; import com.lf.server.entity.data.MetaFileEntity; -import com.lf.server.entity.md.MdzxcgEntity; import com.lf.server.helper.*; -import com.lf.server.mapper.bd.DlgagnpMapper; import com.lf.server.service.data.MetaService; import com.lf.server.service.data.UploadService; -import com.lf.server.service.show.LocateService; import com.lf.server.service.sys.ArgsService; import com.lf.server.service.sys.BlacklistService; import com.lf.server.service.sys.ReportService; @@ -25,8 +18,6 @@ import org.springframework.core.env.Environment; import org.springframework.stereotype.Service; -import java.util.ArrayList; -import java.util.HashMap; import java.util.List; import java.util.Map; @@ -44,9 +35,6 @@ ArgsService argsService; @Autowired - DlgagnpMapper dlgagnpMapper; - - @Autowired PermsService permsService; @Autowired @@ -54,9 +42,6 @@ @Autowired BaseQueryService baseQueryService; - - @Autowired - LocateService locateService; @Autowired Environment env; @@ -102,71 +87,6 @@ mf.setExtName(".shp"); uploadService.loadSpatialData(mf); - } - - public void testBatchUpdate() { - DlgagnpEntity d1 = new DlgagnpEntity(); - d1.setGid(56); - d1.setGb("10"); - d1.setName("a01"); - DlgagnpEntity d2 = new DlgagnpEntity(); - d2.setGid(57); - d2.setGb("20"); - d2.setName("a02"); - - List<DlgagnpEntity> list = new ArrayList<>(); - list.add(d1); - list.add(d2); - - int rows = dlgagnpMapper.updateBatch(list); - } - - public void testMybatisPlus() { - String s1 = locateService.selectWktById(1); - - String tabName = BaseQueryService.getTabName(dlgagnpMapper); - List<String> list0 = dlgagnpMapper.selectFieldFuzzy(tabName, "name", "%鍘�%"); - - DlgagnpEntity dlg = dlgagnpMapper.selectById(1); - String wkt = dlgagnpMapper.selectWktById(tabName, 2); - - Map<String, Object> map = new HashMap<String, Object>(3); - map.put("gid", 2); - List<DlgagnpEntity> list1 = dlgagnpMapper.selectByMap(map); - - QueryWrapper<DlgagnpEntity> w1 = new QueryWrapper<>(); - w1.eq("name", "娌诲鍘�"); - List<DlgagnpEntity> list2 = dlgagnpMapper.selectList(w1); - - UpdateWrapper<DlgagnpEntity> w2 = new UpdateWrapper<DlgagnpEntity>(); - // 璁剧疆鏇存柊鍐呭 - w2.set("name", "newName").set("gb", "10013") - // 璁剧疆鏇存柊鏉′欢 - .eq("gid", 0); - // dlgagnpMapper.update(null, w2) - - List<Integer> ids = new ArrayList<Integer>(); - ids.add(1); - ids.add(2); - // dlgagnpMapper.deleteBatchIds(ids) - List<DlgagnpEntity> list3 = dlgagnpMapper.selectBatchIds(ids); - - // dlgagnpMapper.updateById(dlg) - // List<DlgAgnp> all = dlgagnpMapper.selectList(null) - - // 椤垫暟 / 姣忛〉璁板綍鏁� - Page<DlgagnpEntity> page = new Page<>(1, 10); - // 鍗囧簭鎺掑簭 - page.addOrder(OrderItem.desc("gid")); - // 鍒嗛〉锛歐rapper鏌ヨ鏉′欢 - Page<DlgagnpEntity> userPage = dlgagnpMapper.selectPage(page, null); - // 鎬婚〉鏁� / 鎬昏褰曟暟锛�325 / 3247 - String str = userPage.getPages() + " / " + userPage.getTotal(); - List<DlgagnpEntity> list4 = userPage.getRecords(); - - QueryWrapper<DlgagnpEntity> w3 = new QueryWrapper<>(); - w3.like("name", "澶�").ge("gid", 100); - List<DlgagnpEntity> list5 = dlgagnpMapper.selectList(w3); } public void testAes() { @@ -217,7 +137,7 @@ } public void testReadExcel() { - List<?> listMdZxcg = ExcelHelper.readExcel(MdzxcgEntity.class, "D:\\LF\\data\\xls\\娴嬬粯\\1-椤圭洰鎴愭灉-瑗夸笁涓璡\1-1涓嚎鎴愭灉琛╘\娴峰師鍘夸腑绾挎垚鏋滆〃.xlsx"); + List<?> listMdZxcg = ExcelHelper.readExcel(CoordEntity.class, "D:\\LF\\data\\xls\\娴嬬粯\\1-椤圭洰鎴愭灉-瑗夸笁涓璡\1-1涓嚎鎴愭灉琛╘\娴峰師鍘夸腑绾挎垚鏋滆〃.xlsx"); int r1 = listMdZxcg.size(); //List<MdGdcgEntity> listGdcg = ExcelHelper.readExcel(MdGdcgEntity.class, "D:\\LF\\data\\xls\\娴嬬粯\\2-鍦颁笅绠$嚎鎺㈡祴鎴愭灉\\2-2 绠$嚎鎴愭灉琛�.xlsx"); -- Gitblit v1.9.3