Skip to content

通用查询协议

所有 *_list 方法接受统一的 query 参数:

typescript
interface QueryParams {
  currentPage?: number;
  pageSize?: number;
  search?: SearchCondition[];
  sort?: SortCondition | SortCondition[];
  columns?: string[];
  returnList?: boolean;
}

interface SearchCondition {
  prop: string;
  value: any;
  method?: 'whereEq' | 'whereIn' | 'whereLike' | 'whereNull' | 'whereMonth' | 'whereDateRange';
}