|
|
@@ -1,131 +1,141 @@
|
|
|
<template>
|
|
|
- <div class="page">
|
|
|
- <el-tabs type="card" class="my-tabs" v-model="activeName" @tab-change="handleTabClick">
|
|
|
- <el-tab-pane label="当前菜单" name="current">
|
|
|
- <el-form :inline="true" v-if="searchVisible" class="query-form m-b-10" ref="searchForm"
|
|
|
- :model="searchForm" @keyup.enter.native="refreshList()" @submit.native.prevent>
|
|
|
- <el-form-item label="菜品名称" prop="dishName">
|
|
|
- <el-input v-model="searchForm.dishName" placeholder="请输入菜品名称" clearable></el-input>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item label="菜品分类" prop="typeId">
|
|
|
- <SelectTree ref="searchDishTypeTree" :props="{
|
|
|
- value: 'id',
|
|
|
- label: 'name',
|
|
|
- children: 'children'
|
|
|
- }" url="/psi-management-server/psi/dishType/treeData" :value="searchForm.typeId" :clearable="true"
|
|
|
- :accordion="true" size="default" style="width: 180px"
|
|
|
- @getValue="(value) => { searchForm.typeId = value }" />
|
|
|
- </el-form-item>
|
|
|
- <el-form-item label="状态" prop="status">
|
|
|
- <el-select v-model="searchForm.status" placeholder="请选择状态" clearable style="width: 120px">
|
|
|
- <el-option label="启用" value="0"></el-option>
|
|
|
- <el-option label="停用" value="1"></el-option>
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item>
|
|
|
- <el-button type="primary" @click="refreshList()" icon="el-icon-search">查询</el-button>
|
|
|
- <el-button @click="resetSearch()" icon="el-icon-refresh-right">重置</el-button>
|
|
|
- </el-form-item>
|
|
|
- </el-form>
|
|
|
+ <splitpanes class="default-theme">
|
|
|
+ <pane size="14" min-size="10" max-size="30">
|
|
|
+ <el-container class="jp-container">
|
|
|
+ <el-header class="m-p-13-15">
|
|
|
+ <el-input placeholder="请输入分类名称过滤" clearable v-model="filterText"></el-input>
|
|
|
+ </el-header>
|
|
|
+ <el-main class="nopadding" v-loading="treeLoading">
|
|
|
+ <el-tree class="filter-tree" :data="typeTreeData" :props="{
|
|
|
+ label: 'name',
|
|
|
+ children: 'children'
|
|
|
+ }" node-key="id" default-expand-all highlight-current :expand-on-click-node="false"
|
|
|
+ :filter-node-method="filterNode" @node-click="handleNodeClick" ref="dishTypeTree"></el-tree>
|
|
|
+ </el-main>
|
|
|
+ <el-footer style="height: 51px">
|
|
|
+ <el-button type="default" size="small" icon="el-icon-refresh" @click="refreshTree()"></el-button>
|
|
|
+ </el-footer>
|
|
|
+ </el-container>
|
|
|
+ </pane>
|
|
|
+ <pane size="86">
|
|
|
+ <el-tabs type="card" class="my-tabs" v-model="activeName" @tab-change="handleTabClick">
|
|
|
+ <el-tab-pane label="当前菜单" name="current" class="current-pane">
|
|
|
+ <el-form :inline="true" v-if="searchVisible" class="query-form m-b-10" ref="searchForm"
|
|
|
+ :model="searchForm" @keyup.enter.native="refreshList()" @submit.native.prevent>
|
|
|
+ <el-form-item label="菜品名称" prop="dishName">
|
|
|
+ <el-input v-model="searchForm.dishName" placeholder="请输入菜品名称" clearable></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="状态" prop="status">
|
|
|
+ <el-select v-model="searchForm.status" placeholder="请选择状态" clearable style="width: 120px">
|
|
|
+ <el-option label="启用" value="0"></el-option>
|
|
|
+ <el-option label="停用" value="1"></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item>
|
|
|
+ <el-button type="primary" @click="refreshList()" icon="el-icon-search">查询</el-button>
|
|
|
+ <el-button @click="resetSearch()" icon="el-icon-refresh-right">重置</el-button>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
|
|
|
- <div class="jp-table top">
|
|
|
- <vxe-toolbar :refresh="{ query: refreshList }" custom>
|
|
|
- <template #buttons>
|
|
|
+ <div class="jp-table top">
|
|
|
+ <vxe-toolbar :refresh="{ query: refreshList }" custom>
|
|
|
+ <template #buttons>
|
|
|
|
|
|
- <el-button type="primary" icon="el-icon-plus" v-if="hasPermission('psi:menu:add')"
|
|
|
- @click="openDishDialog()">添加菜品</el-button>
|
|
|
- <el-button type="primary" icon="el-icon-refresh" v-if="hasPermission('psi:menu:edit')"
|
|
|
- @click="updateMenu()">更新</el-button>
|
|
|
- <el-button type="danger" icon="el-icon-delete" plain @click="del()"
|
|
|
- :disabled="$refs.dishTable && $refs.dishTable.getCheckboxRecords().length === 0"
|
|
|
- v-if="hasPermission('psi:menu:del')">删除</el-button>
|
|
|
- </template>
|
|
|
- <template #tools>
|
|
|
- <vxe-button text type="primary" :title="searchVisible ? '收起检索' : '展开检索'"
|
|
|
- icon="vxe-icon-search" class="tool-btn"
|
|
|
- @click="searchVisible = !searchVisible"></vxe-button>
|
|
|
- </template>
|
|
|
- </vxe-toolbar>
|
|
|
- <div style="height: calc(100% - 50px)">
|
|
|
- <vxe-table border="inner" auto-resize resizable height="auto" :loading="loading" ref="dishTable"
|
|
|
- show-header-overflow show-overflow highlight-hover-row :menu-config="{}" :data="dataList"
|
|
|
- :tree-config="{ transform: true, rowField: 'treeId', parentField: 'treeParentId', expandAll: true }"
|
|
|
- :checkbox-config="{ checkMethod: ({ row }) => !row.isCategory }">
|
|
|
- <vxe-column type="seq" width="60" title="序号"></vxe-column>
|
|
|
- <vxe-column type="checkbox" width="60"></vxe-column>
|
|
|
- <vxe-column min-width="220" align="left" title="菜品名称" field="dishName"
|
|
|
- tree-node></vxe-column>
|
|
|
- <vxe-column width="80" align="center" title="菜品图片" field="imageUrl">
|
|
|
- <template #default="scope">
|
|
|
- <el-image v-if="!scope.row.isCategory && scope.row.previewImageUrl"
|
|
|
- :src="scope.row.previewImageUrl" :preview-src-list="scope.row.previewImageList"
|
|
|
- fit="cover" style="width: 44px; height: 44px; border-radius: 4px;"
|
|
|
- hide-on-click-modal append-to-body :z-index="9999"></el-image>
|
|
|
- <span v-else-if="!scope.row.isCategory">暂无图片</span>
|
|
|
- </template>
|
|
|
- </vxe-column>
|
|
|
- <vxe-column min-width="150" align="center" title="菜品编码" field="dishCode"></vxe-column>
|
|
|
- <vxe-column min-width="150" align="center" title="菜品分类" field="typeName"></vxe-column>
|
|
|
- <vxe-column width="90" align="center" title="单位" field="unit"></vxe-column>
|
|
|
- <vxe-column width="120" align="center" title="菜品库价格" field="librarySalePrice"></vxe-column>
|
|
|
- <vxe-column width="120" align="center" title="菜单价格" field="salePrice"></vxe-column>
|
|
|
- <vxe-column width="100" align="center" title="状态" field="status">
|
|
|
- <template #default="scope">
|
|
|
- <el-tag v-if="!scope.row.isCategory"
|
|
|
- :type="scope.row.status === '0' ? 'success' : 'info'">
|
|
|
- {{ scope.row.status === '0' ? '启用' : '停用' }}
|
|
|
- </el-tag>
|
|
|
- </template>
|
|
|
- </vxe-column>
|
|
|
- <vxe-column min-width="130" align="center" title="创建人" field="createName"></vxe-column>
|
|
|
- <vxe-column min-width="180" align="center" title="创建时间" field="createTime"></vxe-column>
|
|
|
- <vxe-column title="操作" width="180px" fixed="right" align="center">
|
|
|
- <template #default="scope">
|
|
|
- <el-button text type="primary" size="small"
|
|
|
- v-if="!scope.row.isCategory && hasPermission('psi:menu:edit')"
|
|
|
- @click="openPriceDialog(scope.row)">修改价格</el-button>
|
|
|
- <el-button text type="primary" size="small" @click="del(scope.row.id)"
|
|
|
- v-if="!scope.row.isCategory && hasPermission('psi:menu:del')">删除</el-button>
|
|
|
- </template>
|
|
|
- </vxe-column>
|
|
|
- </vxe-table>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </el-tab-pane>
|
|
|
- <el-tab-pane label="历史菜单" name="history">
|
|
|
- <div class="jp-table history-table">
|
|
|
- <vxe-toolbar :refresh="{ query: refreshHistoryList }" custom></vxe-toolbar>
|
|
|
- <vxe-table border="inner" auto-resize resizable height="auto" :loading="historyLoading"
|
|
|
- show-header-overflow show-overflow highlight-hover-row :data="historyList">
|
|
|
- <vxe-column type="seq" width="60" title="序号"></vxe-column>
|
|
|
- <vxe-column min-width="180" align="center" title="更新时间" field="historyTime"></vxe-column>
|
|
|
- <vxe-column min-width="180" align="center" title="创建时间" field="createTime"></vxe-column>
|
|
|
- <vxe-column min-width="130" align="center" title="操作人" field="createName"></vxe-column>
|
|
|
- <vxe-column width="120" align="center" title="菜品数量" field="dishCount"></vxe-column>
|
|
|
- <vxe-column title="操作" width="120px" fixed="right" align="center">
|
|
|
- <template #default="scope">
|
|
|
- <el-button text type="primary" size="small"
|
|
|
- @click="openHistoryDetail(scope.row)">详情</el-button>
|
|
|
+ <el-button type="primary" icon="el-icon-plus" v-if="hasPermission('psi:menu:add')"
|
|
|
+ @click="openDishDialog()">添加菜品</el-button>
|
|
|
+ <el-button type="primary" icon="el-icon-refresh" v-if="hasPermission('psi:menu:edit')"
|
|
|
+ @click="updateMenu()">更新</el-button>
|
|
|
+ <el-button type="danger" icon="el-icon-delete" plain @click="del()"
|
|
|
+ :disabled="$refs.dishTable && $refs.dishTable.getCheckboxRecords().length === 0"
|
|
|
+ v-if="hasPermission('psi:menu:del')">删除</el-button>
|
|
|
+ </template>
|
|
|
+ <template #tools>
|
|
|
+ <vxe-button text type="primary" :title="searchVisible ? '收起检索' : '展开检索'"
|
|
|
+ icon="vxe-icon-search" class="tool-btn"
|
|
|
+ @click="searchVisible = !searchVisible"></vxe-button>
|
|
|
</template>
|
|
|
- </vxe-column>
|
|
|
- </vxe-table>
|
|
|
- <vxe-pager background :current-page="historyPage.currentPage" :page-size="historyPage.pageSize"
|
|
|
- :total="historyPage.total" :page-sizes="[10, 20, 100, 1000]"
|
|
|
- :layouts="['PrevPage', 'JumpNumber', 'NextPage', 'FullJump', 'Sizes', 'Total']"
|
|
|
- @page-change="historyPageChange">
|
|
|
- </vxe-pager>
|
|
|
- </div>
|
|
|
- </el-tab-pane>
|
|
|
- </el-tabs>
|
|
|
+ </vxe-toolbar>
|
|
|
+ <div style="height: calc(100% - 50px)">
|
|
|
+ <vxe-table border="inner" auto-resize resizable height="auto" :loading="loading"
|
|
|
+ ref="dishTable" show-header-overflow show-overflow highlight-hover-row :menu-config="{}"
|
|
|
+ :data="dataList" :checkbox-config="{}">
|
|
|
+ <vxe-column type="seq" width="60" title="序号"></vxe-column>
|
|
|
+ <vxe-column type="checkbox" width="60"></vxe-column>
|
|
|
+ <vxe-column min-width="220" align="left" title="菜品名称" field="dishName"></vxe-column>
|
|
|
+ <vxe-column width="80" align="center" title="菜品图片" field="imageUrl">
|
|
|
+ <template #default="scope">
|
|
|
+ <el-image v-if="scope.row.previewImageUrl"
|
|
|
+ :src="scope.row.previewImageUrl" :preview-src-list="scope.row.previewImageList"
|
|
|
+ fit="cover" style="width: 44px; height: 44px; border-radius: 4px;"
|
|
|
+ hide-on-click-modal append-to-body :z-index="9999"></el-image>
|
|
|
+ <span v-else>暂无图片</span>
|
|
|
+ </template>
|
|
|
+ </vxe-column>
|
|
|
+ <vxe-column min-width="150" align="center" title="菜品编码" field="dishCode"></vxe-column>
|
|
|
+ <vxe-column min-width="150" align="center" title="菜品分类" field="typeName"></vxe-column>
|
|
|
+ <vxe-column width="90" align="center" title="单位" field="unit"></vxe-column>
|
|
|
+ <vxe-column width="120" align="center" title="菜品库价格" field="librarySalePrice"></vxe-column>
|
|
|
+ <vxe-column width="120" align="center" title="菜单价格" field="salePrice"></vxe-column>
|
|
|
+ <vxe-column width="100" align="center" title="状态" field="status">
|
|
|
+ <template #default="scope">
|
|
|
+ <el-tag :type="scope.row.status === '0' ? 'success' : 'info'">
|
|
|
+ {{ scope.row.status === '0' ? '启用' : '停用' }}
|
|
|
+ </el-tag>
|
|
|
+ </template>
|
|
|
+ </vxe-column>
|
|
|
+ <vxe-column min-width="130" align="center" title="创建人" field="createName"></vxe-column>
|
|
|
+ <vxe-column min-width="180" align="center" title="创建时间" field="createTime"></vxe-column>
|
|
|
+ <vxe-column title="操作" width="180px" fixed="right" align="center">
|
|
|
+ <template #default="scope">
|
|
|
+ <el-button text type="primary" size="small"
|
|
|
+ v-if="hasPermission('psi:menu:edit')"
|
|
|
+ @click="openPriceDialog(scope.row)">修改价格</el-button>
|
|
|
+ <el-button text type="primary" size="small" @click="del(scope.row.id)"
|
|
|
+ v-if="hasPermission('psi:menu:del')">删除</el-button>
|
|
|
+ </template>
|
|
|
+ </vxe-column>
|
|
|
+ </vxe-table>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </el-tab-pane>
|
|
|
+ <el-tab-pane label="历史菜单" name="history" class="history-pane">
|
|
|
+ <div class="jp-table history-table">
|
|
|
+ <vxe-toolbar :refresh="{ query: refreshHistoryList }" custom></vxe-toolbar>
|
|
|
+ <div style="height: calc(100% - 90px)">
|
|
|
+ <vxe-table border="inner" auto-resize resizable height="auto" :loading="historyLoading"
|
|
|
+ show-header-overflow show-overflow highlight-hover-row :data="historyList">
|
|
|
+ <vxe-column type="seq" width="60" title="序号"></vxe-column>
|
|
|
+ <vxe-column min-width="180" align="center" title="更新时间" field="historyTime"></vxe-column>
|
|
|
+ <vxe-column min-width="180" align="center" title="创建时间" field="createTime"></vxe-column>
|
|
|
+ <vxe-column min-width="130" align="center" title="操作人" field="createName"></vxe-column>
|
|
|
+ <vxe-column width="120" align="center" title="菜品数量" field="dishCount"></vxe-column>
|
|
|
+ <vxe-column title="操作" width="120px" fixed="right" align="center">
|
|
|
+ <template #default="scope">
|
|
|
+ <el-button text type="primary" size="small"
|
|
|
+ @click="openHistoryDetail(scope.row)">详情</el-button>
|
|
|
+ </template>
|
|
|
+ </vxe-column>
|
|
|
+ </vxe-table>
|
|
|
+ <vxe-pager background :current-page="historyPage.currentPage" :page-size="historyPage.pageSize"
|
|
|
+ :total="historyPage.total" :page-sizes="[10, 20, 100, 1000]"
|
|
|
+ :layouts="['PrevPage', 'JumpNumber', 'NextPage', 'FullJump', 'Sizes', 'Total']"
|
|
|
+ @page-change="historyPageChange">
|
|
|
+ </vxe-pager>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </el-tab-pane>
|
|
|
+ </el-tabs>
|
|
|
+ </pane>
|
|
|
+ </splitpanes>
|
|
|
|
|
|
- <DishMenuDishDialog ref="dishMenuDishDialog" @refreshList="refreshList"></DishMenuDishDialog>
|
|
|
- <DishMenuPriceDialog ref="dishMenuPriceDialog" @refreshList="refreshList"></DishMenuPriceDialog>
|
|
|
- <DishMenuHistoryDetailDialog ref="dishMenuHistoryDetailDialog"></DishMenuHistoryDetailDialog>
|
|
|
- </div>
|
|
|
+ <DishMenuDishDialog ref="dishMenuDishDialog" @refreshList="refreshList"></DishMenuDishDialog>
|
|
|
+ <DishMenuPriceDialog ref="dishMenuPriceDialog" @refreshList="refreshList"></DishMenuPriceDialog>
|
|
|
+ <DishMenuHistoryDetailDialog ref="dishMenuHistoryDetailDialog"></DishMenuHistoryDetailDialog>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import SelectTree from '@/components/treeSelect/treeSelect.vue'
|
|
|
+import { Splitpanes, Pane } from 'splitpanes'
|
|
|
+import 'splitpanes/dist/splitpanes.css'
|
|
|
import OSSSerivce from '@/api/sys/OSSService'
|
|
|
import DishMenuService from '@/api/psi/DishMenuService'
|
|
|
import DishTypeService from '@/api/psi/DishTypeService'
|
|
|
@@ -138,6 +148,9 @@ export default {
|
|
|
return {
|
|
|
activeName: 'current',
|
|
|
searchVisible: true,
|
|
|
+ filterText: '',
|
|
|
+ typeTreeData: [],
|
|
|
+ treeLoading: false,
|
|
|
searchForm: {
|
|
|
dishName: '',
|
|
|
typeId: '',
|
|
|
@@ -169,18 +182,46 @@ export default {
|
|
|
this.ossService = new OSSSerivce()
|
|
|
},
|
|
|
components: {
|
|
|
- SelectTree,
|
|
|
+ Splitpanes,
|
|
|
+ Pane,
|
|
|
DishMenuDishDialog,
|
|
|
DishMenuPriceDialog,
|
|
|
DishMenuHistoryDetailDialog
|
|
|
},
|
|
|
mounted() {
|
|
|
+ this.refreshTree()
|
|
|
this.refreshList()
|
|
|
},
|
|
|
activated() {
|
|
|
+ this.refreshTree()
|
|
|
this.refreshList()
|
|
|
},
|
|
|
+ watch: {
|
|
|
+ filterText(val) {
|
|
|
+ this.$refs.dishTypeTree.filter(val)
|
|
|
+ }
|
|
|
+ },
|
|
|
methods: {
|
|
|
+ refreshTree() {
|
|
|
+ this.treeLoading = true
|
|
|
+ this.dishTypeService.treeData().then((data) => {
|
|
|
+ // 前置虚拟根节点,点击时查询全部菜单菜品
|
|
|
+ this.typeTreeData = [{ id: '', name: '全部菜品分类', children: data }]
|
|
|
+ this.treeLoading = false
|
|
|
+ }).catch(() => {
|
|
|
+ this.treeLoading = false
|
|
|
+ })
|
|
|
+ },
|
|
|
+ filterNode(value, data) {
|
|
|
+ if (!value) return true
|
|
|
+ return data.name.indexOf(value) !== -1
|
|
|
+ },
|
|
|
+ handleNodeClick(data) {
|
|
|
+ this.searchForm.typeId = data.id || ''
|
|
|
+ if (this.activeName === 'current') {
|
|
|
+ this.refreshList()
|
|
|
+ }
|
|
|
+ },
|
|
|
handleTabClick() {
|
|
|
if (this.activeName === 'history') {
|
|
|
this.refreshHistoryList()
|
|
|
@@ -190,70 +231,19 @@ export default {
|
|
|
},
|
|
|
refreshList() {
|
|
|
this.loading = true
|
|
|
- Promise.all([
|
|
|
- this.dishTypeService.list({}),
|
|
|
- this.dishMenuService.list({
|
|
|
- current: 1,
|
|
|
- size: 1000000,
|
|
|
- orders: this.tablePage.orders,
|
|
|
- ...this.searchForm
|
|
|
- })
|
|
|
- ]).then(([typeList, data]) => {
|
|
|
- const dishList = data && data.records ? data.records : []
|
|
|
- this.dataList = this.buildCurrentMenuTree(typeList || [], dishList)
|
|
|
- this.loadImagePreview(this.dataList.filter(item => !item.isCategory))
|
|
|
+ this.dishMenuService.list({
|
|
|
+ current: 1,
|
|
|
+ size: 1000000,
|
|
|
+ orders: this.tablePage.orders,
|
|
|
+ ...this.searchForm
|
|
|
+ }).then((data) => {
|
|
|
+ this.dataList = data && data.records ? data.records : []
|
|
|
+ this.loadImagePreview(this.dataList)
|
|
|
this.loading = false
|
|
|
- this.$nextTick(() => {
|
|
|
- if (this.$refs.dishTable) {
|
|
|
- this.$refs.dishTable.setAllTreeExpand(true)
|
|
|
- }
|
|
|
- })
|
|
|
}).catch(() => {
|
|
|
this.loading = false
|
|
|
})
|
|
|
},
|
|
|
- buildCurrentMenuTree(typeList, dishList) {
|
|
|
- const typeMap = new Map(typeList.map(item => [item.id, item]))
|
|
|
- const usedTypeIdSet = new Set()
|
|
|
- dishList.forEach(item => {
|
|
|
- let typeId = item.typeId
|
|
|
- while (typeId && typeId !== '0' && typeMap.has(typeId) && !usedTypeIdSet.has(typeId)) {
|
|
|
- usedTypeIdSet.add(typeId)
|
|
|
- typeId = typeMap.get(typeId).parentId
|
|
|
- }
|
|
|
- })
|
|
|
-
|
|
|
- const rows = typeList.filter(item => usedTypeIdSet.has(item.id)).map(item => {
|
|
|
- return {
|
|
|
- treeId: `type:${item.id}`,
|
|
|
- treeParentId: usedTypeIdSet.has(item.parentId) ? `type:${item.parentId}` : null,
|
|
|
- isCategory: true,
|
|
|
- dishName: item.name
|
|
|
- }
|
|
|
- })
|
|
|
-
|
|
|
- const hasUncategorized = dishList.some(item => !item.typeId || !typeMap.has(item.typeId))
|
|
|
- if (hasUncategorized) {
|
|
|
- rows.push({
|
|
|
- treeId: 'type:uncategorized',
|
|
|
- treeParentId: null,
|
|
|
- isCategory: true,
|
|
|
- dishName: '未分类'
|
|
|
- })
|
|
|
- }
|
|
|
-
|
|
|
- dishList.forEach(item => {
|
|
|
- rows.push({
|
|
|
- ...item,
|
|
|
- treeId: `dish:${item.id}`,
|
|
|
- treeParentId: item.typeId && typeMap.has(item.typeId)
|
|
|
- ? `type:${item.typeId}`
|
|
|
- : 'type:uncategorized',
|
|
|
- isCategory: false
|
|
|
- })
|
|
|
- })
|
|
|
- return rows
|
|
|
- },
|
|
|
refreshHistoryList() {
|
|
|
this.historyLoading = true
|
|
|
this.dishMenuService.historyList({
|
|
|
@@ -335,6 +325,7 @@ export default {
|
|
|
resetSearch() {
|
|
|
this.$refs.searchForm.resetFields()
|
|
|
this.searchForm.typeId = ''
|
|
|
+ this.$refs.dishTypeTree.setCurrentKey(null)
|
|
|
this.tablePage.currentPage = 1
|
|
|
this.refreshList()
|
|
|
}
|
|
|
@@ -356,10 +347,35 @@ export default {
|
|
|
|
|
|
.my-tabs :deep(.el-tab-pane) {
|
|
|
height: 100%;
|
|
|
- overflow: auto;
|
|
|
+}
|
|
|
+
|
|
|
+.current-pane {
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ overflow: hidden;
|
|
|
+}
|
|
|
+
|
|
|
+.current-pane .query-form {
|
|
|
+ flex: none;
|
|
|
+ margin-bottom: 6px !important;
|
|
|
+}
|
|
|
+
|
|
|
+.current-pane .jp-table {
|
|
|
+ flex: 1;
|
|
|
+ min-height: 0;
|
|
|
+ overflow: hidden;
|
|
|
+ background-color: #fff;
|
|
|
+ border-radius: 4px;
|
|
|
+}
|
|
|
+
|
|
|
+.history-pane {
|
|
|
+ overflow: hidden;
|
|
|
}
|
|
|
|
|
|
.history-table {
|
|
|
- height: calc(100% - 4px);
|
|
|
+ height: 100%;
|
|
|
+ overflow: hidden;
|
|
|
+ background-color: #fff;
|
|
|
+ border-radius: 4px;
|
|
|
}
|
|
|
</style>
|