import request from '@/utils/request'


enum API {
  SAVE_SELF_REPORT = '/owSelfReporting/save',
}
export interface SelfReportResponseData{
  contactInformation:string,
  contacts:string,
  enterpriseName:string,
  unifiedSocialCreditCode:string,
  files:any
}
export interface SelfReportResponse extends AxiosResponse{
  data: SelfReportResponseData
}

export const saveSelfReport = (selfReportData:SelfReportResponseData)=>{
  const {contactInformation,contacts,enterpriseName,unifiedSocialCreditCode,files} = selfReportData;
  return request.post<any,SelfReportResponse>(API.SAVE_SELF_REPORT,{
    contactInformation,
    contacts,
    enterpriseName,
    unifiedSocialCreditCode,
    files
  })
}

//删除图片
export const delImgById = (id:number) => {
  return request.get<any,any>('/commonFile/deleteFileById',{
    params:{
      id
    }
  });
}