feat: Add table page size cache (#10146)

This commit is contained in:
CityFun 2025-08-26 17:08:13 +08:00 committed by GitHub
parent 39f334f3a2
commit fd9627576b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
41 changed files with 41 additions and 41 deletions

View file

@ -68,7 +68,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'task-list-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('task-list-page-size')) || 10,
total: 0,
small: true,
});

View file

@ -118,7 +118,7 @@ const items = ref<AI.McpServer[]>([]);
const paginationConfig = reactive({
cacheSizeKey: 'mcp-server-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('mcp-server-page-size')) || 10,
total: 0,
});
const mobile = computed(() => {

View file

@ -119,7 +119,7 @@ const loading = ref(false);
const paginationConfig = reactive({
cacheSizeKey: 'container-compose-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('container-compose-page-size')) || 10,
total: 0,
});
const searchName = ref();

View file

@ -391,7 +391,7 @@ const selects = ref<any>([]);
const paginationConfig = reactive({
cacheSizeKey: 'container-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('container-page-size')) || 10,
total: 0,
state: 'all',
orderBy: 'createdAt',

View file

@ -145,7 +145,7 @@ const repos = ref();
const paginationConfig = reactive({
cacheSizeKey: 'container-image-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('container-image-page-size')) || 10,
total: 0,
name: '',
orderBy: 'createdAt',

View file

@ -113,7 +113,7 @@ const selects = ref<any>([]);
const paginationConfig = reactive({
cacheSizeKey: 'container-network-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('container-network-page-size')) || 10,
total: 0,
});
const searchName = ref();

View file

@ -73,7 +73,7 @@ const selects = ref<any>([]);
const paginationConfig = reactive({
cacheSizeKey: 'image-repo-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('image-repo-page-size')) || 10,
total: 0,
});
const searchName = ref();

View file

@ -78,7 +78,7 @@ const selects = ref<any>([]);
const paginationConfig = reactive({
cacheSizeKey: 'compose-template-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('compose-template-page-size')) || 10,
total: 0,
});
const searchName = ref();

View file

@ -117,7 +117,7 @@ const selects = ref<any>([]);
const paginationConfig = reactive({
cacheSizeKey: 'container-volume-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('container-volume-page-size')) || 10,
total: 0,
});
const searchName = ref();

View file

@ -260,7 +260,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'cronjob-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('cronjob-page-size')) || 10,
total: 0,
orderBy: 'createdAt',
order: 'null',

View file

@ -134,7 +134,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'script-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('script-page-size')) || 10,
total: 0,
});
const searchInfo = ref<string>('');

View file

@ -93,7 +93,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'mysql-remote-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('mysql-remote-page-size')) || 10,
total: 0,
orderBy: 'createdAt',
order: 'null',

View file

@ -93,7 +93,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'postgresql-remote-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('postgresql-remote-page-size')) || 10,
total: 0,
orderBy: 'createdAt',
order: 'null',

View file

@ -92,7 +92,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'redis-remote-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('redis-remote-page-size')) || 10,
total: 0,
orderBy: 'createdAt',
order: 'null',

View file

@ -171,7 +171,7 @@ const confirmDialogRef = ref();
const paginationConfig = reactive({
cacheSizeKey: 'redis-backup-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('redis-backup-page-size')) || 10,
total: 0,
});

View file

@ -17,7 +17,7 @@ import { reactive, ref } from 'vue';
const paginationConfig = reactive({
cacheSizeKey: 'favorite-page-size',
currentPage: 1,
pageSize: 20,
pageSize: Number(localStorage.getItem('favorite-page-size')) || 20,
total: 0,
});
const req = reactive({

View file

@ -684,7 +684,7 @@ const { searchableStatus, searchablePath, searchableInputRef, searchableInputBlu
const paginationConfig = reactive({
cacheSizeKey: 'file-page-size',
currentPage: 1,
pageSize: 100,
pageSize: Number(localStorage.getItem('file-page-size')) || 10,
total: 0,
});

View file

@ -83,7 +83,7 @@ const status = ref('Enable');
const paginationConfig = reactive({
cacheSizeKey: 'recycle-page-size',
currentPage: 1,
pageSize: 20,
pageSize: Number(localStorage.getItem('recycle-page-size')) || 20,
total: 0,
});

View file

@ -102,7 +102,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'firewall-forward-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('firewall-forward-page-size')) || 10,
total: 0,
});

View file

@ -123,7 +123,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'firewall-ip-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('firewall-ip-page-size')) || 10,
total: 0,
});

View file

@ -175,7 +175,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'firewall-port-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('firewall-port-page-size')) || 10,
total: 0,
});

View file

@ -100,7 +100,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'ssh-log-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('ssh-log-page-size')) || 10,
total: 0,
});

View file

