|
@ -14,9 +14,8 @@ const Record = () => { |
|
|
|
|
|
|
|
|
const { token } = store.state; |
|
|
const { token } = store.state; |
|
|
const { push, location } = useRouter() |
|
|
const { push, location } = useRouter() |
|
|
console.log(location); |
|
|
|
|
|
|
|
|
|
|
|
const recordTabs = useMemo(() => ['充值', '提现', '收益'], []); |
|
|
|
|
|
|
|
|
const recordTabs = useMemo(() => ['充值', '提現', '收益'], []); |
|
|
const [recordIndex, setRecordIndex] = useState(location.state ? location.state.index : 0); |
|
|
const [recordIndex, setRecordIndex] = useState(location.state ? location.state.index : 0); |
|
|
const { copyVal } = useCopyLink(); |
|
|
const { copyVal } = useCopyLink(); |
|
|
const [query, setQuery] = useState([ |
|
|
const [query, setQuery] = useState([ |
|
@ -78,7 +77,7 @@ const Record = () => { |
|
|
return ( |
|
|
return ( |
|
|
<div className="plr-2 record"> |
|
|
<div className="plr-2 record"> |
|
|
<BackBar |
|
|
<BackBar |
|
|
title='账单' |
|
|
|
|
|
|
|
|
title='賬單' |
|
|
/> |
|
|
/> |
|
|
<Tabs |
|
|
<Tabs |
|
|
swipeable |
|
|
swipeable |
|
@ -119,10 +118,10 @@ const RechargeRecord = ( |
|
|
{ list, copy, finished, getData }: ChildProps |
|
|
{ list, copy, finished, getData }: ChildProps |
|
|
) => { |
|
|
) => { |
|
|
|
|
|
|
|
|
if (list.length <= 0 || Object.keys(list).length <= 0) return <Empty description="暂无记录" />; |
|
|
|
|
|
|
|
|
if (list.length <= 0 || Object.keys(list).length <= 0) return <Empty description="暫無記錄" />; |
|
|
|
|
|
|
|
|
return ( |
|
|
return ( |
|
|
<List finished={finished} onLoad={() => getData()} errorText="请求失败,点击重新加载" offset={10}> |
|
|
|
|
|
|
|
|
<List finished={finished} onLoad={() => getData()} errorText="請求失敗,點擊重新加載" offset={10}> |
|
|
{ |
|
|
{ |
|
|
list.map((item) => ( |
|
|
list.map((item) => ( |
|
|
<Cell key={item.id} className="ptb-1" style={{ background: 'none' }}> |
|
|
<Cell key={item.id} className="ptb-1" style={{ background: 'none' }}> |
|
@ -155,16 +154,16 @@ const RechargeRecord = ( |
|
|
|
|
|
|
|
|
const WithdrawRecord = ({ list, finished, getData, copy }: ChildProps) => { |
|
|
const WithdrawRecord = ({ list, finished, getData, copy }: ChildProps) => { |
|
|
|
|
|
|
|
|
if (list.length <= 0 || Object.keys(list).length <= 0) return <Empty description="暂无记录" />; |
|
|
|
|
|
|
|
|
if (list.length <= 0 || Object.keys(list).length <= 0) return <Empty description="暫無記錄" />; |
|
|
|
|
|
|
|
|
return ( |
|
|
return ( |
|
|
<List finished={finished} onLoad={() => getData()} errorText="请求失败,点击重新加载" offset={10}> |
|
|
|
|
|
|
|
|
<List finished={finished} onLoad={() => getData()} errorText="請求失敗,點擊重新加載" offset={10}> |
|
|
{ |
|
|
{ |
|
|
list.map((item, index) => ( |
|
|
list.map((item, index) => ( |
|
|
<Cell className='ptb-1' key={item.id} style={{ background: 'none' }}> |
|
|
<Cell className='ptb-1' key={item.id} style={{ background: 'none' }}> |
|
|
<div style={{ display: 'flex', justifyContent: 'space-between' }}> |
|
|
<div style={{ display: 'flex', justifyContent: 'space-between' }}> |
|
|
<div> |
|
|
<div> |
|
|
<div className='fz-wb-550'>提现</div> |
|
|
|
|
|
|
|
|
<div className='fz-wb-550'>提現</div> |
|
|
<div className='sub-color fz-14'>{getTime(item.time * 1000)}</div> |
|
|
<div className='sub-color fz-14'>{getTime(item.time * 1000)}</div> |
|
|
<div className='sub-color fz-14'> |
|
|
<div className='sub-color fz-14'> |
|
|
交易哈希:{item.tx_hash && splitAddress(item.tx_hash, 8)} |
|
|
交易哈希:{item.tx_hash && splitAddress(item.tx_hash, 8)} |
|
@ -191,10 +190,10 @@ const WithdrawRecord = ({ list, finished, getData, copy }: ChildProps) => { |
|
|
|
|
|
|
|
|
const TransferRecord = ({ list, finished, getData }: ChildProps) => { |
|
|
const TransferRecord = ({ list, finished, getData }: ChildProps) => { |
|
|
|
|
|
|
|
|
if (list.length <= 0 || Object.keys(list).length <= 0) return <Empty description="暂无记录" />; |
|
|
|
|
|
|
|
|
if (list.length <= 0 || Object.keys(list).length <= 0) return <Empty description="暫無記錄" />; |
|
|
|
|
|
|
|
|
return ( |
|
|
return ( |
|
|
<List finished={finished} onLoad={() => getData()} errorText="请求失败,点击重新加载" offset={10}> |
|
|
|
|
|
|
|
|
<List finished={finished} onLoad={() => getData()} errorText="請求失敗,點擊重新加載" offset={10}> |
|
|
{ |
|
|
{ |
|
|
list.map((item, index) => ( |
|
|
list.map((item, index) => ( |
|
|
<Cell className="ptb-1" key={item.id} style={{ background: 'none' }}> |
|
|
<Cell className="ptb-1" key={item.id} style={{ background: 'none' }}> |
|
|