Files
xin-procurement/web/domain/iProductCategory.ts
T

18 lines
463 B
TypeScript

/** 商品分类(多级,children 由后端组装) */
export default interface IProductCategory {
id?: number;
parent_id?: number;
name?: string;
sort?: number;
status?: number;
icon?: number;
icon_url?: string;
children?: IProductCategory[];
created_at?: string;
}
export const CATEGORY_STATUS_MAP: Record<number, { text: string; color: string }> = {
0: { text: '停用', color: 'error' },
1: { text: '正常', color: 'success' },
};