change - 箱壳成型数据监控平台、铝内胆数据监控平台设备功率单位改为W

master
wenjy 2 years ago
parent 199babac34
commit 0a73c45377

@ -7,7 +7,7 @@ $(() => {
if (result.length > 0) { if (result.length > 0) {
if(result[0].deviceEnergy > 0){ if(result[0].deviceEnergy > 0){
statusArray[0] = result[0].deviceStatus == "正常" ? "1" : "0"; statusArray[0] = result[0].deviceStatus == "正常" ? "1" : "0";
statusArray[1] = result[0].devicePower; statusArray[1] = result[0].devicePower+"W";
statusArray[2] = result[0].deviceEnergy; statusArray[2] = result[0].deviceEnergy;
statusArray[3] = result[0].count; statusArray[3] = result[0].count;
dataInformationFunction(statusArray); dataInformationFunction(statusArray);

@ -84,7 +84,7 @@ const dataInformationFunction = (statusArray) => {
let info = `<table style="position: absolute;top: 8%;width: 100%;height:100%;"> let info = `<table style="position: absolute;top: 8%;width: 100%;height:100%;">
<tr style="width: 100%; height: 50%;"> <tr style="width: 100%; height: 50%;">
<td style="border:0px solid red;text-align:center;width: 50%;"><i ${res.deviceStatus == 1 ? 'style="color:rgb(107, 253, 110);"' : 'style="color: rgb(255, 105, 106);"'} class="fa-regular ${res.deviceStatus == 1 ? "fa-circle-check" : "fa-circle-xmark"}"></i>${res.deviceStatus == 1 ? `<span style="color:rgb(107, 253, 110);margin-left: 10px"></span>` : `<span style="color:rgb(255, 105, 106);margin-left: 10px"></span>`}</td> <td style="border:0px solid red;text-align:center;width: 50%;"><i ${res.deviceStatus == 1 ? 'style="color:rgb(107, 253, 110);"' : 'style="color: rgb(255, 105, 106);"'} class="fa-regular ${res.deviceStatus == 1 ? "fa-circle-check" : "fa-circle-xmark"}"></i>${res.deviceStatus == 1 ? `<span style="color:rgb(107, 253, 110);margin-left: 10px"></span>` : `<span style="color:rgb(255, 105, 106);margin-left: 10px"></span>`}</td>
<td style="border:0px solid red;text-align:center;width: 50%;color: #FFEF76;"> ${res.devicePower} kW</td> <td style="border:0px solid red;text-align:center;width: 50%;color: #FFEF76;"> ${res.devicePower} W</td>
</tr> </tr>
<tr style="width: 100%; height: 50%;"> <tr style="width: 100%; height: 50%;">

@ -12,6 +12,6 @@ mybatis-plus:
mapper-locations: classpath*:/mapper/**Mapper.xml mapper-locations: classpath*:/mapper/**Mapper.xml
server: server:
port: 6069 port: 6070
in_id: 1 in_id: 2

@ -7,7 +7,7 @@ $(() => {
if (result.length > 0) { if (result.length > 0) {
if(result[0].deviceEnergy > 0){ if(result[0].deviceEnergy > 0){
statusArray[0] = result[0].deviceStatus == "正常" ? "1" : "0"; statusArray[0] = result[0].deviceStatus == "正常" ? "1" : "0";
statusArray[1] = result[0].devicePower; statusArray[1] = result[0].devicePower+"W";
statusArray[2] = result[0].deviceEnergy; statusArray[2] = result[0].deviceEnergy;
statusArray[3] = result[0].count; statusArray[3] = result[0].count;
dataInformationFunction(statusArray); dataInformationFunction(statusArray);

@ -2201,6 +2201,9 @@ const energyConsumption = (res, ids) => {
bottom: '3%', bottom: '3%',
containLabel: true containLabel: true
}, },
tooltip:{
trigger :'axis',
},
xAxis: [ xAxis: [
{ {
interval: 0, interval: 0,
@ -2211,6 +2214,7 @@ const energyConsumption = (res, ids) => {
} }
} }
], ],
yAxis: [ yAxis: [
{ {
type: 'value', type: 'value',
@ -2277,7 +2281,7 @@ const energyConsumption = (res, ids) => {
}, },
tooltip: { tooltip: {
valueFormatter: function (value) { valueFormatter: function (value) {
return value + ' ml'; return value + ' t';
} }
}, },
barWidth: 20, barWidth: 20,
@ -2289,16 +2293,23 @@ const energyConsumption = (res, ids) => {
yAxisIndex: 1, yAxisIndex: 1,
tooltip: { tooltip: {
valueFormatter: function (value) { valueFormatter: function (value) {
return value + ' °C'; return value + ' kw·h';
} }
}, },
lineStyle: { lineStyle: {
color: '#45b685' color: '#0066FF'
},
/*label: {
show: true,
position: "buttom",
textStyle: {
color: "#0066FF",
}, },
},*/
data: yAxisDataTwo, data: yAxisDataTwo,
}, },
{ {
name: "柱顶部", name: "",
type: "pictorialBar", type: "pictorialBar",
symbolSize: [20, 6], symbolSize: [20, 6],
symbolOffset: [0, -3], symbolOffset: [0, -3],
@ -2310,6 +2321,9 @@ const energyConsumption = (res, ids) => {
}, },
}, },
}, },
tooltip: {
show:false,
},
label: { label: {
show: true, show: true,
position: "top", position: "top",

@ -84,7 +84,7 @@ const dataInformationFunction = (statusArray) => {
let info = `<table style="position: absolute;top: 8%;width: 100%;height:100%;"> let info = `<table style="position: absolute;top: 8%;width: 100%;height:100%;">
<tr style="width: 100%; height: 50%;"> <tr style="width: 100%; height: 50%;">
<td style="border:0px solid red;text-align:center;width: 50%;"><i ${res.deviceStatus == 1 ? 'style="color:rgb(107, 253, 110);"' : 'style="color: rgb(255, 105, 106);"'} class="fa-regular ${res.deviceStatus == 1 ? "fa-circle-check" : "fa-circle-xmark"}"></i>${res.deviceStatus == 1 ? `<span style="color:rgb(107, 253, 110);margin-left: 10px"></span>` : `<span style="color:rgb(255, 105, 106);margin-left: 10px"></span>`}</td> <td style="border:0px solid red;text-align:center;width: 50%;"><i ${res.deviceStatus == 1 ? 'style="color:rgb(107, 253, 110);"' : 'style="color: rgb(255, 105, 106);"'} class="fa-regular ${res.deviceStatus == 1 ? "fa-circle-check" : "fa-circle-xmark"}"></i>${res.deviceStatus == 1 ? `<span style="color:rgb(107, 253, 110);margin-left: 10px"></span>` : `<span style="color:rgb(255, 105, 106);margin-left: 10px"></span>`}</td>
<td style="border:0px solid red;text-align:center;width: 50%;color: #FFEF76;"> ${res.devicePower} kW</td> <td style="border:0px solid red;text-align:center;width: 50%;color: #FFEF76;"> ${res.devicePower} W</td>
</tr> </tr>
<tr style="width: 100%; height: 50%;"> <tr style="width: 100%; height: 50%;">

Loading…
Cancel
Save