feat : 新增需求征集组件

This commit is contained in:
2024-05-17 23:24:38 +08:00
parent 7869ff4e6a
commit f5c6680c66
4 changed files with 250 additions and 37 deletions

13
src/utils/matterTree.js Normal file
View File

@@ -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;
}
}