Merge pull request #13646 from dataease/pr@dev-v2@refactor_tab-sort

refactor: tab支持图层侧拖拽排序
This commit is contained in:
王嘉豪 2024-11-28 15:31:29 +08:00 committed by GitHub
commit 306c6711f7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 10 deletions

View File

@ -13,7 +13,7 @@
<el-color-picker
:effect="themes"
v-model="seniorStyleSetting.linkageIconColor"
:trigger-width="197"
:trigger-width="100"
is-custom
:predefine="state.predefineColors"
@change="themeChange"
@ -30,7 +30,7 @@
<el-color-picker
v-model="seniorStyleSetting.drillLayerColor"
:effect="themes"
:trigger-width="197"
:trigger-width="100"
is-custom
:predefine="state.predefineColors"
@change="themeChange"

View File

@ -74,14 +74,6 @@ const closeEditComponentName = () => {
const dragOnEnd = ({ oldIndex, newIndex }) => {
const source = componentData.value[newIndex]
const comLength = componentData.value.length
//
componentData.value.splice(newIndex, 1)
componentData.value.splice(oldIndex, 0, source)
const target = componentData.value[comLength - 1 - oldIndex]
//
componentData.value.splice(comLength - 1 - oldIndex, 1)
componentData.value.splice(comLength - 1 - newIndex, 0, target)
dvMainStore.setCurTabName(source.title)
eventBus.emit('onTabSortChange-' + tabElement.value?.id)
snapshotStore.recordSnapshotCache()