|
@@ -1,4 +1,4 @@
|
|
|
-import React, { useEffect, useMemo, useState } from 'react'
|
|
|
+import React, { useEffect, useMemo, useRef, useState } from 'react'
|
|
|
import styles from './index.module.scss'
|
|
|
import Y1cathet from '@/pages/Y_goodsDetails/Y1cathet'
|
|
|
import { selectObj } from '@/utils/select'
|
|
@@ -10,6 +10,7 @@ import { RootState } from '@/store'
|
|
|
import ImageLazy from '@/components/ImageLazy'
|
|
|
import { statusCollectObj, statusStorageObj } from '@/utils/tableData'
|
|
|
import { FourTableType } from '@/pages/B_enterTibet/B1collect/type'
|
|
|
+import { baseURL } from '@/utils/http'
|
|
|
|
|
|
type Props = {
|
|
|
pageNum: number
|
|
@@ -133,9 +134,37 @@ function A32table({ pageNum, pageSize, pageChangeFu, advanced }: Props) {
|
|
|
}
|
|
|
}, [advanced])
|
|
|
|
|
|
+ // 空数据列表会闪一下的问题
|
|
|
+ const timerrRef = useRef(-1)
|
|
|
+ const [isLoding, setIsLoding] = useState(false)
|
|
|
+ useEffect(() => {
|
|
|
+ timerrRef.current = window.setTimeout(() => {
|
|
|
+ setIsLoding(true)
|
|
|
+ }, 500)
|
|
|
+ return () => {
|
|
|
+ clearTimeout(timerrRef.current)
|
|
|
+ }
|
|
|
+ }, [])
|
|
|
+
|
|
|
return (
|
|
|
<div className={styles.A32table}>
|
|
|
<Table
|
|
|
+ locale={{
|
|
|
+ emptyText: (
|
|
|
+ <div
|
|
|
+ className='NODATA'
|
|
|
+ style={{ height: advanced ? 550 : 605, opacity: isLoding ? '1' : '0' }}
|
|
|
+ >
|
|
|
+ <img src={baseURL + `/baseData/staImg/build.png`} alt='' />
|
|
|
+ <p>暂无相关搜索结果,请更换关键字搜索</p>
|
|
|
+ <div>
|
|
|
+ <p>应用归属单位:义乌市博物馆</p>
|
|
|
+ <p>应用管理员:李亮</p>
|
|
|
+ <p>联系方式:18767178372</p>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ )
|
|
|
+ }}
|
|
|
scroll={{ y: advanced ? 550 : 605, x: 'max-content' }}
|
|
|
dataSource={tableInfo.list}
|
|
|
columns={columns}
|