import { DefaultOptionType } from 'rc-select/es/Select';

export interface IPropsType {
  userList: IUserType[];
  loading: boolean;
  dispatch: (args: { type: string; payload: object }) => {};
}

export interface IMandateChildType {
  Content: string;
  CreateTime: string;
  ExtendId: number;
  Id: number;
  MandateClass: number;
  MandateId: number;
  ProjectId: number;
  Status: number;
  Title: string;
}

export interface IWorkOrderType {
  ActualDoneTime: string;
  CreateTime: string;
  Detail: string;
  Id: number;
  Note: string;
  PlanDoneTime: string;
  RecordType: number | DefaultOptionType;
  Responsible: number | IUserType;
  Status: number | DefaultOptionType;
}

export interface IMandateDetailType {
  Id: number;
  ProjectId: number;
  MandateType: number | DefaultOptionType;
  MandateClass: number | DefaultOptionType;
  ResponsiblePeople: number | IUserType;
  Detail: string;
  MandateChild: IMandateChildType[];
  Records: IWorkOrderType[];
  Summary: string;
  CreateTime: string;
  Status: number | DefaultOptionType;
  Note: string;
  OperationLog: string;
  OperationPeople: number;
  ExtendId: number;
  img?: string;
  Files?: any[];
}

export interface IUserType {
  CName: string;
  ID: number;
  RoleID: string;
  RoleName: string;
  UserName: string;
}

export interface ITopFilter {
  key: string;
  placeholder: string;
  options: { label: string | number; value: any }[];
}
