|
@@ -102,10 +102,11 @@
|
|
|
accordion
|
|
|
ref="tree"
|
|
|
:props="treeProps"
|
|
|
+ :allow-drop="allowDrop"
|
|
|
>
|
|
|
>
|
|
|
<span class="custom-tree-node" slot-scope="{ node, data }">
|
|
|
- <span>{{ node.label }}</span>
|
|
|
+ <span :class="node.level == 1?'title':''">{{ node.label }}</span>
|
|
|
<span>
|
|
|
<i class="el-icon-edit" @click="() => editItem(data)"></i>
|
|
|
<i
|
|
@@ -285,6 +286,13 @@ export default {
|
|
|
uploadImg() {
|
|
|
this.$refs.uploadImg.$refs.upload.submit();
|
|
|
},
|
|
|
+ allowDrop(draggingNode, dropNode, type){
|
|
|
+ if(dropNode.level == 1){
|
|
|
+ return true
|
|
|
+ }else{
|
|
|
+ return false
|
|
|
+ }
|
|
|
+ }
|
|
|
},
|
|
|
computed: {},
|
|
|
};
|
|
@@ -301,8 +309,12 @@ export default {
|
|
|
.addCateBtn {
|
|
|
margin-bottom: 20px;
|
|
|
}
|
|
|
+
|
|
|
.custom-tree-node {
|
|
|
- font-size: 16px;
|
|
|
+ .title {
|
|
|
+ font-size: 16px;
|
|
|
+ }
|
|
|
+ font-size: 14px;
|
|
|
i {
|
|
|
// font-size: 20px;
|
|
|
margin-left: 5px;
|