mirror of
https://gitee.com/dromara/go-view.git
synced 2024-11-30 02:38:30 +08:00
fix: 修改图层顺序
This commit is contained in:
parent
88b03a416c
commit
1b7bcd3e32
@ -14,7 +14,7 @@
|
||||
|
||||
<!-- 图层内容 -->
|
||||
<ListItem
|
||||
v-for="item in chartEditStore.getComponentList"
|
||||
v-for="item in reverseList"
|
||||
:key="item.id"
|
||||
:componentData="item"
|
||||
@mousedown="mousedownHandle(item)"
|
||||
@ -26,12 +26,13 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { computed } from 'vue'
|
||||
import { ContentBox } from '../ContentBox/index'
|
||||
|
||||
import { useChartLayoutStore } from '@/store/modules/chartLayoutStore/chartLayoutStore'
|
||||
import { ChartLayoutStoreEnum } from '@/store/modules/chartLayoutStore/chartLayoutStore.d'
|
||||
import { useChartEditStoreStore } from '@/store/modules/chartEditStore/chartEditStore'
|
||||
import { CreateComponentType } from '@/packages/index.d'
|
||||
import cloneDeep from 'lodash/cloneDeep';
|
||||
import {
|
||||
ChartEditStoreEnum,
|
||||
TargetChartType
|
||||
@ -53,6 +54,12 @@ const { handleContextMenu } = useContextMenu({
|
||||
hideOptionsList: [MenuEnum.CLEAR, MenuEnum.PARSE]
|
||||
})
|
||||
|
||||
// 逆序输出
|
||||
const reverseList = computed(()=>{
|
||||
const list: CreateComponentType[] = cloneDeep(chartEditStore.getComponentList)
|
||||
return list.reverse()
|
||||
})
|
||||
|
||||
const backHandle = () => {
|
||||
chartLayoutStore.setItem(ChartLayoutStoreEnum.LAYERS, false)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user