This commit is contained in:
ah--desktop
2026-01-12 00:14:47 +08:00
parent e1f39c1815
commit 59a649f002
65 changed files with 5097 additions and 369 deletions
@@ -0,0 +1,55 @@
import type { BrushOrderDTO, BrushOrderVO } from './types';
import type { PageQueryDTO, PageResultVO } from '#/types/common';
import { requestClient } from '#/api/request';
/**
* 刷单记录管理API
*/
/**
* 创建刷单记录
*/
export async function createBrushOrderApi(data: BrushOrderDTO.Create) {
return requestClient.post<BrushOrderVO.Info>('/ec/brush-order/create', data);
}
/**
* 更新刷单记录
*/
export async function updateBrushOrderApi(
id: number,
data: BrushOrderDTO.Update,
) {
return requestClient.put<BrushOrderVO.Info>(
`/ec/brush-order/update/${id}`,
data,
);
}
/**
* 删除刷单记录
*/
export async function deleteBrushOrderApi(id: number) {
return requestClient.delete(`/ec/brush-order/delete/${id}`);
}
/**
* 分页获取刷单记录列表
*/
export async function getBrushOrderPageApi(
params: PageQueryDTO<BrushOrderDTO.Filters>,
) {
return requestClient.post<PageResultVO<BrushOrderVO.Info>>(
'/ec/brush-order/page',
params,
);
}
/**
* 获取刷单记录详情
*/
export async function getBrushOrderByIdApi(id: number) {
return requestClient.get<BrushOrderVO.Info>(`/ec/brush-order/detail/${id}`);
}
@@ -0,0 +1,6 @@
/**
* 刷单记录管理模块API导出
*/
export * from './apis';
export * from './types';
@@ -0,0 +1,6 @@
/**
* 刷单记录管理模块类型定义导出
*/
export * from './types.dto';
export * from './types.vo';
@@ -0,0 +1,63 @@
/**
* 刷单记录相关DTO类型定义
*/
export namespace BrushOrderDTO {
/** 创建刷单记录参数 */
export interface Create {
/** 店铺ID */
shopId: number;
/** 商品ID(可选) */
productId?: number;
/** 商品规格ID(可选) */
productSpecId?: number;
/** 刷单金额 */
brushAmount: number;
/** 刷单时间 */
brushTime: string;
/** 平台订单号(可选) */
platformOrderNo?: string;
/** 刷单数量 */
quantity?: number;
/** 备注 */
remark?: string;
}
/** 更新刷单记录参数 */
export interface Update {
/** 店铺ID */
shopId: number;
/** 商品ID(可选) */
productId?: number;
/** 商品规格ID(可选) */
productSpecId?: number;
/** 刷单金额 */
brushAmount: number;
/** 刷单时间 */
brushTime: string;
/** 平台订单号(可选) */
platformOrderNo?: string;
/** 刷单数量 */
quantity?: number;
/** 备注 */
remark?: string;
}
/** 刷单记录过滤条件 */
export interface Filters {
/** 店铺ID */
shopId?: number;
/** 商品ID */
productId?: number;
/** 平台订单号(模糊查询) */
platformOrderNo?: string;
/** 刷单金额范围-最小值 */
minBrushAmount?: number;
/** 刷单金额范围-最大值 */
maxBrushAmount?: number;
/** 刷单时间范围-开始时间 */
startBrushTime?: string;
/** 刷单时间范围-结束时间 */
endBrushTime?: string;
}
}
@@ -0,0 +1,43 @@
/**
* 刷单记录相关VO类型定义
*/
export namespace BrushOrderVO {
/** 刷单记录信息 */
export interface Info {
/** 刷单记录ID */
id: number;
/** 公司ID */
companyId: number;
/** 店铺ID */
shopId: number;
/** 店铺名称 */
shopName: string;
/** 商品ID */
productId?: number;
/** 商品名称 */
productName?: string;
/** 商品规格ID */
productSpecId?: number;
/** 商品规格名称 */
productSpecName?: string;
/** 刷单金额 */
brushAmount: number;
/** 刷单时间 */
brushTime: string;
/** 平台订单号 */
platformOrderNo?: string;
/** 刷单数量 */
quantity?: number;
/** 备注 */
remark?: string;
/** 创建时间 */
createTime: string;
/** 更新时间 */
updateTime: string;
/** 创建人ID */
createBy?: number;
/** 更新人ID */
updateBy?: number;
}
}