task-62(ASIN 数据中心): 实现去重汇总列表查询
新增 dedupe-total-model.ts 纯解析 DedupeTotalDataPageVo(camel items/total/page/pageSize, 条目 dataValue/country/groupId/groupName/uploader/username/createdAt,缺 id 过滤); dedupe-total-api.ts fetchDedupeTotalList 复用共享筛选归一后 GET /api/admin/dedupe-total-data。 8 用例全过,451 单测 + build 绿。
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
/** 去重汇总列表查询适配(任务 62):GET /api/admin/dedupe-total-data + 共享筛选归一。 */
|
||||
import { http } from '@/api/http'
|
||||
import { normalizeAsinPageParams, toAsinPageQuery, type AsinListParams } from './asin-filter'
|
||||
import { parseDedupeTotalPage, type DedupeTotalPageResult } from './dedupe-total-model'
|
||||
|
||||
export const DEDUPE_TOTAL_ENDPOINT = '/api/admin/dedupe-total-data'
|
||||
|
||||
export async function fetchDedupeTotalList(params: Partial<AsinListParams> = {}): Promise<DedupeTotalPageResult> {
|
||||
const normalized = normalizeAsinPageParams(params)
|
||||
const { data } = await http.get<unknown>(DEDUPE_TOTAL_ENDPOINT, { params: toAsinPageQuery(normalized) })
|
||||
return parseDedupeTotalPage(data)
|
||||
}
|
||||
Reference in New Issue
Block a user