修改树节点切换菜单问题
This commit is contained in:
@@ -65,7 +65,7 @@
|
||||
<el-icon><Download /></el-icon>
|
||||
</el-button>
|
||||
<el-button
|
||||
v-if="activePath != '/'"
|
||||
v-if="activePath && activePath != '/'"
|
||||
type="danger"
|
||||
@click="handleDelDirOrFile(item)"
|
||||
size="small"
|
||||
@@ -81,7 +81,7 @@
|
||||
v-if="item?.type == 'file'"
|
||||
src="@/assets/img/wenjian.svg"
|
||||
/>
|
||||
<!-- <span v-if="!item.type">暂无数据</span> -->
|
||||
<span v-if="!item.type">暂无数据</span>
|
||||
<p>
|
||||
{{
|
||||
item &&
|
||||
@@ -94,7 +94,7 @@
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<el-empty v-if="dirList.length == 0 || !dirList[0].type" />
|
||||
<el-empty v-if="dirList.length == 0 || !dirList[0].type || activePathList.length === 0" />
|
||||
</div>
|
||||
<popup ref="fileRef"></popup>
|
||||
<el-dialog
|
||||
@@ -168,9 +168,12 @@ const isRoot = ref<boolean>(true)
|
||||
//储存所有点击过的目录
|
||||
const activePathList: any = ref([])
|
||||
const nodeClick = (e: any) => {
|
||||
loading.value = true
|
||||
if (e.level == 2) {
|
||||
loading.value = true
|
||||
nDid.value = e.ndid
|
||||
dirList.value = []
|
||||
activePath.value = ''
|
||||
activePathList.value = []
|
||||
getDeviceRootPath(nDid.value)
|
||||
.then((res: any) => {
|
||||
loading.value = false
|
||||
@@ -206,7 +209,7 @@ const handleSearch = () => {
|
||||
}
|
||||
//重置搜索
|
||||
const handleRefresh = () => {
|
||||
loading.value=true
|
||||
loading.value = true
|
||||
filterFileName.value = ''
|
||||
dirList.value = currentDirList.value
|
||||
reloadCurrentMenu('')
|
||||
|
||||
Reference in New Issue
Block a user