|
|
|
@ -416,12 +416,12 @@
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="sensor-Text" id="sensor-text">
|
|
|
|
|
<p>设备编号:<span>10kv 主变压器001</span></p>
|
|
|
|
|
<!--<p>设备编号:<span>10kv 主变压器001</span></p>
|
|
|
|
|
<p>设备型号:<span>SC(B)10型干式电力变压器</span></p>
|
|
|
|
|
<p>启用时间:<span>2020年1月20日</span></p>
|
|
|
|
|
<p>所属变电站:<span>新疆某某变电站</span></p>
|
|
|
|
|
<p>测试参数-1:<span>xxxxx</span></p>
|
|
|
|
|
<p>测试参数-2:<span>xxxxx</span></p>
|
|
|
|
|
<p>测试参数-2:<span>xxxxx</span></p>-->
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -469,7 +469,7 @@
|
|
|
|
|
multiSelect: $('#chk-select-multi').is(':checked'),
|
|
|
|
|
onNodeSelected: function (event, node) {
|
|
|
|
|
$('#selectable-output').prepend('<p>' + node.text + ' was selected</p>');
|
|
|
|
|
if(node.nodeId > 0){
|
|
|
|
|
if (node.nodeId > 0) {
|
|
|
|
|
monitorUnitModule(node.href);
|
|
|
|
|
sensorCollectionRefresh(node.href);
|
|
|
|
|
}
|
|
|
|
@ -500,10 +500,10 @@
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
$(() => {
|
|
|
|
|
let unitId = getParams("id");
|
|
|
|
|
if( unitId != null) {
|
|
|
|
|
if (unitId != null) {
|
|
|
|
|
monitorUnitModule(unitId)
|
|
|
|
|
sensorCollectionRefresh(unitId);
|
|
|
|
|
}else{
|
|
|
|
|
} else {
|
|
|
|
|
$.ajax({
|
|
|
|
|
url: "/iot/deviceMonitor/getFirstMonitorUnit",
|
|
|
|
|
type: "get",
|
|
|
|
@ -523,15 +523,19 @@
|
|
|
|
|
type: "get",
|
|
|
|
|
dataType: 'JSON',
|
|
|
|
|
success: (res) => {
|
|
|
|
|
console.log("监控单元信息:" + res[0].deviceParams)
|
|
|
|
|
$('#transformer-model').html("");
|
|
|
|
|
let e = '<img src="' + res[0].monitorunitImage + '" >';
|
|
|
|
|
$("#transformer-model").append(e);
|
|
|
|
|
|
|
|
|
|
$('#sensor-text').html("");
|
|
|
|
|
let html = '<p>设备编号:<span>' + res[0].monitorunitName + '</span></p>\n' +
|
|
|
|
|
' <p>设备型号:<span>' + res[0].monitorunitName + '</span></p>\n' +
|
|
|
|
|
' <p>启用时间:<span>' + formatter(res[0].createTime, "yyyy-MM-dd") + '</span></p>\n' +
|
|
|
|
|
' <p>所属变电站:<span>' + res[0].substationName + '</span></p>';
|
|
|
|
|
let html = '<p>设备编号:<span>' + res[0].monitorunitName + '</span></p>';
|
|
|
|
|
if(res[0].deviceParams.length > 0){
|
|
|
|
|
res[0].deviceParams.map(x => {
|
|
|
|
|
html += '<p>' + x.paramTitle + ':<span>' + x.paramValue + '</span></p>';
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
html += ' <p>所属变电站:<span>' + res[0].substationName + '</span></p>';
|
|
|
|
|
$("#sensor-text").append(html);
|
|
|
|
|
},
|
|
|
|
|
error: () => {
|
|
|
|
@ -585,10 +589,10 @@
|
|
|
|
|
console.log(result);
|
|
|
|
|
switch (result.type) {
|
|
|
|
|
case "CMD_REPORTDATA":
|
|
|
|
|
reportData(result);
|
|
|
|
|
reportData(result);
|
|
|
|
|
break;
|
|
|
|
|
case "CMD_SENSORSTATUS":
|
|
|
|
|
reportStatus(result);
|
|
|
|
|
reportStatus(result);
|
|
|
|
|
break;
|
|
|
|
|
default:
|
|
|
|
|
break;
|
|
|
|
@ -634,7 +638,7 @@
|
|
|
|
|
document.getElementById(result.sensorId + "collectTime").innerHTML = result['collectTime'] == null ? "-" : collectTime(result['collectTime']);
|
|
|
|
|
}
|
|
|
|
|
//上报设备状态
|
|
|
|
|
const reportStatus = function(result) {
|
|
|
|
|
const reportStatus = function (result) {
|
|
|
|
|
document.getElementById(result.sensorId + "sensorStatus").innerHTML = result['sensorStatus'] == null ? "-" : sensorStatus(result['sensorStatus']);
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|