Browse Source

修复建设大屏bug

release_0.0.4
dengyinhuan 2 years ago
parent
commit
94d3a4c324
  1. 6
      web/client/src/sections/quanju/containers/footer/build/Rightbottom.js
  2. 29
      web/client/src/sections/quanju/containers/footer/build/index.js
  3. 2
      web/client/src/sections/quanju/containers/footer/build/style.less

6
web/client/src/sections/quanju/containers/footer/build/Rightbottom.js

@ -11,13 +11,15 @@ function Rightbottom(props) {
"rgba(7,185,254,1)",
"rgba(28,96,254,1)",
"rgba(4,251,240,1)",
"rgba(255,194,20,1)"
"rgba(255,194,20,1)",
'rgba(255,255,255,1)'
]
let underColorList = [
"rgba(7,185,254,0.5)",
"rgba(28,96,254,0.5)",
"rgba(4,251,240,0.5)",
"rgba(255,194,20,0.5)"
"rgba(255,194,20,0.5)",
'rgba(255,255,255,0.5)',
]
let name = [], emptyName = []
// const name = data?.map(d)

29
web/client/src/sections/quanju/containers/footer/build/index.js

@ -12,7 +12,8 @@ import RightBottom from './Rightbottom'
import AutoRollComponent from './AutoRollComponent'
import './style.less'
import {getdaolutongji,getxuanchuan} from '../../../actions/example'
import { number } from 'echarts';
import { Carousel } from 'antd';
// import { number } from 'echarts';
const Build = (props) => {
const { dispatch } = props
let data1 = [
@ -89,20 +90,11 @@ const Build = (props) => {
let safetyData = alldengji?.filter(item=>item.name==='一级公路'||item.name==='二级公路'||item.name==='三级公路'||item.name==='四级公路'||item.name==='等外公路')
let sundata = data?.reduce((x,y)=>x+y.value,0)
let sunsafetyData = safetyData?.reduce((x,y)=>x+y.value,0)
// console.log(safetyData,'好凶猛')
// console.log(data1,'对比')
// console.log(totalgongli,"好好的")
// console.log(keepThreeNum(totalgongli),'jjjjj')
useEffect(()=>{
requestbuildingnumber();
requestxuanchuanlan()
},[])
// const datas = new Array(15)
// datas.fill({
// name:"东乡镇",
// number:"11111",
// gongli:'9999'
// },0,15)
const rendercontent = ()=>{
return (<div className='build-left-center-content'>
{list.map(({name,number,gongli},index)=><div className='build-left-center-item' key={index}>
@ -201,7 +193,20 @@ const Build = (props) => {
}} customize={true}>
<div className='build-right-top'>
{/* <img src='/assets/images/quanju/xuanchuanlan.jpg'></img> */}
<video src={xuandata&&xuandata!==null&&xuandata.length!==0?`${localStorage.getItem("qndmn")}/${xuandata[0].video!==null&&xuandata[0].video?xuandata[0].video[0]:""}`:"#"} autoPlay="autoplay" loop></video>
<Carousel autoplay={true} dots={false} autoplaySpeed={180000}>
{xuandata&&xuandata!==null&&xuandata.length!==0?xuandata.map((item,index)=>{
if(item.enable){
if(item.video&&item.video!==null&&item.video.length!==0){
return item.video.map((i,index)=>{
// console.log(i,'视频')
return <video src={`${localStorage.getItem("qndmn")}/${i}`} autoPlay="autoplay" loop></video>
})
}
// return <video src={`${localStorage.getItem("qndmn")}/${item.video!==null&&item.video.length!==0?item.video[0]:""}`} autoPlay="autoplay" loop></video>
}
}):""}
{/* <video src={xuandata&&xuandata!==null&&xuandata.length!==0?`${localStorage.getItem("qndmn")}/${xuandata[0].video!==null&&xuandata[0].video?xuandata[0].video[0]:""}`:"#"} autoPlay="autoplay" loop></video> */}
</Carousel>
<h2>全面建设好农村公路切实发挥先行官作用</h2>
</div>
</Module>

2
web/client/src/sections/quanju/containers/footer/build/style.less

@ -214,7 +214,7 @@
padding: 0 10px;
video{
width: 100%;
height: 65%;
height: 17vh;
// margin-bottom: 5%;
}

Loading…
Cancel
Save