驾驶舱页面绘制
绘制2、稳态电能质量分析、稳态治理效果分析、暂态电能质量分析页面
This commit is contained in:
@@ -5,16 +5,13 @@
|
||||
<el-button type="primary" @click="add" icon="el-icon-Plus">新增</el-button>
|
||||
</template>
|
||||
</TableHeader>
|
||||
<Table
|
||||
ref="tableRef"
|
||||
:tree-config="{ transform: true, parentField: 'uPid', rowField: 'uId' }"
|
||||
:scroll-y="{ enabled: true }"
|
||||
/>
|
||||
<Table ref="tableRef" :tree-config="{ transform: true, parentField: 'uPid', rowField: 'uId' }"
|
||||
:scroll-y="{ enabled: true }" />
|
||||
<Add ref="addRef" v-if="addFlag" @onSubmit="tableStore.index()" />
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref, onMounted, provide } from 'vue'
|
||||
import { ref, onMounted, provide,nextTick } from 'vue'
|
||||
import TableStore from '@/utils/tableStore'
|
||||
import Table from '@/components/table/index.vue'
|
||||
import { useDictData } from '@/stores/dictData'
|
||||
@@ -42,12 +39,13 @@ const tableStore = new TableStore({
|
||||
width: '80',
|
||||
render: 'icon'
|
||||
},
|
||||
{ field: 'code', title: '组件标识' },
|
||||
{ field: 'code', title: '组件标识', minWidth: '100', },
|
||||
{ field: 'path', title: '组件路径' },
|
||||
{ field: 'image', title: '组件展示', render: 'image' },
|
||||
{
|
||||
title: '操作',
|
||||
render: 'buttons',
|
||||
width: '150',
|
||||
buttons: [
|
||||
{
|
||||
name: 'edit',
|
||||
@@ -93,9 +91,9 @@ const tableStore = new TableStore({
|
||||
loadCallback: () => {
|
||||
addFlag.value = false
|
||||
setTimeout(() => {
|
||||
tableRef.value.getRef().setAllTreeExpand(true)
|
||||
}, 1000)
|
||||
tableStore.table.data.forEach((item:any) => {
|
||||
tableRef.value?.getRef()?.setAllTreeExpand(true)
|
||||
}, 0)
|
||||
tableStore.table.data.forEach((item: any) => {
|
||||
item.state = 0
|
||||
})
|
||||
treeData.value = tree2List(tableStore.table.data, Math.random() * 1000)
|
||||
|
||||
Reference in New Issue
Block a user