Commit 1e3bf8f4 authored by 仇晓婷's avatar 仇晓婷

119,118bug

parent e55a8703
...@@ -19,13 +19,19 @@ ...@@ -19,13 +19,19 @@
</div> </div>
<div class="fg"> <div class="fg">
<div class="tree"> <div class="tree">
<Tree :data="data" :render="renderContent" ref="tree" @on-select-change="change"></Tree> <Tree
:data="data"
:render="renderContent"
ref="tree"
@on-select-change="change"
></Tree>
</div> </div>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import { forEach } from "lodash";
export default { export default {
name: "", name: "",
data() { data() {
...@@ -64,7 +70,24 @@ export default { ...@@ -64,7 +70,24 @@ export default {
}, },
"upId" "upId"
); );
this.list = this.$u.clone(data); let creatorUserId = this.$store.state.userInfo.userId;
console.log(creatorUserId);
let list = this.$u.clone(data);
let newlist = [];
list.filter((e, index) => {
let userIds = [];
let obj = {};
if (e.upId == 0) {
userIds = e.userIds.split(",");
userIds.forEach((v) => {
if (creatorUserId == v) {
newlist.push(e);
}
});
}
});
// console.log(newlist);
this.list = newlist;
}); });
}, },
toggle() { toggle() {
...@@ -124,6 +147,7 @@ export default { ...@@ -124,6 +147,7 @@ export default {
let items = this.$u.clone(this.list); let items = this.$u.clone(this.list);
let expand = this.expand; let expand = this.expand;
let result = []; let result = [];
search(this.keys, items); search(this.keys, items);
function search(keys, data) { function search(keys, data) {
data.map((u) => { data.map((u) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment