/** 客户实体 */ export interface Customer { customerId?: number customerCode?: string customerName: string shortName?: string tradeType: string creditCode?: string parentId?: number | null parentCustomerCode?: string parentCustomerName?: string responsibleUserId?: number | null responsibleUserName?: string customerStatus?: string creationDate?: string createdBy?: string lastUpdateDate?: string lastUpdatedBy?: string versionNum?: number addressList?: CustomerAddress[] } /** 客户表单(新增/编辑) */ export interface CustomerForm { customerId?: number | null customerCode?: string customerName: string shortName?: string tradeType: string creditCode?: string parentId?: number | null responsibleUserId?: number | null customerStatus?: string versionNum?: number } /** 收货地址 */ export interface CustomerAddress { addressId?: number customerId?: number addressDetail: string isDefault: number // 0 | 1 creationDate?: string } /** 地址表单 */ export interface AddressForm { addressId?: number | null customerId?: number | null addressDetail: string isDefault: number } /** 贸易类型枚举 */ export const TRADE_TYPE_OPTIONS = [ { label: '内销', value: 'DOMESTIC' }, { label: '外销', value: 'EXPORT' }, ] as const /** 客户状态枚举 */ export const CUSTOMER_STATUS_OPTIONS = [ { label: '正常', value: '正常' }, { label: '停用', value: '停用' }, ] as const /** 角色类型 */ export type UserRole = 'sales' | 'manager' | 'admin' /** 搜索表单 */ export interface SearchForm { customerCode?: string customerName?: string tradeType?: string customerStatus?: string }