|
|
@ -12,8 +12,11 @@ const Guanli = (props) => { |
|
|
|
const [rightDatas,setrightDatas] = useState([]) |
|
|
|
const requestleftDatas = async()=>{ |
|
|
|
const res = await dispatch(getjiandmanage()) |
|
|
|
res.payload.data.sort((a,b)=>{ |
|
|
|
return parseInt(b.total) - parseInt(a.total) |
|
|
|
}) |
|
|
|
setleftDatas(res.payload.data) |
|
|
|
// console.log(res,'哈哈哈')
|
|
|
|
console.log(res.payload.data,'哈哈哈') |
|
|
|
} |
|
|
|
const requestRightDatas = async()=>{ |
|
|
|
const res = await dispatch(getjiandetail()) |
|
|
@ -24,7 +27,7 @@ const Guanli = (props) => { |
|
|
|
requestleftDatas(); |
|
|
|
requestRightDatas() |
|
|
|
},[]) |
|
|
|
// let datalist = newArry(35)
|
|
|
|
// let datalist = newArry(30)
|
|
|
|
// datalist.fill({licensePlate:"赣A44454",overrunRate:"30%",fine:"200元",processingTime:"2020年4月1日"})
|
|
|
|
const renderContent = () => { |
|
|
|
return <div style={{height:"100%"}}> |
|
|
@ -41,6 +44,7 @@ const Guanli = (props) => { |
|
|
|
</div> |
|
|
|
} |
|
|
|
const renderLeftContent = ()=>{ |
|
|
|
// setleftDatas(leftDatas=>leftDatas.sort((a,b)=>b.total - a.total))
|
|
|
|
|
|
|
|
return leftDatas && leftDatas.length!==0?leftDatas.map((item,index)=> |
|
|
|
<LeftItem key={index} datas={item}></LeftItem> |
|
|
|