diff --git a/admin-frontend-vue/src/pages/tasks/DuplicateCheckPage.vue b/admin-frontend-vue/src/pages/tasks/DuplicateCheckPage.vue index 25516409..0c0c716a 100644 --- a/admin-frontend-vue/src/pages/tasks/DuplicateCheckPage.vue +++ b/admin-frontend-vue/src/pages/tasks/DuplicateCheckPage.vue @@ -4,7 +4,7 @@ * 数据源保持自家后端:/duplicate-check-console(指标/店铺/撞款全集/分组统计) + /duplicate-check-ledger(台账分页) + /duplicate-check-export(Excel)。 * 分组归属来自「店铺管理」真实店铺分组,本页只读展示,仅用于分组撞款范围切换。 */ -import { computed, onMounted, reactive, ref } from 'vue' +import { computed, onMounted, reactive, ref, watch } from 'vue' import { useAdminSessionStore } from '@/stores/admin-session' import type { DuplicateItem, DuplicateOccurrence, DuplicateMetrics, DuplicateShop } from './duplicate-model.ts' import { fetchDuplicateConsole, fetchDuplicateLedger, requestDuplicateExportBlob, type LedgerSortKey } from './duplicate-console-api.ts' @@ -39,6 +39,8 @@ const ledgerLoading = ref(false) const jumpInput = ref('') const sortState = reactive<{ key: LedgerSortKey | ''; dir: 'asc' | 'desc' }>({ key: 'earliest', dir: 'asc' }) +import OldPagination from '@/components/OldPagination.vue' + const drawerVisible = ref(false) const drawerTitle = ref('') const drawerBrand = ref('') @@ -127,6 +129,35 @@ function itemBrand(item: DuplicateItem): string { return '' } + +// ---- 撞款视图分页(分布/矩阵/撞款详情/抽屉明细;10/20/50/100 可选) ---- +const distCount = computed(() => storeDistribution.value.list.length) +const distPage = ref(1) +const distPageSize = ref(10) +const pagedDistBars = computed(() => + storeDistribution.value.list.slice((distPage.value - 1) * distPageSize.value, distPage.value * distPageSize.value), +) +const matrixPage = ref(1) +const matrixPageSize = ref(10) +const matrixRows = computed(() => + dupRows.value.slice((matrixPage.value - 1) * matrixPageSize.value, matrixPage.value * matrixPageSize.value), +) +const dupCardPage = ref(1) +const dupCardPageSize = ref(6) +const dupCardRows = computed(() => + dupRows.value.slice((dupCardPage.value - 1) * dupCardPageSize.value, dupCardPage.value * dupCardPageSize.value), +) +const drawerPage = ref(1) +const drawerPageSize = ref(10) +const drawerRows = computed(() => + drawerAggRows.value.slice((drawerPage.value - 1) * drawerPageSize.value, drawerPage.value * drawerPageSize.value), +) +watch([dupRows, drawerOccurrences], () => { + matrixPage.value = Math.min(matrixPage.value, Math.max(1, Math.ceil(dupRows.value.length / matrixPageSize.value))) + dupCardPage.value = Math.min(dupCardPage.value, Math.max(1, Math.ceil(dupRows.value.length / dupCardPageSize.value))) + drawerPage.value = 1 +}) + const matrixHint = computed(() => scope.value === 'global' ? '行 = 全店撞款ASIN,列 = 全部店铺;有数字表示该店在售此 ASIN,点击行可看上架时间明细' @@ -452,7 +483,7 @@ onMounted(() => { 各店铺在本批站点中的上架记录量(含重复扫描)
-
+
{{ bar.name }} · {{ bar.group }} {{ bar.records.toLocaleString() }} @@ -461,6 +492,7 @@ onMounted(() => {
{{ bar.asins.toLocaleString() }} 个 ASIN
+ @@ -521,7 +553,7 @@ onMounted(() => { - + {{ item.asin }} {{ itemBrand(item) || '—' }} @@ -538,10 +570,11 @@ onMounted(() => { 调整筛选条件或切换到其他分组查看
+
撞款详情 同一 ASIN 在多家店铺的上架时间明细
-
+
{{ item.asin }} {{ item.shopCount }}店在售 @@ -636,7 +669,7 @@ onMounted(() => { 店铺分组站点上架时间(按时间升序)次数 - + {{ row.shopName }} {{ row.groupName || '—' }} {{ asinCountryLabel(row.country || '') }} diff --git a/admin-frontend-vue/src/pages/tasks/ShopDataTasksPage.vue b/admin-frontend-vue/src/pages/tasks/ShopDataTasksPage.vue index d0802e8c..a31e88d2 100644 --- a/admin-frontend-vue/src/pages/tasks/ShopDataTasksPage.vue +++ b/admin-frontend-vue/src/pages/tasks/ShopDataTasksPage.vue @@ -32,7 +32,7 @@ const loading = ref(false) const groups = ref([]) const totalShops = ref(0) const page = ref(1) -const pageSize = ref(20) +const pageSize = ref(200) const pageJump = ref('') const totalPages = computed(() => Math.max(1, Math.ceil(totalShops.value / pageSize.value))) // 卡片宫格分页:一行 3 个、一页 9 张卡片(在店铺分页的结果文件内翻页)。 @@ -338,7 +338,6 @@ onMounted(load)
共 {{ totalShops }} 家店铺 · 本页 {{ resultFileCount() }} 个结果文件 -