Browse Source

(*)数据在线率时间优化为时分秒格式; 数据详情和数据计算测点选择优化; 服务器信息运维监控网站修改; 修复固件升级页面报错

dev
wuqun 1 year ago
parent
commit
54cd189dcd
  1. 3
      api/app/lib/controllers/firmwareUpgrade/index.js
  2. 3
      web/client/src/sections/data/containers/dataDetail.jsx
  3. 2
      web/client/src/sections/firmwareUpgrade/containers/deviceManagement.jsx
  4. 2
      web/client/src/sections/firmwareUpgrade/containers/firmwareLibrary.jsx
  5. 4
      web/client/src/sections/install/containers/cacl.jsx
  6. 4
      web/client/src/sections/projectGroup/containers/bigscreen.jsx
  7. 2
      web/package.json

3
api/app/lib/controllers/firmwareUpgrade/index.js

@ -88,7 +88,8 @@ async function getFirmwares (ctx) {
const query = ctx.query
// console.log('query1',query)
try{
const res=await ctx.app.fs.craw.get(ApiTable.getFirmwares,{query})
const { tokenup } = ctx.query
const res = await ctx.app.fs.craw.get(ApiTable.getFirmwares,{query:{ ...query, token: tokenup} })
// console.log('666x1111',res)
let rslt=[]
if(res){

3
web/client/src/sections/data/containers/dataDetail.jsx

@ -221,8 +221,9 @@ const DataDetail = (props) => {
field="point"
placeholder="点位"
multiple
maxTagCount={2}
optionList={sensorList}
style={{ width: 260, marginLeft: 12, marginRight: 12 }}
style={{ width: 280, marginLeft: 12, marginRight: 12 }}
showClear
onChange={pointChange}
></Form.Select>

2
web/client/src/sections/firmwareUpgrade/containers/deviceManagement.jsx

@ -45,7 +45,7 @@ const DeviceManagement = (props) => {
})
// console.log('xxxx111',user)
dispatch(firmwareUpgrade.getFirmware()).then(res=>{
dispatch(firmwareUpgrade.getFirmware({tokenup: '22767e1f-db8d-4a1d-87d4-56347cf21247'})).then(res=>{
if(res.success) setVData(res.payload.data)
})
},[pepProjectId])

2
web/client/src/sections/firmwareUpgrade/containers/firmwareLibrary.jsx

@ -16,7 +16,7 @@ const FirmwareLibrary = (props) => {
const {service,firmwareUpgrade}=actions
// console.log(data,'data1111')
const getData=(query)=>{
dispatch(firmwareUpgrade.getFirmware(query)).then(res=>{
dispatch(firmwareUpgrade.getFirmware({tokenup: '22767e1f-db8d-4a1d-87d4-56347cf21247',...query})).then(res=>{
if(res.success)setData(res.payload.data)
})
}

4
web/client/src/sections/install/containers/cacl.jsx

@ -451,8 +451,8 @@ const Calc = (props) => {
</Form.Cascader>
</Col>
<Col span={6} >
<Form.Select showSearch filter multiple iSelect label="测点" field="point" value={sensorId} onChange={pointChange}
optionList={sensorList} placeholder="请选择测点" style={{ textAlign: 'left', width: 274 }} >
<Form.Select showSearch filter multiple maxTagCount={1} showClear iSelect label="测点" field="point" value={sensorId} onChange={pointChange}
optionList={sensorList} placeholder="请选择测点" style={{ textAlign: 'left', width: '90%' }} >
</Form.Select>
</Col>
<Col span={6} >

4
web/client/src/sections/projectGroup/containers/bigscreen.jsx

@ -318,7 +318,7 @@ const Bigscreen = (props) => {
// console.log(params);
let title = params[0].data[0] + '<br/>' + '<br/>'
params.forEach(v => {
let find = online?.find(s => s.name == v.seriesName)?.online?.find(d => moment(d.collect_time).format('YYYY-MM-DD HH') == v.data[0]) || {}
let find = online?.find(s => s.name == v.seriesName)?.online?.find(d => moment(d.collect_time).format('YYYY-MM-DD HH:mm:ss') == v.data[0]) || {}
title = title + v.seriesName + ":" + "&nbsp" + "&nbsp" + v.data[1] + "%" + "(" + find?.online + "/" + find?.total + ")" + '<br/>'
})
return title
@ -358,7 +358,7 @@ const Bigscreen = (props) => {
areaStyle: {
color: '#0e9cff26',
},
data: v.online.sort((a,b)=>new Date(b.collect_time)-new Date(a.collect_time))?.map(f => [moment(f.collect_time).format('YYYY-MM-DD HH'), f.rate.toFixed(1)]) || []
data: v.online.sort((a,b)=>new Date(b.collect_time)-new Date(a.collect_time))?.map(f => [moment(f.collect_time).format('YYYY-MM-DD HH:mm:ss'), f.rate.toFixed(1)]) || []
})) || []
}}
notMerge={true}

2
web/package.json

@ -7,7 +7,7 @@
"test": "mocha",
"start-vite": "cross-env NODE_ENV=developmentVite npm run start-params",
"start": "cross-env NODE_ENV=development npm run start-params",
"start-params": "node server -p 5600 -u http://localhost:4600 --networkWeb http://localhost:5000 --apiPomsUrl http://localhost:4600 --apiAnxinyunUrl http://10.8.30.112:4100 --apiEmisUrl http://localhost:14000 --webEmisUrl http://localhost:5000 --webOaUrl http://10.8.30.161:8668 --qnak 5XrM4wEB9YU6RQwT64sPzzE6cYFKZgssdP5Kj3uu --qnsk w6j2ixR_i-aelc6I7S3HotKIX-ukMzcKmDfH6-M5 --qnbkt anxinyun-test --qndmn http://test.resources.anxinyun.cn --iotVcmpWeb https://mediaconsole.ngaiot.com --pomsMonitor http://monitor.anxinyun.cn/goto/PaEDLE84z?orgId=1 --pomsKubesphere https://k8sadmin.anxinyun.cn/ --pomsAmbari https://ambari.anxinyun.cn/ --pomsKowl https://kafka.anxinyun.cn/ --pomsPghero https://pghero.anxinyun.cn/ --pomsEs https://esc.anxinyun.cn/ --pomsNotebook https://inotebook.anxinyun.cn/ --crawapi http://218.3.126.49:30555/v1 --dcWeb https://fsiot-oamss.anxinyun.cn",
"start-params": "node server -p 5600 -u http://localhost:4600 --networkWeb http://localhost:5000 --apiPomsUrl http://localhost:4600 --apiAnxinyunUrl http://10.8.30.112:4100 --apiEmisUrl http://localhost:14000 --webEmisUrl http://localhost:5000 --webOaUrl http://10.8.30.161:8668 --qnak 5XrM4wEB9YU6RQwT64sPzzE6cYFKZgssdP5Kj3uu --qnsk w6j2ixR_i-aelc6I7S3HotKIX-ukMzcKmDfH6-M5 --qnbkt anxinyun-test --qndmn http://test.resources.anxinyun.cn --iotVcmpWeb https://mediaconsole.ngaiot.com --pomsMonitor http://monitor.anxinyun.cn/goto/PaEDLE84z?orgId=1 --pomsKubesphere https://ksboard.ngaiot.com/ --pomsAmbari https://ambari.anxinyun.cn/ --pomsKowl https://kafka.anxinyun.cn/ --pomsPghero https://pghero.anxinyun.cn/ --pomsEs https://esc.anxinyun.cn/ --pomsNotebook https://inotebook.anxinyun.cn/ --crawapi http://218.3.126.49:30555/v1 --dcWeb https://fsiot-oamss.anxinyun.cn",
"deploy": "export NODE_ENV=production&& npm run build && node server",
"build-dev": "cross-env NODE_ENV=development&&webpack --config webpack.config.js",
"build": "cross-env NODE_ENV=production&&webpack --config webpack.config.prod.js"

Loading…
Cancel
Save