declare namespace PreEventAPI {
  interface PreprocessingReq {
    page: number;
    count: number;
    pretreatmentType: string | number;
    handleState: string | number;
  }
  interface List<T> {
    total: number;
    loading?: boolean;
    items: T[];
    hasNext: boolean;
    page: number;
  }

  interface PreprocessingEvent {
    disposePicPath: string;
    eventId: string;
    sourceSystem: string;
    standardEventContent: string;
    standardEventTitle: string;
    timeDescription: string;
    pretreatmentTypes: {
      label: string;
      type: string;
      typeValue: string;
      value: string;
    }[];
  }

  interface EventBoundaryInfo {
    editEventInfo: {
      adjustRegion: string;
      categoryHandleState: string;
      collectionMode: string;
      collectionModeText: string;
      disposeDeadline: string;
      disposePicPaths: string[];
      extendAddress: string;
      extendClass: string;
      id: string;
      informantName: string;
      lat: string;
      limitTimeText: string;
      lon: string;
      mainEventFlag: string;
      originalRegion: string;
      reportDuration: string;
      reportTime: string;
      standardEventContent: string;
      standardEventNumber: string;
      standardEventTitle: string;
    };
  }

  interface EventDetailDto {
    collectionMode: string;
    disposePicPath: string[];
    thematicArea: string[];
    updateByName: string;
    updateTime: string;
    categoryHandleState: CategoryHandleStateDto;
    classifyLabel: string[];
    lat: number;
    lon: number;
    extendClass: string;
    collectionModeText: string;
    disposeDeadline: string;
    extendAddress: string;
    id: string;
    informantName: string;
    limitTimeText: string;
    informantPhone: string;
    reportDuration: string;
    reportTime: string;
    standardEventContent: string;
    standardEventTitle: string;
    originalRegion: string;
    adjustRegion: string;
    adjustBoundaryFlag: string; //调整标志  0未调整 1已调整
    aiClassify: any[];
    splitEvents?: SplitEventsDto[];
  }

  //获取区域树
  interface EventTreeDto {
    key?: string;
    value?: string;
    label: string;
    title: string;
    sort: number;
    type: string;
    children?: EventTreeDto[];
  }

  //修改交界事件信息
  interface AdjustBoundaryDto {
    id: string;
    adjustBoundaryFlag: 0 | 1; //调整标志  0未调整 1已调整
    cityCode?: string;
    cityName?: string;
    districtCode?: string;
    districtName?: string;
    streetCode?: string;
    streetName?: string;
    communityCode?: string;
    communityName?: string;
  }

  //事件合并
  interface UpdateEventMergeDto {
    mainEventId: string; //主事件ID
    allSubEventIds: string; //所有子事件ID，不包含主事件
    mergeFlag: '2' | '3' | number; //是否合并 2合并 3 不合并
  }

  //不明部件
  interface UpdateUnComponentEventDto {
    id: string; //事件ID
    ownershipName?: string | undefined; //权属代码
    ownershipCode?: string | undefined; //权属名
    operation: 0 | 1 | number; // 0 权属  1不明部件 2派遣核实
  }

  interface EventCompletionDetailDto {
    labelAttribute?: Options[];
    editEventInfo: EventDetailDto;
  }

  interface CategoryDto {
    id?: string;
    componentCode: string;
    componentName: string;
    mainTypeCode: string;
    mainTypeName: string;
    subTypeCode: string;
    subTypeName: string;
    thirdTypeCode: string;
    thirdTypeName: string;
    newInstCondCode: string;
    newInstCondName: string;
  }

  interface UpdateEventDetailInfoDto extends CategoryDto {
    id: string;
    cityCode: string;
    cityName: string;
    districtCode: string;
    districtName: string;
    streetCode: string;
    streetName: string;
    communityCode: string;
    communityName: string;
    lon: string;
    lat: string;
    coordinateType: string; //坐标类型
    address: string;
    eventSpecialAreaLabel: string; //专题区域标签
    gridName: string; //专题网格
    updatePretreatmentType: string;
  }

  interface updateAiEventReq extends CategoryDto {
    updatePretreatmentType: string; //预处理类型
    operation: 1 | 2 | 3; //操作 1 AI识别正确 2A识别错误，去更改类别 3AI识别错误，作废
    cancelReason?: string;
  }

  interface ReportEventSourceInfoReq {
    standardEventTitle?: string; //标题 //极简上报的描述就传入此字段
    standardEventContent?: string; //描述
    collectionMode: '4'; //领导传入
    handlingMethod: '1'; //办理方式  1:派遣处置，2:自查自处，3:通知商户整改
    eventReportInfoExtend: {
      articleCode: string;
      sourceSystemCode: string;
      sourceSystem: string;
      newInstCondCode: string;
      newInstCondName: string;
      cityCode: string;
      cityName: string;
      districtCode: string;
      districtName: string;
      streetCode: string;
      streetName: string;
      eventIndustryCode: string; //行业code
      eventIndustryName: string; //行业name
      communityCode: string;
      communityName: string;
      lon: string; //事件经度
      lat: string; //事件纬度
      coordinateType: string; //坐标类型
      address: string;
      aiFlag: '0'; //是否ai识别分类0
      roadName: string;
    };
    beforeFilePath: string[];
    afterFilePath?: string[];
  }

  interface CountDbzdDto {
    area: BaseChartInfo[];
    overdue: OptionsDto[];
    source: BaseChartInfo[];
  }

  interface DbzdEventListDto {
    extendAddress: string;
    extendClass: string;
    handlingEffectiveness: string;
    handlingMethod: stringstring;
    id: string;
    informantId: string;
    informantName: string;
  }
}
