소스 검색

删除节点id修改

duy 2 년 전
부모
커밋
645a46ee2b
1개의 변경된 파일5개의 추가작업 그리고 3개의 파일을 삭제
  1. 5 3
      src/views/manager/archivetree.vue

+ 5 - 3
src/views/manager/archivetree.vue

@@ -1020,11 +1020,11 @@ export default {
 
         treeSelectId:'',//选中的划分树
         menusData:[
-          {icon: 'el-icon-s-promotion', label: '新增', key: "add"},
+          {icon: 'el-icon-plus', label: '新增', key: "add"},
           {icon: 'el-icon-s-promotion', label: '编辑', key: "edit"},
           {icon: 'el-icon-sort', label: '排序', key: "sort"},
        
-          {icon: 'el-icon-s-promotion', label: '删除', key: "del"},
+          {icon: 'el-icon-delete', label: '删除', key: "del"},
       
       ],//树组件操作菜单
       menuvisible:false,
@@ -1304,7 +1304,8 @@ export default {
         cancelButtonText: '取消'
       })
         .then(() => {
-          this.remove(node.data.id).then(()=>{
+          console.log(1111111);
+          this.remove(node.id).then(()=>{
             _that.$refs.trees1.remove(node) //删除界面上的节点
           }).catch(()=>{
 
@@ -1316,6 +1317,7 @@ export default {
         });
     },
     async remove (id) {//删除接口
+      console.log('删除');
       const { data: res } = await remove({ id })
       console.log(res);
       if (res.code == 200) {