feat(): 渗压、渗流和位移数据对接
parent
46df02e1c5
commit
3a4153f941
|
|
@ -29,11 +29,11 @@ const Page = () => {
|
|||
]
|
||||
}else{
|
||||
return [
|
||||
{ title: '监测点', key: 'stationCode', dataIndex: 'stationCode',align: "center",width: 80, ellipsis: true },
|
||||
{ title: '监测点', key: 'cd', dataIndex: 'cd',align: "center",width: 80, ellipsis: true },
|
||||
{ title: '监测时间', key: 'tm', dataIndex: 'tm',align: "center",width: 80, ellipsis: true, render:(v,row)=><div style={{color:row.flag===1?'red':'#3B4859'}}><div>{v?.slice(5,10)}</div><div>{v?.slice(11,16)}</div></div> },
|
||||
{ title: <div><div>X方向</div><div>(mm)</div></div>, key: 'x', dataIndex: 'x',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.xstatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>Y方向</div><div>(mm)</div></div>, key: 'y', dataIndex: 'y',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.ystatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>H方向</div><div>(mm)</div></div>, key: 'h', dataIndex: 'h',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.hstatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>e方向</div><div>(mm)</div></div>, key: 'de', dataIndex: 'de',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.xstatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>n方向</div><div>(mm)</div></div>, key: 'dn', dataIndex: 'dn',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.ystatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>u方向</div><div>(mm)</div></div>, key: 'du', dataIndex: 'du',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.hstatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
]
|
||||
}
|
||||
}, [checked]);
|
||||
|
|
@ -89,7 +89,10 @@ const Page = () => {
|
|||
<Table rowKey="stationCode"
|
||||
sticky
|
||||
columns={columns}
|
||||
pagination={false}
|
||||
pagination={checked == '位移监测' ?{
|
||||
pageSize: 100,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: [ '100', '200']}:false}
|
||||
dataSource={tableData}
|
||||
scroll={{ y: "300px"}}
|
||||
onRow={
|
||||
|
|
|
|||
|
|
@ -44,11 +44,11 @@ export default function Page({isHome}) {
|
|||
]
|
||||
|
||||
const columnsWy = [
|
||||
{ title: '监测点', key: 'stationCode', dataIndex: 'stationCode',align: "center",width: 80, ellipsis: true },
|
||||
{ title: '监测点', key: 'cd', dataIndex: 'cd',align: "center",width: 80, ellipsis: true },
|
||||
{ title: '监测时间', key: 'tm', dataIndex: 'tm',align: "center",width: 80, ellipsis: true, render:(v,row)=><div style={{color:row.flag===1?'red':'#3B4859'}}><div>{v?.slice(5,10)}</div><div>{v?.slice(11,16)}</div></div> },
|
||||
{ title: <div><div>X方向</div><div>(mm)</div></div>, key: 'x', dataIndex: 'x',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.xstatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>Y方向</div><div>(mm)</div></div>, key: 'y', dataIndex: 'y',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.ystatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>H方向</div><div>(mm)</div></div>, key: 'h', dataIndex: 'h',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.hstatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>e方向</div><div>(mm)</div></div>, key: 'de', dataIndex: 'de',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.xstatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>n方向</div><div>(mm)</div></div>, key: 'dn', dataIndex: 'dn',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.ystatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
{ title: <div><div>u方向</div><div>(mm)</div></div>, key: 'du', dataIndex: 'du',align: "center", ellipsis: true, render:(v,row)=><div style={{color:row.hstatus===1?'red':'#3B4859'}}>{v}</div> },
|
||||
]
|
||||
|
||||
|
||||
|
|
@ -194,8 +194,13 @@ export default function Page({isHome}) {
|
|||
<Table rowKey="stationCode"
|
||||
sticky
|
||||
columns={columnsWy}
|
||||
pagination={false}
|
||||
// pagination={false}
|
||||
dataSource={wyList}
|
||||
pagination={{
|
||||
pageSize: 100,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: [ '100', '200'],
|
||||
}}
|
||||
scroll={{ y: "650px"}}
|
||||
onRow={
|
||||
(data)=>({
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ const Page = () => {
|
|||
let newArr = [];
|
||||
let newData = res.data?.map((s, i) => {
|
||||
newArr.push(s.list?.map(c => ({
|
||||
[c.stationCode]: c.value || '-',
|
||||
[c.stationCode]: (c.value || c.value == 0) ? c.value : '-',
|
||||
tm:c.tm
|
||||
})))
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -83,7 +83,7 @@ const Page = () => {
|
|||
let newArr = [];
|
||||
let newData = res.data?.map((s, i) => {
|
||||
newArr.push(s.list?.map((c, i) => ({
|
||||
[c.cd]: c.value || '-',
|
||||
[c.cd]: (c.value || c.value == 0) ? c.value : '-',
|
||||
[`e_${c.cd}`]:c.de ,
|
||||
[`n_${c.cd}`]:c.dn ,
|
||||
[`u_${c.cd}`]:c.du ,
|
||||
|
|
@ -171,7 +171,7 @@ const Page = () => {
|
|||
}
|
||||
getTable2Data(params)
|
||||
}
|
||||
}, [trData,wyObj])
|
||||
}, [trData,wyObj,searchVal])
|
||||
|
||||
useEffect(() => {
|
||||
getDmTree()
|
||||
|
|
|
|||
|
|
@ -83,8 +83,8 @@ const Page = () => {
|
|||
},
|
||||
{
|
||||
title: '测点编号',
|
||||
dataIndex: 'mnNo',
|
||||
key: 'mnNo',
|
||||
dataIndex: 'order',
|
||||
key: 'order',
|
||||
width: 120,
|
||||
align:'center'
|
||||
},
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ const ToolBar = ({ setSearchVal, onSave, storeData, role }) => {
|
|||
style={{ width: "240px" }}
|
||||
/>
|
||||
</Form.Item>
|
||||
<Form.Item label="测点编号" name="mnNo">
|
||||
<Form.Item label="测点编号" name="order">
|
||||
<Input
|
||||
allowClear
|
||||
style={{ width: "240px" }}
|
||||
|
|
|
|||
Loading…
Reference in New Issue