update Tree
This commit is contained in:
parent
ffb3729603
commit
83e7c64fec
1 changed files with 6 additions and 1 deletions
|
@ -1,7 +1,7 @@
|
|||
<template>
|
||||
<collapse-transition :appear="appear">
|
||||
<ul :class="classes">
|
||||
<li @contextmenu.stop="handleContextmenu(data, $event)">
|
||||
<li @contextmenu.stop="handleContextmenu(data, $event)" @selectstart.stop="handlePreventSelect(data, $event)">
|
||||
<span :class="arrowClasses" @click="handleExpand">
|
||||
<Icon v-if="showArrow" :type="arrowType" :custom="customArrowType" :size="arrowSize" />
|
||||
<Icon v-if="showLoading" type="ios-loading" class="ivu-load-loop" />
|
||||
|
@ -222,6 +222,11 @@
|
|||
event.preventDefault();
|
||||
this.dispatch('Tree', 'contextmenu', { data, event });
|
||||
}
|
||||
},
|
||||
handlePreventSelect (data, event) {
|
||||
if (data.contextmenu) {
|
||||
event.preventDefault();
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Add table
Reference in a new issue