@ -218,7 +218,7 @@ const selects = ref<any>([]);
const paginationConfig = reactive({
cacheSizeKey: 'login-log-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('login-log-page-size')) || 10,
total: 0,
small: true,
});

View file

@ -61,7 +61,7 @@ const confirmDialogRef = ref();
const paginationConfig = reactive({
cacheSizeKey: 'login-log-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('login-log-page-size')) || 10,
total: 0,
});
const searchIP = ref<string>('');

View file

@ -109,7 +109,7 @@ const confirmDialogRef = ref();
const paginationConfig = reactive({
cacheSizeKey: 'operation-log-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('operation-log-page-size')) || 10,
total: 0,
});
const searchName = ref<string>('');

View file

@ -58,7 +58,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'task-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('task-page-size')) || 10,
total: 0,
});
const taskLogRef = ref();

View file

@ -124,7 +124,7 @@ const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'license-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('license-page-size')) || 10,
total: 0,
type: '',
name: '',

View file

@ -246,7 +246,7 @@ const selects = ref<any>([]);
const paginationConfig = reactive({
cacheSizeKey: 'snapshot-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('snapshot-page-size')) || 10,
total: 0,
orderBy: 'createdAt',
order: 'null',

View file

@ -106,7 +106,7 @@ const groupList = ref();
const paginationConfig = reactive({
cacheSizeKey: 'terminal-command-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('terminal-command-page-size')) || 10,
total: 0,
orderBy: 'name',
order: 'ascending',

View file

@ -94,7 +94,7 @@ const selects = ref<any>([]);
const paginationConfig = reactive({
cacheSizeKey: 'terminal-host-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('terminal-host-page-size')) || 10,
total: 0,
});
const info = ref();

View file

@ -46,7 +46,7 @@ import i18n from '@/lang';
const paginationConfig = reactive({
cacheSizeKey: 'ftp-log-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('ftp-log-page-size')) || 10,
total: 0,
user: '',
operation: '',

View file

@ -135,7 +135,7 @@ const mobile = computed(() => {
const paginationConfig = reactive({
cacheSizeKey: 'runtime-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('runtime-page-size')) || 10,
total: 0,
});
const req = reactive<Runtime.RuntimeReq>({

View file

@ -134,7 +134,7 @@ const isExist = ref(false);
const paginationConfig = reactive({
cacheSizeKey: 'runtime-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('runtime-page-size')) || 10,
total: 0,
});
const req = reactive<Runtime.RuntimeReq>({

View file

@ -134,7 +134,7 @@ const isExist = ref(false);
const paginationConfig = reactive({
cacheSizeKey: 'runtime-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('runtime-page-size')) || 10,
total: 0,
});
const req = reactive<Runtime.RuntimeReq>({

View file

@ -137,7 +137,7 @@ const isExist = ref(false);
const paginationConfig = reactive({
cacheSizeKey: 'runtime-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('runtime-page-size')) || 10,
total: 0,
});
const req = reactive<Runtime.RuntimeReq>({

View file

@ -163,7 +163,7 @@ const taskLogRef = ref();
const paginationConfig = reactive({
cacheSizeKey: 'runtime-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('runtime-page-size')) || 10,
total: 0,
});
let req = reactive<Runtime.RuntimeReq>({

View file

@ -134,7 +134,7 @@ const isExist = ref(false);
const paginationConfig = reactive({
cacheSizeKey: 'runtime-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('runtime-page-size')) || 10,
total: 0,
});
const req = reactive<Runtime.RuntimeReq>({

View file

@ -63,7 +63,7 @@ const createRef = ref();
const paginationConfig = reactive({
cacheSizeKey: 'acme-account-page-size',
currentPage: 1,
pageSize: 20,
pageSize: Number(localStorage.getItem('acme-account-page-size')) || 20,
total: 0,
});
const opRef = ref();

View file

@ -50,7 +50,7 @@ const createRef = ref();
const paginationConfig = reactive({
cacheSizeKey: 'ca-page-size',
currentPage: 1,
pageSize: 20,
pageSize: Number(localStorage.getItem('ca-page-size')) || 20,
total: 0,
});
const opRef = ref();

View file

@ -43,7 +43,7 @@ import { getDNSName } from '@/utils/util';
const paginationConfig = reactive({
cacheSizeKey: 'dns-account-page-size',
currentPage: 1,
pageSize: 20,
pageSize: Number(localStorage.getItem('dns-account-page-size')) || 20,
total: 0,
});
let data = ref<Website.DnsAccount[]>();

View file

@ -188,7 +188,7 @@ const globalStore = GlobalStore();
const paginationConfig = reactive({
cacheSizeKey: 'ssl-page-size',
currentPage: 1,
pageSize: 10,
pageSize: Number(localStorage.getItem('ssl-page-size')) || 10,
total: 0,
});
const acmeAccountRef = ref();