mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2024-11-13 02:55:18 +08:00
feat: 表格增加手动刷新按钮
This commit is contained in:
parent
2565373db6
commit
b84e4d148f
20 changed files with 56 additions and 18 deletions
|
@ -6,6 +6,7 @@ import ErrPrompt from './error-prompt/index.vue';
|
|||
import OpDialog from './del-dialog/index.vue';
|
||||
import TableSearch from './table-search/index.vue';
|
||||
import TableSetting from './table-setting/index.vue';
|
||||
import TableRefresh from './table-refresh/index.vue';
|
||||
import Tooltip from '@/components/tooltip/index.vue';
|
||||
import CopyButton from '@/components/copy-button/index.vue';
|
||||
import MsgInfo from '@/components/msg-info/index.vue';
|
||||
|
@ -22,6 +23,7 @@ export default {
|
|||
app.component(CopyButton.name, CopyButton);
|
||||
app.component(TableSearch.name, TableSearch);
|
||||
app.component(TableSetting.name, TableSetting);
|
||||
app.component(TableRefresh.name, TableRefresh);
|
||||
app.component(MsgInfo.name, MsgInfo);
|
||||
app.component(MainDiv.name, MainDiv);
|
||||
app.component(DrawerPro.name, DrawerPro);
|
||||
|
|
19
frontend/src/components/table-refresh/index.vue
Normal file
19
frontend/src/components/table-refresh/index.vue
Normal file
|
@ -0,0 +1,19 @@
|
|||
<template>
|
||||
<el-button class="fresh-button" icon="Refresh" @click="onRefresh"></el-button>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
defineOptions({ name: 'TableRefresh' });
|
||||
|
||||
const emit = defineEmits(['search']);
|
||||
|
||||
const onRefresh = () => {
|
||||
emit('search');
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.fresh-button {
|
||||
float: right;
|
||||
}
|
||||
</style>
|
|
@ -2,7 +2,7 @@
|
|||
<div>
|
||||
<el-popover placement="bottom-start" :width="200" trigger="click">
|
||||
<template #reference>
|
||||
<el-button class="timer-button" icon="Refresh"></el-button>
|
||||
<el-button class="timer-button" icon="Clock"></el-button>
|
||||
</template>
|
||||
<el-select v-model="refreshRate" @change="changeRefresh">
|
||||
<template #prefix>{{ $t('commons.table.refreshRate') }}</template>
|
||||
|
|
|
@ -31,7 +31,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="compose-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -106,6 +106,7 @@
|
|||
{{ $t('container.includeAppstore') }}
|
||||
</el-checkbox>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="container-refresh" @search="refresh()" class="mr-2.5" />
|
||||
<fu-table-column-select
|
||||
:columns="columns"
|
||||
|
|
|
@ -26,7 +26,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="image-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable :pagination-config="paginationConfig" :data="data" @search="search" :heightDiff="300">
|
||||
|
|
|
@ -20,7 +20,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="network-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -14,7 +14,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="repo-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -17,7 +17,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="template-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -20,7 +20,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="volume-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -27,7 +27,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="cronjob-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -28,7 +28,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="firewall-forward-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -35,7 +35,8 @@
|
|||
<el-option :label="$t('firewall.deny')" value="drop"></el-option>
|
||||
</el-select>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="firewall-ip-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -57,7 +57,8 @@
|
|||
<el-option :label="$t('firewall.drop')" value="drop"></el-option>
|
||||
</el-select>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="firewall-port-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
|
@ -12,8 +12,9 @@
|
|||
<el-option :label="$t('commons.status.success')" value="Success"></el-option>
|
||||
<el-option :label="$t('commons.status.failed')" value="Failed"></el-option>
|
||||
</el-select>
|
||||
<TableSetting @search="search()" class="mr-2.5" />
|
||||
<TableSearch @search="search()" v-model:searchName="searchInfo" />
|
||||
<TableSearch @search="search()" v-model:searchName="searchInfo" class="mr-2.5" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="ssh-log-refresh" @search="search()" />
|
||||
</template>
|
||||
|
||||
<template #main>
|
||||
|
|
|
@ -17,7 +17,8 @@
|
|||
<el-option :label="$t('commons.status.failed')" value="Failed"></el-option>
|
||||
</el-select>
|
||||
<TableSearch @search="search()" v-model:searchName="searchIP" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="login-log-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable :pagination-config="paginationConfig" :data="data" @search="search" :heightDiff="370">
|
||||
|
|
|
@ -32,7 +32,8 @@
|
|||
<el-option :label="$t('commons.status.failed')" value="Failed"></el-option>
|
||||
</el-select>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="operation-log-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable :pagination-config="paginationConfig" :data="data" @search="search" :heightDiff="370">
|
||||
|
|
|
@ -12,7 +12,8 @@
|
|||
<el-option :label="$t('commons.status.failed')" value="Failed"></el-option>
|
||||
<el-option :label="$t('logs.taskRunning')" value="Running"></el-option>
|
||||
</el-select>
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="task-log-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable :pagination-config="paginationConfig" :data="data" @search="search" :heightDiff="370">
|
||||
|
|
|
@ -8,7 +8,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="paginationConfig.name" class="mr-2.5" />
|
||||
<TableSetting @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="backup-account-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<el-alert type="info" :closable="false" class="common-div">
|
||||
|
|
|
@ -17,7 +17,8 @@
|
|||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableSearch @search="search()" v-model:searchName="searchName" class="mr-2.5" />
|
||||
<TableSetting ref="timerRef" @search="search()" />
|
||||
<TableRefresh @search="search()" class="mr-2.5" />
|
||||
<TableSetting title="snapshot-refresh" ref="timerRef" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable
|
||||
|
|
Loading…
Reference in a new issue