diff --git a/package-lock.json b/package-lock.json
index 973f3a2..3f8f0de 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -14,6 +14,8 @@
"dayjs": "^1.11.13",
"echarts": "^5.6.0",
"element-plus": "^2.10.1",
+ "loadsh": "^0.0.4",
+ "lodash-es": "^4.17.21",
"pinia": "^3.0.3",
"pinia-plugin-persistedstate": "^4.3.0",
"vue": "^3.5.13",
@@ -3131,6 +3133,13 @@
"node": ">=6.11.5"
}
},
+ "node_modules/loadsh": {
+ "version": "0.0.4",
+ "resolved": "https://registry.npmjs.org/loadsh/-/loadsh-0.0.4.tgz",
+ "integrity": "sha512-U+wLL8InpfRalWrr+0SuhWgGt10M4OyAk6G8xCYo2rwpiHtxZkWiFpjei0vO463ghW8LPCdhqQxXlMy2qicAEw==",
+ "deprecated": "This is a typosquat on the popular Lodash package. This is not maintained nor is the original Lodash package.",
+ "license": "MIT"
+ },
"node_modules/local-pkg": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/local-pkg/-/local-pkg-1.1.1.tgz",
diff --git a/package.json b/package.json
index c406a5d..6f258a3 100644
--- a/package.json
+++ b/package.json
@@ -15,6 +15,8 @@
"dayjs": "^1.11.13",
"echarts": "^5.6.0",
"element-plus": "^2.10.1",
+ "loadsh": "^0.0.4",
+ "lodash-es": "^4.17.21",
"pinia": "^3.0.3",
"pinia-plugin-persistedstate": "^4.3.0",
"vue": "^3.5.13",
diff --git a/src/assets/vue.svg b/src/assets/vue.svg
deleted file mode 100644
index 770e9d3..0000000
--- a/src/assets/vue.svg
+++ /dev/null
@@ -1 +0,0 @@
-
\ No newline at end of file
diff --git a/src/service/api/linkPrediction.js b/src/service/api/linkPrediction.js
index 29347f2..611974c 100644
--- a/src/service/api/linkPrediction.js
+++ b/src/service/api/linkPrediction.js
@@ -11,8 +11,8 @@ export function getInteractionCommunityNodes() {
}
//人物互动隐关系预测的社团内部节点
-export function getInteractionCommunityDetailNodes(ids) {
- return http.get(`linkPrediction/interaction/community_detail?groupIds=${ids}`)
+export function getInteractionCommunityDetailNodes(ids, time = "2024.05.16 16:56:04") {
+ return http.get(`linkPrediction/interaction/community_detail?groupIds=${ids}&dateTime=${time}`)
}
//人物互动隐关系预测的社团统计
diff --git a/src/store/llinkPrediction/index.js b/src/store/llinkPrediction/index.js
index 2bfc8b2..91c7d02 100644
--- a/src/store/llinkPrediction/index.js
+++ b/src/store/llinkPrediction/index.js
@@ -26,9 +26,10 @@ export const useCharacterInteractionStore = defineStore("characterInteraction",
userChartList: [], //组相关性
posts: [],
communityNodeList: [],
-
+ curComponent: "CommunityNode",
+ curSelecedGroupIds: [],
communityDetailNodeList: [],
-
+ curSelectedGroup: [],
anlysisList: [
{
id: 1,
@@ -142,6 +143,11 @@ export const useCharacterInteractionStore = defineStore("characterInteraction",
{ id: 1, icon: nodePrefix, name: "节点数", key: "nodesCount" },
{ id: 2, icon: communityPrefix, name: "社团数", key: "groupCount" },
{ id: 3, icon: hiddenPrefix, name: "隐关系数", key: "hiddenInteractionCount" }
+ ],
+ statisticsDetailList: [
+ { id: 1, icon: nodePrefix, name: "节点数", key: "nodesCount" },
+ { id: 2, icon: communityPrefix, name: "社团数", key: "groupCount" },
+ { id: 3, icon: hiddenPrefix, name: "隐关系数", key: "hiddenInteractionCount" }
]
}),
actions: {
@@ -170,10 +176,15 @@ export const useCharacterInteractionStore = defineStore("characterInteraction",
if (res.code != 200) return
this.communityNodeList = res.data
},
- async initGraphCommunityDetailNode(ids) {
- const res = await getInteractionCommunityDetailNodes(ids)
+ async initGraphCommunityDetailNode(ids, time = "2024.05.16 16:56:04") {
+ this.curSelecedGroupIds = ids
+ const res = await getInteractionCommunityDetailNodes(ids, time)
if (res.code != 200) return
- return res.data
+ this.statisticsDetailList = this.statisticsDetailList.map((item) => ({
+ ...item,
+ count: res.data.communityStatistics[item.key]
+ }))
+ this.communityDetailNodeList = res.data.userRelation
},
async initGraphStatistics() {
const res = await getInteractionCommunityStatistics()
diff --git a/src/views/LinkPrediction/characterInteraction/index.vue b/src/views/LinkPrediction/characterInteraction/index.vue
index f1f8289..b7c7474 100644
--- a/src/views/LinkPrediction/characterInteraction/index.vue
+++ b/src/views/LinkPrediction/characterInteraction/index.vue
@@ -83,6 +83,7 @@ const postDialog = ref(false)
const currentPostPost = ref(null)
const handleSelectedUserGroup = (group) => {
+ interactionStore.curComponent = "detailNode"
console.log(group)
}
diff --git a/src/views/LinkPrediction/components/detailNode.vue b/src/views/LinkPrediction/components/detailNode.vue
index 2241a53..9395d6a 100644
--- a/src/views/LinkPrediction/components/detailNode.vue
+++ b/src/views/LinkPrediction/components/detailNode.vue
@@ -3,51 +3,146 @@