|  | @@ -1,4 +1,5 @@
 | 
	
		
			
				|  |  | -import { ZhSubmitButton, ZhUploadButton } from '@/components/Button'
 | 
	
		
			
				|  |  | +import AuditContent from '@/components/AuditContent'
 | 
	
		
			
				|  |  | +import { ZhAuditBackButton, ZhCloseButton, ZhSubmitButton, ZhUploadButton } from '@/components/Button'
 | 
	
		
			
				|  |  |  import DatePicker from '@/components/DatePicker'
 | 
	
		
			
				|  |  |  import Header from '@/components/Header'
 | 
	
		
			
				|  |  |  import Slot from '@/components/Header/slot'
 | 
	
	
		
			
				|  | @@ -6,7 +7,8 @@ import OssUploadModal from '@/components/OssUpload'
 | 
	
		
			
				|  |  |  import SvgIcon from '@/components/SvgIcon'
 | 
	
		
			
				|  |  |  import { userStore } from '@/store/mobx'
 | 
	
		
			
				|  |  |  import { iFile } from '@/types/file'
 | 
	
		
			
				|  |  | -import { iAuditHistory, iLatestAuditorState, iRectifiedState } from '@/types/safe'
 | 
	
		
			
				|  |  | +import { iAuditHistoryState, iAuditor, iLatestAuditorState, iRectifiedState } from '@/types/safe'
 | 
	
		
			
				|  |  | +import { iUserInfo } from '@/types/setting'
 | 
	
		
			
				|  |  |  import { apiDelFile, apiGetFileList, apiSaveFileInfo } from '@/utils/common/api'
 | 
	
		
			
				|  |  |  import consts from '@/utils/consts'
 | 
	
		
			
				|  |  |  import { dayjsFormat } from '@/utils/util'
 | 
	
	
		
			
				|  | @@ -20,7 +22,7 @@ import styles from './index.module.scss'
 | 
	
		
			
				|  |  |  const { TextArea } = Input
 | 
	
		
			
				|  |  |  interface iDetailState {
 | 
	
		
			
				|  |  |    auditName: string
 | 
	
		
			
				|  |  | -  auditors: any[]
 | 
	
		
			
				|  |  | +  auditors: iAuditor[]
 | 
	
		
			
				|  |  |    bidsectionId: string
 | 
	
		
			
				|  |  |    code: string
 | 
	
		
			
				|  |  |    createTime: string | undefined
 | 
	
	
		
			
				|  | @@ -32,12 +34,12 @@ interface iDetailState {
 | 
	
		
			
				|  |  |    position: string
 | 
	
		
			
				|  |  |    status: number
 | 
	
		
			
				|  |  |    checkOrder: iModifiedOrder
 | 
	
		
			
				|  |  | -  auditHistory: iAuditHistory
 | 
	
		
			
				|  |  | +  auditHistory: iAuditHistoryState[][]
 | 
	
		
			
				|  |  |    rectifiedInfo: iRectifiedState[]
 | 
	
		
			
				|  |  |    latestAuditor: iLatestAuditorState
 | 
	
		
			
				|  |  |  }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -interface iModifiedOrder{
 | 
	
		
			
				|  |  | +interface iModifiedOrder {
 | 
	
		
			
				|  |  |    name: string
 | 
	
		
			
				|  |  |    end_time: string | undefined
 | 
	
		
			
				|  |  |    opinion: string
 | 
	
	
		
			
				|  | @@ -47,43 +49,41 @@ interface iFileState {
 | 
	
		
			
				|  |  |    fileList: any[]
 | 
	
		
			
				|  |  |    total: number
 | 
	
		
			
				|  |  |  }
 | 
	
		
			
				|  |  | -const Detail:React.FC<RouteComponentProps> = (props) => {
 | 
	
		
			
				|  |  | -  const { saveId = "" } = props.location.state as any
 | 
	
		
			
				|  |  | +const Detail: React.FC<RouteComponentProps> = props => {
 | 
	
		
			
				|  |  | +  const { saveId = '' } = props.location.state as any
 | 
	
		
			
				|  |  |    const [ visible, setVisible ] = useState<boolean>(false)
 | 
	
		
			
				|  |  |    const [ detail, setDetail ] = useState<iDetailState>({
 | 
	
		
			
				|  |  | -    auditName: "",
 | 
	
		
			
				|  |  | +    auditName: '',
 | 
	
		
			
				|  |  |      auditors: [],
 | 
	
		
			
				|  |  | -    bidsectionId: "",
 | 
	
		
			
				|  |  | -    code: "",
 | 
	
		
			
				|  |  | -    createTime: "",
 | 
	
		
			
				|  |  | -    demand: "",
 | 
	
		
			
				|  |  | +    bidsectionId: '',
 | 
	
		
			
				|  |  | +    code: '',
 | 
	
		
			
				|  |  | +    createTime: '',
 | 
	
		
			
				|  |  | +    demand: '',
 | 
	
		
			
				|  |  |      file: { fileList: [], total: 0 },
 | 
	
		
			
				|  |  | -    id: "",
 | 
	
		
			
				|  |  | -    inspection: "",
 | 
	
		
			
				|  |  | -    inspectionDetail: "",
 | 
	
		
			
				|  |  | -    position: "",
 | 
	
		
			
				|  |  | +    id: '',
 | 
	
		
			
				|  |  | +    inspection: '',
 | 
	
		
			
				|  |  | +    inspectionDetail: '',
 | 
	
		
			
				|  |  | +    position: '',
 | 
	
		
			
				|  |  |      status: 0,
 | 
	
		
			
				|  |  |      checkOrder: {
 | 
	
		
			
				|  |  | -      name: "",
 | 
	
		
			
				|  |  | +      name: '',
 | 
	
		
			
				|  |  |        status: 0,
 | 
	
		
			
				|  |  | -      opinion: "",
 | 
	
		
			
				|  |  | -      end_time: ""
 | 
	
		
			
				|  |  | -    },
 | 
	
		
			
				|  |  | -    auditHistory: {
 | 
	
		
			
				|  |  | -      "1": []
 | 
	
		
			
				|  |  | +      opinion: '',
 | 
	
		
			
				|  |  | +      end_time: ''
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  | +    auditHistory: [],
 | 
	
		
			
				|  |  |      rectifiedInfo: [],
 | 
	
		
			
				|  |  |      latestAuditor: {
 | 
	
		
			
				|  |  | -      audit_id: "",
 | 
	
		
			
				|  |  | +      audit_id: '',
 | 
	
		
			
				|  |  |        status: 0,
 | 
	
		
			
				|  |  | -      progress: ""
 | 
	
		
			
				|  |  | +      progress: ''
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |    })
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |    useEffect(() => {
 | 
	
		
			
				|  |  |      initData()
 | 
	
		
			
				|  |  |    }, [ saveId ])
 | 
	
		
			
				|  |  | -  const initData = async() => {
 | 
	
		
			
				|  |  | +  const initData = async () => {
 | 
	
		
			
				|  |  |      const { code = -1, data = {}, checkOrder = {} } = await apiGetSafeDetail(saveId)
 | 
	
		
			
				|  |  |      if (code === consts.RET_CODE.SUCCESS) {
 | 
	
		
			
				|  |  |        setDetail({ ...detail, ...data, checkOrder })
 | 
	
	
		
			
				|  | @@ -92,35 +92,80 @@ const Detail:React.FC<RouteComponentProps> = (props) => {
 | 
	
		
			
				|  |  |    const onCreate = async (fileList: iFile[]) => {
 | 
	
		
			
				|  |  |      const { code = -1 } = await apiSaveFileInfo(fileList, consts.DATA_TYPE.SAFE, detail.id)
 | 
	
		
			
				|  |  |      if (code === consts.RET_CODE.SUCCESS) {
 | 
	
		
			
				|  |  | -      const newFiles = detail.file.fileList.concat(fileList.map(file => {
 | 
	
		
			
				|  |  | -        return { ...file, accountName: userStore.userInfo.name }
 | 
	
		
			
				|  |  | -      }))
 | 
	
		
			
				|  |  | +      const newFiles = detail.file.fileList.concat(
 | 
	
		
			
				|  |  | +        fileList.map(file => {
 | 
	
		
			
				|  |  | +          return { ...file, accountName: userStore.userInfo.name }
 | 
	
		
			
				|  |  | +        })
 | 
	
		
			
				|  |  | +      )
 | 
	
		
			
				|  |  |        setDetail({ ...detail, file: { ...detail.file, fileList: newFiles } })
 | 
	
		
			
				|  |  |        setVisible(false)
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |    }
 | 
	
		
			
				|  |  |    const onShow = (show: boolean) => setVisible(show)
 | 
	
		
			
				|  |  |    const fileListChange = async (pageNo: number = 1, pageSize: number = 10) => {
 | 
	
		
			
				|  |  | -    const { code = -1, data } = await apiGetFileList(consts.DATA_TYPE.SAFE,detail.id, pageNo, pageSize)
 | 
	
		
			
				|  |  | +    const { code = -1, data } = await apiGetFileList(consts.DATA_TYPE.SAFE, detail.id, pageNo, pageSize)
 | 
	
		
			
				|  |  |      if (code === consts.RET_CODE.SUCCESS) {
 | 
	
		
			
				|  |  |        setDetail({ ...detail, file: { ...detail.file, fileList: data } })
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |    }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -  const delFile = async(id: string) => {
 | 
	
		
			
				|  |  | +  const delFile = async (id: string) => {
 | 
	
		
			
				|  |  |      const { code = -1 } = await apiDelFile(id)
 | 
	
		
			
				|  |  |      if (code === consts.RET_CODE.SUCCESS) {
 | 
	
		
			
				|  |  |        const newFiles = detail.file.fileList.filter(file => file.id !== id)
 | 
	
		
			
				|  |  |        setDetail({ ...detail, file: { ...detail.file, fileList: newFiles } })
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |    }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +  const addAuditor = (type: string, user: iUserInfo) => {
 | 
	
		
			
				|  |  | +    if (type === "check") {
 | 
	
		
			
				|  |  | +      const newAuditors = detail.auditors
 | 
	
		
			
				|  |  | +      const len = detail.auditors.filter((item: iAuditor) => item.progress === "0").length
 | 
	
		
			
				|  |  | +      newAuditors.push({ audit_id: user.id, audit_order: len + 1,position: user.position, progress: "0", name: user.name,accountGroup: user.accountGroup, company: user.company, status: 0 })
 | 
	
		
			
				|  |  | +      setDetail({ ...detail, auditors: newAuditors })
 | 
	
		
			
				|  |  | +    } else {
 | 
	
		
			
				|  |  | +      const newAuditors = detail.auditors
 | 
	
		
			
				|  |  | +      const len = detail.auditors.filter((item: iAuditor) => item.progress === "2").length
 | 
	
		
			
				|  |  | +      newAuditors.push({ audit_id: user.id, audit_order: len + 1,position: user.position, progress: "2",  name: user.name, accountGroup: user.accountGroup, company: user.company, status: 0 })
 | 
	
		
			
				|  |  | +      setDetail({ ...detail, auditors: newAuditors })
 | 
	
		
			
				|  |  | +    }
 | 
	
		
			
				|  |  | +  }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +  const delAuditor = (id: string) => {
 | 
	
		
			
				|  |  | +    const newAuditors = detail.auditors.filter(item => item.audit_id !== id)
 | 
	
		
			
				|  |  | +    setDetail({ ...detail, auditors: newAuditors })
 | 
	
		
			
				|  |  | +  }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +  const renderHeaderBtn = (status: number) => {
 | 
	
		
			
				|  |  | +    if (!status) {
 | 
	
		
			
				|  |  | +      return (
 | 
	
		
			
				|  |  | +        <div className="pi-flex-row pi-align-center">
 | 
	
		
			
				|  |  | +          <ZhCloseButton size="small">删除巡检</ZhCloseButton>
 | 
	
		
			
				|  |  | +          <ZhSubmitButton size="small" className="pi-mg-left-5">提交审批</ZhSubmitButton>
 | 
	
		
			
				|  |  | +        </div>
 | 
	
		
			
				|  |  | +      )
 | 
	
		
			
				|  |  | +    } else if(status === 1) {
 | 
	
		
			
				|  |  | +      return (
 | 
	
		
			
				|  |  | +        <div className="pi-flex-row pi-align-center">
 | 
	
		
			
				|  |  | +          <Button type="primary" danger size="small">关闭</Button>
 | 
	
		
			
				|  |  | +          <ZhAuditBackButton size="small" className="pi-mg-left-5">审批退回</ZhAuditBackButton>
 | 
	
		
			
				|  |  | +          <ZhSubmitButton size="small" className="pi-mg-left-5">审批通过</ZhSubmitButton>
 | 
	
		
			
				|  |  | +        </div>
 | 
	
		
			
				|  |  | +      )
 | 
	
		
			
				|  |  | +    } else {
 | 
	
		
			
				|  |  | +      return (
 | 
	
		
			
				|  |  | +        <div className="pi-flex-row pi-align-center">
 | 
	
		
			
				|  |  | +          <ZhAuditBackButton size="small">审批退回</ZhAuditBackButton>
 | 
	
		
			
				|  |  | +          <ZhSubmitButton size="small" className="pi-mg-left-5">整改</ZhSubmitButton>
 | 
	
		
			
				|  |  | +        </div>
 | 
	
		
			
				|  |  | +      )
 | 
	
		
			
				|  |  | +    }
 | 
	
		
			
				|  |  | +  }
 | 
	
		
			
				|  |  |    return (
 | 
	
		
			
				|  |  |      <div className="wrap-contaniner">
 | 
	
		
			
				|  |  |        <Header title="安全巡检">
 | 
	
		
			
				|  |  |          <Slot position="right">
 | 
	
		
			
				|  |  | -          <div>
 | 
	
		
			
				|  |  | -            <ZhSubmitButton size="small">提交审批</ZhSubmitButton>
 | 
	
		
			
				|  |  | -          </div>
 | 
	
		
			
				|  |  | +          {renderHeaderBtn(detail.status)}
 | 
	
		
			
				|  |  |          </Slot>
 | 
	
		
			
				|  |  |        </Header>
 | 
	
		
			
				|  |  |        <div className={styles.detailContainer}>
 | 
	
	
		
			
				|  | @@ -129,169 +174,151 @@ const Detail:React.FC<RouteComponentProps> = (props) => {
 | 
	
		
			
				|  |  |            <table className="pi-table pi-bordered">
 | 
	
		
			
				|  |  |              <thead>
 | 
	
		
			
				|  |  |                <tr>
 | 
	
		
			
				|  |  | -                <th colSpan={2} className="pi-text-center">安全巡检单</th>
 | 
	
		
			
				|  |  | +                <th colSpan={2} className="pi-text-center">
 | 
	
		
			
				|  |  | +                  安全巡检单
 | 
	
		
			
				|  |  | +                </th>
 | 
	
		
			
				|  |  |                </tr>
 | 
	
		
			
				|  |  |              </thead>
 | 
	
		
			
				|  |  |              <tbody>
 | 
	
		
			
				|  |  | -              <tr><th style={{ width: "150px" }}>检查项目</th><td><TextArea value={detail.inspection}></TextArea></td></tr>
 | 
	
		
			
				|  |  | -              <tr><th style={{ width: "150px" }}>现场检查情况</th><td><TextArea value={detail.inspectionDetail}></TextArea></td></tr>
 | 
	
		
			
				|  |  | -              <tr><th style={{ width: "150px" }}>处理要求及措施</th><td><TextArea value={detail.demand}></TextArea></td></tr>
 | 
	
		
			
				|  |  |                <tr>
 | 
	
		
			
				|  |  | -                <th style={{ width: "150px" }}>检查日期</th>
 | 
	
		
			
				|  |  | -                <td><DatePicker size="small" locale={locale} allowClear={false} value={dayjs(detail.createTime)} onChange={(value) => setDetail({ ...detail, createTime: value?.format() })}></DatePicker></td>
 | 
	
		
			
				|  |  | +                <th style={{ width: '150px' }}>检查项目</th>
 | 
	
		
			
				|  |  | +                <td>
 | 
	
		
			
				|  |  | +                  <TextArea value={detail.inspection}></TextArea>
 | 
	
		
			
				|  |  | +                </td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <th style={{ width: '150px' }}>现场检查情况</th>
 | 
	
		
			
				|  |  | +                <td>
 | 
	
		
			
				|  |  | +                  <TextArea value={detail.inspectionDetail}></TextArea>
 | 
	
		
			
				|  |  | +                </td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <th style={{ width: '150px' }}>处理要求及措施</th>
 | 
	
		
			
				|  |  | +                <td>
 | 
	
		
			
				|  |  | +                  <TextArea value={detail.demand}></TextArea>
 | 
	
		
			
				|  |  | +                </td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <th style={{ width: '150px' }}>检查日期</th>
 | 
	
		
			
				|  |  | +                <td>
 | 
	
		
			
				|  |  | +                  <DatePicker
 | 
	
		
			
				|  |  | +                    size="small"
 | 
	
		
			
				|  |  | +                    locale={locale}
 | 
	
		
			
				|  |  | +                    allowClear={false}
 | 
	
		
			
				|  |  | +                    value={dayjs(detail.createTime)}
 | 
	
		
			
				|  |  | +                    onChange={value => setDetail({ ...detail, createTime: value?.format() })}></DatePicker>
 | 
	
		
			
				|  |  | +                </td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <th style={{ width: '150px' }}>质检员</th>
 | 
	
		
			
				|  |  | +                <td>{detail.auditName}</td>
 | 
	
		
			
				|  |  |                </tr>
 | 
	
		
			
				|  |  | -              <tr><th style={{ width: "150px" }}>质检员</th><td>{detail.auditName}</td></tr>
 | 
	
		
			
				|  |  |              </tbody>
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  |            </table>
 | 
	
		
			
				|  |  | -          <table className="pi-table pi-bordered">
 | 
	
		
			
				|  |  | +          {
 | 
	
		
			
				|  |  | +            detail.rectifiedInfo.length ?
 | 
	
		
			
				|  |  | +            <table className="pi-table pi-bordered">
 | 
	
		
			
				|  |  |              <thead>
 | 
	
		
			
				|  |  |                <tr>
 | 
	
		
			
				|  |  | -                <th colSpan={2} className="pi-text-center">整改单</th>
 | 
	
		
			
				|  |  | +                <th colSpan={2} className="pi-text-center">
 | 
	
		
			
				|  |  | +                  整改单
 | 
	
		
			
				|  |  | +                </th>
 | 
	
		
			
				|  |  |                </tr>
 | 
	
		
			
				|  |  |              </thead>
 | 
	
		
			
				|  |  |              <tbody>
 | 
	
		
			
				|  |  | -              <tr><th style={{ width: "150px" }}>整改情况</th><td><TextArea value={detail.checkOrder.opinion}></TextArea></td></tr>
 | 
	
		
			
				|  |  | -              <tr><th style={{ width: "150px" }}>整改日期</th><td><DatePicker size="small" locale={locale} allowClear={false} value={dayjs(detail.checkOrder.end_time)} onChange={(value) => setDetail({ ...detail, checkOrder: { ...detail.checkOrder, end_time: value?.format() } })}></DatePicker></td></tr>
 | 
	
		
			
				|  |  | -              <tr><th style={{ width: "150px" }}>整改人</th><td>王五</td></tr>
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <th style={{ width: '150px' }}>整改情况</th>
 | 
	
		
			
				|  |  | +                <td>
 | 
	
		
			
				|  |  | +                  <TextArea value={detail.checkOrder.opinion}></TextArea>
 | 
	
		
			
				|  |  | +                </td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <th style={{ width: '150px' }}>整改日期</th>
 | 
	
		
			
				|  |  | +                <td>
 | 
	
		
			
				|  |  | +                  <DatePicker
 | 
	
		
			
				|  |  | +                    size="small"
 | 
	
		
			
				|  |  | +                    locale={locale}
 | 
	
		
			
				|  |  | +                    allowClear={false}
 | 
	
		
			
				|  |  | +                    value={dayjs(detail.checkOrder.end_time)}
 | 
	
		
			
				|  |  | +                    onChange={value => setDetail({ ...detail, checkOrder: { ...detail.checkOrder, end_time: value?.format() } })}></DatePicker>
 | 
	
		
			
				|  |  | +                </td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <th style={{ width: '150px' }}>整改人</th>
 | 
	
		
			
				|  |  | +                <td>王五</td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  |              </tbody>
 | 
	
		
			
				|  |  |            </table>
 | 
	
		
			
				|  |  | +          : null
 | 
	
		
			
				|  |  | +          }
 | 
	
		
			
				|  |  |            <table className="pi-table pi-bordered mt-3">
 | 
	
		
			
				|  |  |              <thead>
 | 
	
		
			
				|  |  |                <tr>
 | 
	
		
			
				|  |  |                  <th></th>
 | 
	
		
			
				|  |  |                  <th className="pi-text-center">附件</th>
 | 
	
		
			
				|  |  |                  <th className="pi-text-center">上传者</th>
 | 
	
		
			
				|  |  | -                <th className="pi-text-center" style={{ width: 200 }}>上传时间</th>
 | 
	
		
			
				|  |  | +                <th className="pi-text-center" style={{ width: 200 }}>
 | 
	
		
			
				|  |  | +                  上传时间
 | 
	
		
			
				|  |  | +                </th>
 | 
	
		
			
				|  |  |                  <th className="pi-text-center">操作</th>
 | 
	
		
			
				|  |  |                </tr>
 | 
	
		
			
				|  |  |              </thead>
 | 
	
		
			
				|  |  |              <tbody>
 | 
	
		
			
				|  |  | -              <tr><td colSpan={5}><ZhUploadButton size="small" icon={<SvgIcon type="xxh-cloud-upload"/>} onClick={() => setVisible(true)}>上传附件</ZhUploadButton></td></tr>
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <td colSpan={5}>
 | 
	
		
			
				|  |  | +                  <ZhUploadButton size="small" icon={<SvgIcon type="xxh-cloud-upload" />} onClick={() => setVisible(true)}>
 | 
	
		
			
				|  |  | +                    上传附件
 | 
	
		
			
				|  |  | +                  </ZhUploadButton>
 | 
	
		
			
				|  |  | +                </td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -              {
 | 
	
		
			
				|  |  | -                detail.file.fileList?.map((file, idx) => {
 | 
	
		
			
				|  |  | -                  return (
 | 
	
		
			
				|  |  | -                    <tr key={idx}>
 | 
	
		
			
				|  |  | -                      <td className="pi-width-70">{idx+1}</td>
 | 
	
		
			
				|  |  | -                      <td style={{ width: 383, maxWidth: 383, overflow: 'hidden', whiteSpace: 'nowrap',textOverflow:'ellipsis' }}>
 | 
	
		
			
				|  |  | -                        <a href={consts.OSS_PATH.REVIEW + file.filepath} target="_blank" rel="noopener noreferrer">{file.filename}</a>
 | 
	
		
			
				|  |  | -                      </td>
 | 
	
		
			
				|  |  | -                      <td className="pi-text-center">{file.accountName}</td><td className="pi-text-center">{dayjsFormat(file.createTime)}</td>
 | 
	
		
			
				|  |  | -                      <td className="pi-text-center pi-width-90">
 | 
	
		
			
				|  |  | -                        <Tooltip title="移除">
 | 
	
		
			
				|  |  | -                          <Button size="small" type="text" icon={<SvgIcon type="xxh-times-circle1"/>} style={{ color: "#df3f45" }} onClick={() => delFile(file.id)}></Button>
 | 
	
		
			
				|  |  | -                        </Tooltip>
 | 
	
		
			
				|  |  | -                      </td>
 | 
	
		
			
				|  |  | -                    </tr>
 | 
	
		
			
				|  |  | -                  )
 | 
	
		
			
				|  |  | -                })
 | 
	
		
			
				|  |  | -              }
 | 
	
		
			
				|  |  | -              <tr><td colSpan={5} className="pi-text-right">
 | 
	
		
			
				|  |  | -              {
 | 
	
		
			
				|  |  | -                detail.file.total ?
 | 
	
		
			
				|  |  | -                <Pagination
 | 
	
		
			
				|  |  | -                defaultCurrent={1}
 | 
	
		
			
				|  |  | -                size="small"
 | 
	
		
			
				|  |  | -                pageSize={consts.PAGE_SIZE}
 | 
	
		
			
				|  |  | -                hideOnSinglePage={true}
 | 
	
		
			
				|  |  | -                total={detail.file.total}
 | 
	
		
			
				|  |  | -                onChange={(page, pageSize) => fileListChange(page, pageSize)}
 | 
	
		
			
				|  |  | -                >
 | 
	
		
			
				|  |  | -              </Pagination>
 | 
	
		
			
				|  |  | -              : ''
 | 
	
		
			
				|  |  | -              }
 | 
	
		
			
				|  |  | -              </td></tr>
 | 
	
		
			
				|  |  | +              {detail.file.fileList?.map((file, idx) => {
 | 
	
		
			
				|  |  | +                return (
 | 
	
		
			
				|  |  | +                  <tr key={idx}>
 | 
	
		
			
				|  |  | +                    <td className="pi-width-70">{idx + 1}</td>
 | 
	
		
			
				|  |  | +                    <td style={{ width: 383, maxWidth: 383, overflow: 'hidden', whiteSpace: 'nowrap', textOverflow: 'ellipsis' }}>
 | 
	
		
			
				|  |  | +                      <a href={consts.OSS_PATH.REVIEW + file.filepath} target="_blank" rel="noopener noreferrer">
 | 
	
		
			
				|  |  | +                        {file.filename}
 | 
	
		
			
				|  |  | +                      </a>
 | 
	
		
			
				|  |  | +                    </td>
 | 
	
		
			
				|  |  | +                    <td className="pi-text-center">{file.accountName}</td>
 | 
	
		
			
				|  |  | +                    <td className="pi-text-center">{dayjsFormat(file.createTime)}</td>
 | 
	
		
			
				|  |  | +                    <td className="pi-text-center pi-width-90">
 | 
	
		
			
				|  |  | +                      <Tooltip title="移除">
 | 
	
		
			
				|  |  | +                        <Button size="small" type="text" icon={<SvgIcon type="xxh-times-circle1" />} style={{ color: '#df3f45' }} onClick={() => delFile(file.id)}></Button>
 | 
	
		
			
				|  |  | +                      </Tooltip>
 | 
	
		
			
				|  |  | +                    </td>
 | 
	
		
			
				|  |  | +                  </tr>
 | 
	
		
			
				|  |  | +                )
 | 
	
		
			
				|  |  | +              })}
 | 
	
		
			
				|  |  | +              <tr>
 | 
	
		
			
				|  |  | +                <td colSpan={5} className="pi-text-right">
 | 
	
		
			
				|  |  | +                  {detail.file.total ? (
 | 
	
		
			
				|  |  | +                    <Pagination
 | 
	
		
			
				|  |  | +                      defaultCurrent={1}
 | 
	
		
			
				|  |  | +                      size="small"
 | 
	
		
			
				|  |  | +                      pageSize={consts.PAGE_SIZE}
 | 
	
		
			
				|  |  | +                      hideOnSinglePage={true}
 | 
	
		
			
				|  |  | +                      total={detail.file.total}
 | 
	
		
			
				|  |  | +                      onChange={(page, pageSize) => fileListChange(page, pageSize)}></Pagination>
 | 
	
		
			
				|  |  | +                  ) : (
 | 
	
		
			
				|  |  | +                    ''
 | 
	
		
			
				|  |  | +                  )}
 | 
	
		
			
				|  |  | +                </td>
 | 
	
		
			
				|  |  | +              </tr>
 | 
	
		
			
				|  |  |              </tbody>
 | 
	
		
			
				|  |  |            </table>
 | 
	
		
			
				|  |  | -          <table className="table table-bordered mt-3">
 | 
	
		
			
				|  |  | -                  <thead>
 | 
	
		
			
				|  |  | -                    <tr>
 | 
	
		
			
				|  |  | -                      <th colSpan={2} className="text-center">审批流程</th>
 | 
	
		
			
				|  |  | -                    </tr>
 | 
	
		
			
				|  |  | -                  </thead>
 | 
	
		
			
				|  |  | -                  <tbody>
 | 
	
		
			
				|  |  | -                    <tr>
 | 
	
		
			
				|  |  | -                      <td width="30%">
 | 
	
		
			
				|  |  | -                        <table className="table table-bordered">
 | 
	
		
			
				|  |  | -                              <tbody><tr><td className="text-center">检查人</td><td><i className="fas fa fa-play-circle fa-rotate-90"></i> 布尔 <small className="text-muted">职称</small></td></tr>
 | 
	
		
			
				|  |  | -                              <tr><td rowSpan={2} className="text-center">审批</td><td><i className="fas fa-chevron-circle-down"></i> 张三  <small className="text-muted">职称</small></td></tr>
 | 
	
		
			
				|  |  | -                              <tr><td><i className="fas fa-chevron-circle-down"></i> 李四  <small className="text-muted">职称</small></td></tr>
 | 
	
		
			
				|  |  | -                              <tr><td className="text-center">整改</td><td><i className="fas fa-chevron-circle-down"></i> 由 张三 指派</td></tr>
 | 
	
		
			
				|  |  | -                              <tr><td className="text-center">复查</td><td><i className="fas fa fa-stop-circle"></i> 李四 <small className="text-muted">职称</small></td></tr>
 | 
	
		
			
				|  |  | -                            </tbody></table>
 | 
	
		
			
				|  |  | -                      </td>
 | 
	
		
			
				|  |  | -                      <td width="70%">
 | 
	
		
			
				|  |  | -                        <div className="dropdown text-right">
 | 
	
		
			
				|  |  | -                          <button className="btn btn-outline-primary btn-sm dropdown-toggle" type="button" id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
 | 
	
		
			
				|  |  | -                            添加审批流程
 | 
	
		
			
				|  |  | -                          </button>
 | 
	
		
			
				|  |  | -                        </div>
 | 
	
		
			
				|  |  | -                        <div className="card mt-1 mb-3">
 | 
	
		
			
				|  |  | -                          <div className="card-header">
 | 
	
		
			
				|  |  | -                            审批流程
 | 
	
		
			
				|  |  | -                          </div>
 | 
	
		
			
				|  |  | -                          <ul className="list-group list-group-flush">
 | 
	
		
			
				|  |  | -                            <li className="list-group-item d-flex">
 | 
	
		
			
				|  |  | -                              <div>
 | 
	
		
			
				|  |  | -                                <p className="m-0 ">1 张三  <small className="text-muted">监理</small></p>
 | 
	
		
			
				|  |  | -                                <p className="m-0 ml-2 d-inline"><small className="text-muted">XXX单位</small></p>
 | 
	
		
			
				|  |  | -                              </div>
 | 
	
		
			
				|  |  | -                              <a href="" className="text-danger ml-auto">移除</a>
 | 
	
		
			
				|  |  | -                            </li>
 | 
	
		
			
				|  |  | -                            <li className="list-group-item d-flex">
 | 
	
		
			
				|  |  | -                              <div>
 | 
	
		
			
				|  |  | -                                <p className="m-0 ">2 李四  <small className="text-muted">监理</small></p>
 | 
	
		
			
				|  |  | -                                <p className="m-0 ml-2 d-inline"><small className="text-muted">XXX单位</small></p>
 | 
	
		
			
				|  |  | -                              </div>
 | 
	
		
			
				|  |  | -                              <a href="" className="text-danger ml-auto">移除</a>
 | 
	
		
			
				|  |  | -                            </li>
 | 
	
		
			
				|  |  | -                          </ul>
 | 
	
		
			
				|  |  | -                        </div>
 | 
	
		
			
				|  |  | -                        <div className="card mt-1 mb-3">
 | 
	
		
			
				|  |  | -                          <div className="card-header">
 | 
	
		
			
				|  |  | -                            整改流程
 | 
	
		
			
				|  |  | -                          </div>
 | 
	
		
			
				|  |  | -                          <ul className="list-group list-group-flush">
 | 
	
		
			
				|  |  | -                            <li className="list-group-item d-flex">
 | 
	
		
			
				|  |  | -                              <div>
 | 
	
		
			
				|  |  | -                                整改人由最后一位审批人指派
 | 
	
		
			
				|  |  | -                              </div>
 | 
	
		
			
				|  |  | -                            </li>
 | 
	
		
			
				|  |  | -                          </ul>
 | 
	
		
			
				|  |  | -                        </div>
 | 
	
		
			
				|  |  | -                        <div className="dropdown text-right">
 | 
	
		
			
				|  |  | -                          <button className="btn btn-outline-primary btn-sm dropdown-toggle" type="button" id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
 | 
	
		
			
				|  |  | -                            添加复查流程
 | 
	
		
			
				|  |  | -                          </button>
 | 
	
		
			
				|  |  | -                        </div>
 | 
	
		
			
				|  |  | -                        <div className="card mt-1">
 | 
	
		
			
				|  |  | -                          <div className="card-header">
 | 
	
		
			
				|  |  | -                            复查流程
 | 
	
		
			
				|  |  | -                          </div>
 | 
	
		
			
				|  |  | -                          <ul className="list-group list-group-flush">
 | 
	
		
			
				|  |  | -                            <li className="list-group-item d-flex">
 | 
	
		
			
				|  |  | -                              <div>
 | 
	
		
			
				|  |  | -                                <p className="m-0 ">1 李四  <small className="text-muted">监理</small></p>
 | 
	
		
			
				|  |  | -                                <p className="m-0 ml-2 d-inline"><small className="text-muted">XXX单位</small></p>
 | 
	
		
			
				|  |  | -                              </div>
 | 
	
		
			
				|  |  | -                              <a href="" className="text-danger ml-auto">移除</a>
 | 
	
		
			
				|  |  | -                            </li>
 | 
	
		
			
				|  |  | -                          </ul>
 | 
	
		
			
				|  |  | -                        </div>
 | 
	
		
			
				|  |  | -                      </td>
 | 
	
		
			
				|  |  | -                    </tr>
 | 
	
		
			
				|  |  | -                  </tbody>
 | 
	
		
			
				|  |  | -                </table>
 | 
	
		
			
				|  |  | +          <AuditContent
 | 
	
		
			
				|  |  | +            auditors={detail.auditors}
 | 
	
		
			
				|  |  | +            onSelect={addAuditor}
 | 
	
		
			
				|  |  | +            onDelete={delAuditor}
 | 
	
		
			
				|  |  | +            latest={detail.latestAuditor}
 | 
	
		
			
				|  |  | +            auditHistory={detail.auditHistory}
 | 
	
		
			
				|  |  | +            status={detail.status}
 | 
	
		
			
				|  |  | +            ></AuditContent>
 | 
	
		
			
				|  |  |          </div>
 | 
	
		
			
				|  |  |        </div>
 | 
	
		
			
				|  |  | -      <OssUploadModal
 | 
	
		
			
				|  |  | -        visible={visible}
 | 
	
		
			
				|  |  | -        onCancel={() => setVisible(false)}
 | 
	
		
			
				|  |  | -        onCreate={onCreate}
 | 
	
		
			
				|  |  | -        onShow={onShow}
 | 
	
		
			
				|  |  | -        >
 | 
	
		
			
				|  |  | -      </OssUploadModal>
 | 
	
		
			
				|  |  | +      <OssUploadModal visible={visible} onCancel={() => setVisible(false)} onCreate={onCreate} onShow={onShow}></OssUploadModal>
 | 
	
		
			
				|  |  |      </div>
 | 
	
		
			
				|  |  |    )
 | 
	
		
			
				|  |  |  }
 |