Browse Source

*左侧暂无数据展示

release_0.0.4
wanyiwei 3 years ago
parent
commit
186b48f9a0
  1. 36
      web/client/src/sections/quanju/containers/footer/operation/left.js

36
web/client/src/sections/quanju/containers/footer/operation/left.js

@ -27,8 +27,8 @@ const Left = (props) => {
const onChange = (e) => { const onChange = (e) => {
const { value } = e.target; const { value } = e.target;
let keys = [] let keys = []
const newExpandedKeys = treeDataList.filter(e=> e.key.match(value)) const newExpandedKeys = treeDataList.filter(e => e.key.match(value))
newExpandedKeys.forEach(e=>{ newExpandedKeys.forEach(e => {
keys.push(e.key) keys.push(e.key)
}) })
setExpandedKeys(keys); setExpandedKeys(keys);
@ -66,12 +66,12 @@ const Left = (props) => {
key: e.name, key: e.name,
title: e.name, title: e.name,
}) })
e.child.forEach(i=>{ e.child.forEach(i => {
dataList.push({ dataList.push({
key: i.name, key: i.name,
title: i.name, title: i.name,
}) })
i.child.forEach(s=>{ i.child.forEach(s => {
dataList.push({ dataList.push({
key: s.vehicleLicensePlateNumber, key: s.vehicleLicensePlateNumber,
title: s.vehicleLicensePlateNumber, title: s.vehicleLicensePlateNumber,
@ -103,18 +103,22 @@ const Left = (props) => {
/> />
</div> </div>
<div className='busList'> <div className='busList'>
<Tree {
rootStyle={{ treeData.length > 0 ?
marginTop: '1%', <Tree
background: 'none', rootStyle={{
borderColor: 'none', marginTop: '1%',
color: 'rgba(255, 255, 255, 1)' background: 'none',
}} borderColor: 'none',
onExpand={onExpand} color: 'rgba(255, 255, 255, 1)'
expandedKeys={expandedKeys} }}
autoExpandParent={autoExpandParent} onExpand={onExpand}
treeData={treeData} expandedKeys={expandedKeys}
/> autoExpandParent={autoExpandParent}
treeData={treeData}
/> : <div style={{width:'100%',color:'#fff',textAlign:'center',marginTop:'90%'}}></div>
}
</div> </div>
</div> </div>
</Module> </Module>

Loading…
Cancel
Save