diff --git a/src/components/DetailComponent/CollectionDetail.vue b/src/components/DetailComponent/CollectionDetail.vue
new file mode 100644
index 0000000..a6a3a26
--- /dev/null
+++ b/src/components/DetailComponent/CollectionDetail.vue
@@ -0,0 +1,170 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/utils/matterTree.js b/src/utils/matterTree.js
new file mode 100644
index 0000000..24f791d
--- /dev/null
+++ b/src/utils/matterTree.js
@@ -0,0 +1,13 @@
+export const matterTree = (array,data, id) => {
+ if (id) {
+ for (let i = 0; i < data.length; i++) {
+ if (data[i].value == id) {
+ array.push(data[i].label);
+ }
+ if (data[i].children && data[i].children.length > 0) {
+ matterTree(data[i].children)
+ }
+ }
+ return array;
+ }
+}
diff --git a/src/views/project-demand/collection/detail.vue b/src/views/project-demand/collection/detail.vue
index 6a708f2..f0d3f5a 100644
--- a/src/views/project-demand/collection/detail.vue
+++ b/src/views/project-demand/collection/detail.vue
@@ -80,8 +80,8 @@ import {useProcessStore} from '@/stores/processStore.js';
import {getInfo, agreeTask, rejectTask,downloadFile} from "@/api/project-demand/index.js";
import {getSubCompOpt} from '@/api/user/user.js'
import {ElMessage} from "element-plus";
-import {useRouter} from "vue-router";
import {useTagsView} from '@/stores/tagsview.js'
+import {matterTree} from '@/utils/matterTree.js';
const tagsViewStore = useTagsView()
const router = useRouter()
@@ -180,24 +180,10 @@ const getCompanyOption = async () => {
companyOption.value = res.data
}
-const matterTree = (data, id) => {
- if (id) {
- for (let i = 0; i < data.length; i++) {
- if (data[i].value == id) {
- companyNameArray.value.push(data[i].label);
- }
- if (data[i].children && data[i].children.length > 0) {
- matterTree(data[i].children)
- }
- }
- return companyNameArray.value;
- }
-}
-
const getDataSourceOptionItem = (val) => {
if (val !== undefined) {
val.forEach(item => {
- matterTree(companyOption.value, item)
+ matterTree(companyNameArray.value,companyOption.value, item)
})
}
return companyNameArray.value.join(',');
diff --git a/src/views/project-management/initiation/detail.vue b/src/views/project-management/initiation/detail.vue
index aeebf62..a6be3b1 100644
--- a/src/views/project-management/initiation/detail.vue
+++ b/src/views/project-management/initiation/detail.vue
@@ -1,48 +1,92 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+