/* * @Author: ChenYaJin * @Date: 2023-07-03 10:55:53 * @LastEditors: wjc * @LastEditTime: 2023-12-01 09:19:37 * @Description: 通用模型 */ export type BasicResponse = { code: number message: string data: T } /** * 接口返回数据模型 */ export type ApiResponse = { data: BasicResponse } /** * table */ export type TableData = { list: Array pageSize?: number pageNum?: number pages?: number total?: number } export type Page = { pageSize?: number pageNum?: number isPage?: boolean } /** * dialog数据 */ export type ModalData = { isShow?: boolean type?: string loading?: boolean row?: T title?: string } /** * 枚举 */ export interface IOption { id?: string code?: string value?: string name?: string label?: string type?: string leaf?: boolean children?: IOption[] } /** * 表单验证 */ export type IFormValidateCallback = { (message?: string | Error | undefined): Error | void } export type IFormValidator = ( rule: { field: string }, value: string, callback: IFormValidateCallback ) => void export type FormRuleItemParams = { required?: boolean message?: string validator?: IFormValidator trigger?: string } export interface AnyObject { [key: string]: T } /** * 审核结果信息 */ export interface IAuditStatusInfo { content?: string reviewBy?: string auditStatus?: string reject?: string score?: number reviewAt?: string deadlineAt?: string }