diff --git a/ant-design-vue-jeecg/src/views/cms/admin/modules/CmsArticleForm.vue b/ant-design-vue-jeecg/src/views/cms/admin/modules/CmsArticleForm.vue index 2edf646..5c5ba07 100644 --- a/ant-design-vue-jeecg/src/views/cms/admin/modules/CmsArticleForm.vue +++ b/ant-design-vue-jeecg/src/views/cms/admin/modules/CmsArticleForm.vue @@ -27,7 +27,7 @@ - + diff --git a/ant-design-vue-jeecg/src/views/py/PyAddProject.vue b/ant-design-vue-jeecg/src/views/py/PyAddProject.vue index 4968ea8..05f1d20 100644 --- a/ant-design-vue-jeecg/src/views/py/PyAddProject.vue +++ b/ant-design-vue-jeecg/src/views/py/PyAddProject.vue @@ -1,19 +1,21 @@ @@ -170,15 +193,38 @@ export default { width: 1200, visible: false, model: {}, + // labelCol: { + // xs: {span: 24}, + // sm: {span: 5} + // }, + // wrapperCol: { + // xs: {span: 24}, + // sm: {span: 16} + // }, labelCol: { xs: {span: 24}, - sm: {span: 5} + sm: {span: 6,offset:3 } }, wrapperCol: { xs: {span: 24}, - sm: {span: 16} + sm: {span: 15} + }, + labelCol1: { + xs: {span: 24}, + sm: {span: 2,offset:1 } + }, + wrapperCol1: { + xs: {span: 24}, + sm: {span: 21} + }, + labelCol2: { + xs: {span: 24}, + sm: {span: 3} + }, + wrapperCol2: { + xs: {span: 24}, + sm: {span: 21} }, - confirmLoading: false, validatorRules: { majorCode: { @@ -434,12 +480,15 @@ export default { // .button-container { // margin-left: 100px; // } -.el-left{ - float: right; - margin:10px -} -.el-right{ - float: right; - margin:10px +// .el-left{ +// float: right; +// margin:10px +// } +// .el-right{ +// float: right; +// margin:10px +// } +.centerbox{ + text-align: center; } \ No newline at end of file diff --git a/ant-design-vue-jeecg/src/views/seknowgroup/SeKnowGroupList.vue b/ant-design-vue-jeecg/src/views/seknowgroup/SeKnowGroupList.vue index 0236e1f..5423b2c 100644 --- a/ant-design-vue-jeecg/src/views/seknowgroup/SeKnowGroupList.vue +++ b/ant-design-vue-jeecg/src/views/seknowgroup/SeKnowGroupList.vue @@ -172,15 +172,22 @@ }, methods: { zsAtlsa(record) { - let routeData = this.$router.resolve({ path: '/atlas', query: { name: 1 } }); - - window.open(routeData.href, '_blank'); - // this.$router.push({ - // path: '/src/views/seknowgroup/SeKnowAtlasList', - // query: { - // "id": 1 + // getAction('/seknowgroup/seKnowGroup/zzzztp', {id: record.id}).then((res) => { + // if (res.success) { + // //重新计算分页问题 + // e.exports.nodes=[{name:"重庆高速路网车间器数据"},{name:"重庆高速路网交调站数据"}] + // e.exports.links=[{source:"重庆高速路网车间器数据",target:"重庆高速路网交调站数据",value:.75}] + // console.log("=================================================") + // console.log(e.exports.nodes) + // console.log("=================================================") + // } else { + // this.$message.warning(res.message); // } // }) + + + let routeData = this.$router.resolve({ path: '/atlas', query: { id: record.id } }); + window.open(routeData.href, '_blank'); }, initDictConfig(){ }, diff --git a/ant-design-vue-jeecg/src/views/seknowgroup/atlas/js/main1.js b/ant-design-vue-jeecg/src/views/seknowgroup/atlas/js/main1.js index 24b7c80..2fcdff1 100644 --- a/ant-design-vue-jeecg/src/views/seknowgroup/atlas/js/main1.js +++ b/ant-design-vue-jeecg/src/views/seknowgroup/atlas/js/main1.js @@ -7,6 +7,7 @@ export let threeMainFunction = function(e) { } function o() { + for (var e, t = 0; t < n.length; t++) { for (var o = n[t], a = !0, s = 1; s < o.length; s++) { var i = o[s]; @@ -16,12 +17,12 @@ export let threeMainFunction = function(e) { } return e } + var a = {}, r = { 0: 0 }, n = []; - function u(t) { if (a[t]) return a[t].exports; var o = a[t] = { @@ -31,18 +32,21 @@ export let threeMainFunction = function(e) { }; return e[t].call(o.exports, o, o.exports, u), o.l = !0, o.exports } + u.m = e, u.c = a, u.d = function(e, t, o) { u.o(e, t) || Object.defineProperty(e, t, { enumerable: !0, get: o }) - }, u.r = function(e) { + }, + u.r = function(e) { "undefined" != typeof Symbol && Symbol.toStringTag && Object.defineProperty(e, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(e, "__esModule", { value: !0 }) - }, u.t = function(e, t) { + }, + u.t = function(e, t) { if (1 & t && (e = u(e)), 8 & t) return e; if (4 & t && "object" == typeof e && e && e.__esModule) return e; var o = Object.create(null); @@ -54,25 +58,31 @@ export let threeMainFunction = function(e) { return e[t] }.bind(null, a)); return o - }, u.n = function(e) { + }, + u.n = function(e) { var t = e && e.__esModule ? function() { return e.default } : function() { return e }; return u.d(t, "a", t), t - }, u.o = function(e, t) { + }, + u.o = function(e, t) { return Object.prototype.hasOwnProperty.call(e, t) - }, u.p = ""; - var s = window.webpackJsonp = window.webpackJsonp || [], + }, + u.p = ""; + var s = window.webpackJsonp = window.webpackJsonp || [], i = s.push.bind(s); s.push = t, s = s.slice(); for (var c = 0; c < s.length; c++) t(s[c]); var l = i; n.push([4, 1]), o() -}([, , , , function(e, t, o) { +} +([, , , , function(e, t, o) +{ e.exports = o(5) -}, function(e, t, o) { +}, + function(e, t, o) { "use strict"; o.r(t); var a = o(2), @@ -224,549 +234,39 @@ export let threeMainFunction = function(e) { }; M(S) })() -}, function(e) { - e.exports = { - nodes: [{ - name: "软件项目管理" - }, { - name: "软件项目管理基本概念" - }, { - name: "项目整体管理" - }, { - name: "项目范围管理" - }, { - name: "项目进度管理" - }, { - name: "项目进度管理" - }, { - name: "项目资源与采购管理" - }, { - name: "项目相关方与沟通管理" - }, { - name: "项目质量管理" - }, { - name: "项目风险管理" - }, { - name: "项目(知识点)" - }, { - name: "项目管理(知识点)" - }, { - name: "软件项目管理(知识点)" - }, { - name: "项目组织(知识点)" - }, { - name: "制定项目章程(知识点)" - }, { - name: "制定项目管理计划(知识点)" - }, { - name: "指导与管理项目工作(知识点)" - }, { - name: "监控项目工作(知识点)" - }, { - name: "实施整体变更控制(知识点)" - }, { - name: "结束项目或阶段(知识点)" - }, { - name: "规划范围管理" - }, { - name: "定义范围" - }, { - name: "创建WBS" - }, { - name: "确认范围" - }, { - name: "控制范围" - }, { - name: "规划进度管理" - }, { - name: "定义活动" - }, { - name: "估算活动(知识点)" - }, { - name: "制定进度计划(知识点)" - }, { - name: "控制进度(知识点)" - }, { - name: "规划成本管理(知识点)" - }, { - name: "估算成本(知识点)" - }, { - name: "控制成本(知识点)" - }, { - name: "规划资源管理(知识点)" - }, { - name: "获取资源(知识点)" - }, { - name: "建设团队" - }, { - name: "管理团队(知识点)" - }, { - name: "控制资源(知识点)" - }, { - name: "采购管理(知识点)" - }, { - name: "识别相关方(知识点)" - }, { - name: "相关方管理(知识点)" - }, { - name: "规划沟通管理(知识点)" - }, { - name: "管理沟通(知识点)" - }, { - name: "监督沟通(知识点)" - }, { - name: "规划质量管理(知识点)" - }, { - name: "管理质量(知识点)" - }, { - name: "控制质量(知识点)" - }, { - name: "规划风险管理(知识点)" - }, { - name: "识别与控制风险(知识点)" - }, { - name: "项目(知识点)" - }, { - name: "项目管理(知识点)" - }, { - name: "项目管理知识体系(知识点)" - }, { - name: "软件项目管理(知识点)" - }, { - name: "组织结构类型(知识点)" - }, { - name: "PMO的角色和职责(知识点)" - }, { - name: "项目经理的定义与职责(知识点)" - }, { - name: "项目经理所需的能力(知识点)" - }, { - name: "制定项目章程(知识点)" - }, { - name: "制定项目管理计划(知识点)" - }, { - name: "指导与管理项目工作(知识点)" - }, { - name: "监控项目工作(知识点)" - }, { - name: "实施整体变更控制(知识点)" - }, { - name: "结束项目或阶段(知识点)" - }, { - name: "规划范围管理(知识点)" - }, { - name: "定义范围(知识点)" - }, { - name: "创建WBS(知识点)" - }, { - name: "确认范围(知识点)" - }, { - name: "控制范围(知识点)" - }, { - name: "规划进度管理(知识点)" - }, { - name: "定义活动(知识点)" - }, { - name: "估算活动(知识点)" - }, { - name: "制定进度计划(知识点)" - }, { - name: "控制进度(知识点)" - }, { - name: "规划成本管理(知识点)" - }, { - name: "估算成本(知识点)" - }, { - name: "控制成本(知识点)" - }, { - name: "规划资源管理(知识点)" - }, { - name: "获取资源(知识点)" - }, { - name: "建设团队(知识点)" - }, { - name: "管理团队(知识点)" - }, { - name: "控制资源(知识点)" - }, { - name: "采购管理(知识点)" - }, { - name: "识别相关方(知识点)" - }, { - name: "相关方管理(知识点)" - }, { - name: "规划沟通管理(知识点)" - }, { - name: "管理沟通(知识点)" - }, { - name: "监督沟通(知识点)" - }, { - name: "规划质量管理(知识点)" - }, { - name: "管理质量(知识点)" - }, { - name: "控制质量(知识点)" - }, { - name: "规划风险管理(知识点)" - }, { - name: "识别与控制风险(知识点)" - }], - links: [{ - source: "软件项目管理", - target: "软件项目管理基本概念", - value: .75 - }, { - source: "软件项目管理", - target: "项目整体管理", - value: .1 - }, { - source: "软件项目管理", - target: "项目范围管理", - value: .05 - }, { - source: "软件项目管理", - target: "项目进度管理", - value: .05 - }, { - source: "软件项目管理", - target: "项目成本管理", - value: .05 - }, { - source: "软件项目管理", - target: "项目资源与采购管理", - value: .0167781913 - }, { - source: "软件项目管理", - target: "项目相关方与沟通管理", - value: .3502949852 - }, { - source: "软件项目管理", - target: "项目质量管理", - value: .0006434116 - }, { - source: "软件项目管理", - target: "项目风险管理", - value: .0073746312 - }, { - source: "软件项目管理基本概念", - target: "项目(知识点)", - value: .0006434116 - }, { - source: "软件项目管理基本概念", - target: "项目管理(知识点)", - value: 216053e-10 - }, { - source: "软件项目管理基本概念", - target: "软件项目管理(知识点)", - value: .0006434116 - }, { - source: "软件项目管理基本概念", - target: "项目组织", - value: .6452802359 - }, { - source: "软件项目管理基本概念", - target: "项目经理", - value: .0006434116 - }, { - source: "项目整体管理", - target: "制定项目章程(知识点)", - value: 11182e-10 - }, { - source: "项目整体管理", - target: "制定项目管理计划(知识点)", - value: .0006434116 - }, { - source: "项目整体管理", - target: "指导与管理项目工作(知识点)", - value: .0006434116 - }, { - source: "项目整体管理", - target: "监控项目工作(知识点)", - value: .0010334566 - }, { - source: "项目整体管理", - target: "实施整体变更控制(知识点)", - value: .0006434116 - }, { - source: "项目整体管理", - target: "结束项目或阶段(知识点)", - value: .0010622637 - }, { - source: "项目范围管理", - target: "规划范围管理(知识点)", - value: .2857142857 - }, { - source: "项目范围管理", - target: "定义范围(知识点)", - value: .864745011 - }, { - source: "项目范围管理", - target: "创建WBS(知识点)", - value: .0006434116 - }, { - source: "项目范围管理", - target: "确认范围(知识点)", - value: .0160450734 - }, { - source: "项目范围管理", - target: "控制范围(知识点)", - value: .0006434116 - }, { - source: "项目成本管理", - target: "规划成本管理(知识点)", - value: .1125970066 - }, { - source: "项目成本管理", - target: "估算成本(知识点)", - value: .0006434116 - }, { - source: "项目成本管理", - target: "控制成本(知识点)", - value: .0012991962 - }, { - source: "项目资源与采购管理", - target: "规划资源管理(知识点)", - value: .0006434116 - }, { - source: "项目资源与采购管理", - target: "获取资源(知识点)", - value: .6968641114 - }, { - source: "项目资源与采购管理", - target: " 建设团队(知识点)", - value: .7909090909 - }, { - source: "项目资源与采购管理", - target: "管理团队(知识点)", - value: .0006434116 - }, { - source: "项目资源与采购管理", - target: "控制资源(知识点)", - value: .1909090909 - }, { - source: "项目资源与采购管理", - target: "采购管理(知识点)", - value: .1909090909 - }, { - source: "项目相关方与沟通管理", - target: "识别相关方(知识点)", - value: .5 - }, { - source: "项目相关方与沟通管理", - target: "相关方管理(知识点)", - value: .5 - }, { - source: "项目相关方与沟通管理", - target: "规划沟通管理(知识点)", - value: .0161576704 - }, { - source: "项目相关方与沟通管理", - target: "管理沟通(知识点)", - value: .0006434116 - }, { - source: "项目相关方与沟通管理", - target: "监督沟通(知识点)", - value: .0016956676 - }, { - source: "项目质量管理", - target: "规划质量管理(知识点)", - value: .0006434116 - }, { - source: "项目质量管理", - target: "管理质量(知识点)", - value: .0006434116 - }, { - source: "项目质量管理", - target: "控制质量(知识点)", - value: .4435897435 - }, { - source: "项目风险管理", - target: "规划风险管理(知识点)", - value: .0006434116 - }, { - source: "项目风险管理", - target: "识别与控制风险(知识点)", - value: .5564102565 - }, { - source: "项目管理", - target: "项目管理(知识点)", - value: .0006434116 - }, { - source: "项目管理", - target: "项目管理知识体系(知识点)", - value: .0006434116 - }, { - source: "软件项目管理", - target: "软件项目管理(知识点)", - value: .0006434116 - }, { - source: "项目组织", - target: "组织结构类型(知识点)", - value: .0006434116 - }, { - source: "项目组织", - target: "PMO的角色和职责(知识点)", - value: .0006434116 - }, { - source: "项目经理", - target: "项目经理的定义与职责(知识点)", - value: .0006434116 - }, { - source: "项目经理", - target: "项目经理所需的能力(知识点)", - value: .0006434116 - }, { - source: "制定项目章程", - target: "制定项目章程(知识点)", - value: .0006434116 - }, { - source: "制定项目管理计划", - target: "制定项目管理计划(知识点)", - value: .0006434116 - }, { - source: "指导与管理项目工作", - target: "指导与管理项目工作(知识点)", - value: .0006434116 - }, { - source: "监控项目工作", - target: "监控项目工作(知识点)", - value: .0006434116 - }, { - source: "实施整体变更控制", - target: "实施整体变更控制(知识点)", - value: .0006434116 - }, { - source: "结束项目或阶段", - target: "结束项目或阶段(知识点)", - value: .0006434116 - }, { - source: "规划范围管理", - target: "规划范围管理(知识点)", - value: .0006434116 - }, { - source: "定义范围", - target: "定义范围(知识点)", - value: .0006434116 - }, { - source: "创建WBS", - target: "创建WBS(知识点)", - value: .0006434116 - }, { - source: "确认范围", - target: "确认范围(知识点)", - value: .0006434116 - }, { - source: "控制范围", - target: "控制范围(知识点)", - value: .0006434116 - }, { - source: "项目进度管理", - target: "规划进度管理", - value: .0006434116 - }, - { - source: "规划进度管理", - target: "规划进度管理(知识点)", - value: .0006434116 - },{ - source: "定义活动", - target: "定义活动(知识点)", - value: .0006434116 - }, { - source: "估算活动", - target: "估算活动(知识点)", - value: .0006434116 - } - , { - source: "项目进度管理", - target: "估算活动", - value: .0006434116 +}, + function (e) { + var nodestemp = [] + var linkstemp = [] + var id = window.location.href; + var ids = id.indexOf('=') + var idsur = id.substring(ids + 1) + var xhr = new XMLHttpRequest(); + var url=process.env.VUE_APP_API_BASE_URL+'/seknowgroup/seKnowGroup/zzzztp?id='+idsur; + xhr.open('GET', url, false); + xhr.onreadystatechange = function() { + if (xhr.readyState == 4 && xhr.status == 200 || xhr.status == 304) { + console.log(2222); + // 从服务器获得数据 + var jsonObj = JSON.parse(xhr.responseText) + // 获取 nodes 数组和 links 数组 + nodestemp = jsonObj.nodes; + linkstemp = jsonObj.links; + +// 输出结果 + console.log(nodestemp); + console.log(linkstemp); + /* var stemp= xhr.responseText; + console.log(stemp); + console.log('aaaa',stemp.nodes) + console.log('bbbb',stemp.links)*/ } + }; + xhr.send(); - , { - source: "估算活动", - target: "估算活动(知识点)", - value: .0006434116 - }, { - source: "控制进度", - target: "控制进度(知识点)", - value: .0006434116 - }, { - source: "规划成本管理", - target: "规划成本管理(知识点)", - value: .0006434116 - }, { - source: "估算成本", - target: "估算成本(知识点)", - value: .0006434116 - }, { - source: "控制成本", - target: "控制成本(知识点)", - value: .0006434116 - }, { - source: "规划资源管理", - target: "规划资源管理(知识点)", - value: .0006434116 - }, { - source: "获取资源", - target: "获取资源(知识点)", - value: .0006434116 - }, { - source: "建设团队", - target: "建设团队(知识点)", - value: .0006434116 - }, { - source: "管理团队", - target: "管理团队(知识点)", - value: .0006434116 - }, { - source: "控制资源", - target: "控制资源(知识点)", - value: .0006434116 - }, { - source: "采购管理", - target: "采购管理(知识点)", - value: .0006434116 - }, { - source: "识别相关方", - target: "识别相关方(知识点)", - value: .0006434116 - }, { - source: "相关方管理", - target: "相关方管理(知识点)", - value: .0006434116 - }, { - source: "规划沟通管理", - target: "规划沟通管理(知识点)", - value: .0006434116 - }, { - source: "管理沟通", - target: "管理沟通(知识点)", - value: .0006434116 - }, { - source: "监督沟通", - target: "监督沟通(知识点)", - value: .0006434116 - }, { - source: "规划质量管理", - target: "规划质量管理(知识点)", - value: .0006434116 - }, { - source: "管理质量", - target: "管理质量(知识点)", - value: .0006434116 - }, { - source: "控制质量", - target: "控制质量(知识点)", - value: .0006434116 - }, { - source: "规划风险管理", - target: "规划风险管理(知识点)", - value: .0006434116 - }, { - source: "识别与控制风险", - target: "识别与控制风险(知识点)", - value: .0006434116 - }] - } -}]); \ No newline at end of file + e.exports = { + nodes: nodestemp, + links: linkstemp + } + console.log(3333); + }]); \ No newline at end of file diff --git a/jeecg-boot/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/config/shiro/ShiroConfig.java b/jeecg-boot/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/config/shiro/ShiroConfig.java index fd011d9..1523f7a 100644 --- a/jeecg-boot/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/config/shiro/ShiroConfig.java +++ b/jeecg-boot/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/config/shiro/ShiroConfig.java @@ -76,6 +76,8 @@ public class ShiroConfig { filterChainDefinitionMap.put("/sys/randomImage/**", "anon"); //登录验证码接口排除 filterChainDefinitionMap.put("/sys/checkCaptcha", "anon"); //登录验证码接口排除 filterChainDefinitionMap.put("/sys/login", "anon"); //登录接口排除 + filterChainDefinitionMap.put("/seknowgroup/seKnowGroup/zzzztp", "anon"); //知识图谱接口排除 + filterChainDefinitionMap.put("/sys/facelogin", "anon"); //登录接口排除 filterChainDefinitionMap.put("/sys/faceIdentify", "anon"); //登录接口排除 filterChainDefinitionMap.put("/sys/mLogin", "anon"); //登录接口排除 diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/mapper/SeKonwMapper.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/mapper/SeKonwMapper.java index 7ff98c9..65b2145 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/mapper/SeKonwMapper.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/mapper/SeKonwMapper.java @@ -32,4 +32,6 @@ public interface SeKonwMapper extends BaseMapper { void update1(String getrealname, String createBy); + @Select("select wight from se_konw_relationship where id =#{relationId}") + String getrelaint(String relationId); } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/service/ISeKonwService.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/service/ISeKonwService.java index e48b1ed..265c694 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/service/ISeKonwService.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/service/ISeKonwService.java @@ -23,4 +23,6 @@ public interface ISeKonwService extends IService { void update1(String getrealname, String createBy); Boolean importExcel(List zlListByE); + + String getrelaint(String relationId); } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/service/impl/SeKonwServiceImpl.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/service/impl/SeKonwServiceImpl.java index fa978d3..449548f 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/service/impl/SeKonwServiceImpl.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/know/service/impl/SeKonwServiceImpl.java @@ -63,6 +63,10 @@ public class SeKonwServiceImpl extends ServiceImpl impleme return true; } + @Override + public String getrelaint(String relationId) { + return seKonwMapper.getrelaint(relationId); + } } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/controller/SeKnowGroupController.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/controller/SeKnowGroupController.java index 14950f3..3d37281 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/controller/SeKnowGroupController.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/controller/SeKnowGroupController.java @@ -1,5 +1,6 @@ package org.jeecg.modules.demo.seknowgroup.controller; +import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.Map; @@ -12,6 +13,11 @@ import javax.servlet.http.HttpServletResponse; import org.jeecg.common.api.vo.Result; import org.jeecg.common.system.query.QueryGenerator; import org.jeecg.common.util.oConvertUtils; +import org.jeecg.modules.demo.know.entity.SeKonw; +import org.jeecg.modules.demo.know.service.ISeKonwService; +import org.jeecg.modules.demo.seknowgroup.entity.Exports; +import org.jeecg.modules.demo.seknowgroup.entity.NodeList; +import org.jeecg.modules.demo.seknowgroup.entity.NodeName; import org.jeecg.modules.demo.seknowgroup.entity.SeKnowGroup; import org.jeecg.modules.demo.seknowgroup.service.ISeKnowGroupService; @@ -20,6 +26,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import lombok.extern.slf4j.Slf4j; +import org.jeecg.modules.konwRelationshipMain.entity.SeKonwRelationshipMain; import org.jeecgframework.poi.excel.ExcelImportUtil; import org.jeecgframework.poi.excel.def.NormalExcelConstants; import org.jeecgframework.poi.excel.entity.ExportParams; @@ -50,6 +57,9 @@ public class SeKnowGroupController extends JeecgController nodelist = new ArrayList<>(); + //开始根据id查找中心知识点id + String pointnode = seKnowGroupService.findpointnode(id); + //开始组装知识点节点 + //获取中心知识点 + SeKonw seknow = seKonwService.getById(pointnode); + //将list的第一个位置设置成中心知识点名称 + NodeName nodes = new NodeName(); + nodes.setName(seknow.getName()); + nodelist.add(nodes); + //开是循环,根据中心知识点id,在知识点关系表中查询以中心知识点为中心查询第二层知识点 + List listid = seKnowGroupService.listid(seknow.getId()); + //开始循环 + for (int i=0;i listid2 = seKnowGroupService.listid(listid.get(i)); + System.out.println(listid2.size()); + for (int j =0;j nodelistdss = new ArrayList<>(); + //首先根据中心知识点查询 + List segouplisttemp = new ArrayList<>(); + segouplisttemp=seKnowGroupService.getzxzsnodelist(seknow.getId()); + //第二层 + for (int i=0; i< segouplisttemp.size();i++){ + NodeList ndoesl = new NodeList(); + ndoesl.setSource(seKonwService.getById(segouplisttemp.get(i).getPerKowId()).getName()); + ndoesl.setTarget(seKonwService.getById(segouplisttemp.get(i).getNextKnowId()).getName()); + ndoesl.setValue(seKonwService.getrelaint(segouplisttemp.get(i).getRelationId())); + nodelistdss.add(ndoesl); + List segouplisttemp2 = new ArrayList<>(); + segouplisttemp2=seKnowGroupService.getzxzsnodelist(segouplisttemp.get(i).getNextKnowId()); + for (int j=0;j nodes; + private List links; +} diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/entity/NodeList.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/entity/NodeList.java new file mode 100644 index 0000000..09d644f --- /dev/null +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/entity/NodeList.java @@ -0,0 +1,10 @@ +package org.jeecg.modules.demo.seknowgroup.entity; + +import lombok.Data; + +@Data +public class NodeList { + private String source; + private String target; + private String value; +} diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/entity/NodeName.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/entity/NodeName.java new file mode 100644 index 0000000..a592ac0 --- /dev/null +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/entity/NodeName.java @@ -0,0 +1,9 @@ +package org.jeecg.modules.demo.seknowgroup.entity; + +import lombok.Data; + +@Data +public class NodeName { + private String name; + +} diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/mapper/SeKnowGroupMapper.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/mapper/SeKnowGroupMapper.java index 1ff119f..15bb868 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/mapper/SeKnowGroupMapper.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/mapper/SeKnowGroupMapper.java @@ -3,8 +3,11 @@ package org.jeecg.modules.demo.seknowgroup.mapper; import java.util.List; import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Select; +import org.jeecg.modules.demo.seknowgroup.entity.NodeList; import org.jeecg.modules.demo.seknowgroup.entity.SeKnowGroup; import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import org.jeecg.modules.konwRelationshipMain.entity.SeKonwRelationshipMain; /** * @Description: 知识图谱表 @@ -14,4 +17,14 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; */ public interface SeKnowGroupMapper extends BaseMapper { + + @Select("select know_point from se_know_group where id =#{id}") + String findpointnode(String id); + + + @Select("select next_know_id from se_konw_relationship_main where per_kow_id=#{pointnode}") + List listid(String pointnode); + + @Select("select * from se_konw_relationship_main where per_kow_id =#{id}") + List getzxzsnodelist(String id); } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/service/ISeKnowGroupService.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/service/ISeKnowGroupService.java index 71bcc16..24c6d5a 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/service/ISeKnowGroupService.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/service/ISeKnowGroupService.java @@ -1,7 +1,11 @@ package org.jeecg.modules.demo.seknowgroup.service; +import org.jeecg.modules.demo.seknowgroup.entity.NodeList; import org.jeecg.modules.demo.seknowgroup.entity.SeKnowGroup; import com.baomidou.mybatisplus.extension.service.IService; +import org.jeecg.modules.konwRelationshipMain.entity.SeKonwRelationshipMain; + +import java.util.List; /** * @Description: 知识图谱表 @@ -11,4 +15,10 @@ import com.baomidou.mybatisplus.extension.service.IService; */ public interface ISeKnowGroupService extends IService { + String findpointnode(String id); + + List listid(String pointnode); + + + List getzxzsnodelist(String id); } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/service/impl/SeKnowGroupServiceImpl.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/service/impl/SeKnowGroupServiceImpl.java index fd6d999..6f0bc39 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/service/impl/SeKnowGroupServiceImpl.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/seknowgroup/service/impl/SeKnowGroupServiceImpl.java @@ -1,12 +1,17 @@ package org.jeecg.modules.demo.seknowgroup.service.impl; +import org.jeecg.modules.demo.seknowgroup.entity.NodeList; import org.jeecg.modules.demo.seknowgroup.entity.SeKnowGroup; import org.jeecg.modules.demo.seknowgroup.mapper.SeKnowGroupMapper; import org.jeecg.modules.demo.seknowgroup.service.ISeKnowGroupService; +import org.jeecg.modules.konwRelationshipMain.entity.SeKonwRelationshipMain; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import java.util.List; + /** * @Description: 知识图谱表 * @Author: jeecg-boot @@ -16,4 +21,23 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; @Service public class SeKnowGroupServiceImpl extends ServiceImpl implements ISeKnowGroupService { + @Autowired + SeKnowGroupMapper knowGroupMapper; + + @Override + public String findpointnode(String id) { + return knowGroupMapper.findpointnode(id); + } + + @Override + public List listid(String pointnode) { + return knowGroupMapper.listid(pointnode); + } + + @Override + public List getzxzsnodelist(String id) { + return knowGroupMapper.getzxzsnodelist(id); + } + + } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/resources/logback-spring.xml b/jeecg-boot/jeecg-boot-module-system/src/main/resources/logback-spring.xml index acad24b..dc0c4f9 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/resources/logback-spring.xml +++ b/jeecg-boot/jeecg-boot-module-system/src/main/resources/logback-spring.xml @@ -1,7 +1,7 @@ - + @@ -74,4 +74,4 @@ - \ No newline at end of file +