| | |
| | | <link rel="stylesheet" type="text/css" href="css/basic-layout.css"/>
|
| | | <link rel="stylesheet" href="css/sidebar.css" />
|
| | | <link rel="stylesheet" href="css/confirm.css" />
|
| | | <link href="src/css/layui.css" type="text/css" rel="stylesheet">
|
| | | <style type="text/css">
|
| | | .b8cfe5 {
|
| | | background-color: #b8cfe5 !important;
|
| | |
| | | <table>
|
| | | <tbody>
|
| | | <tr>
|
| | | <th><s:text name="Maintenance_area"/></th> <!-- 维护区 -->
|
| | | <th>省</th> <!-- 省 -->
|
| | | <th>市</th> <!-- 市 -->
|
| | | <th>区/县</th> <!-- 区/县 -->
|
| | | <th><s:text name="Computer_site"/></th> <!-- 机房站点 -->
|
| | | <th><s:text name="Battery"/></th> <!-- 蓄电池组 -->
|
| | | <th colspan="2" style="width: 30%;"><s:text name="Alarm"/><s:text name="Start_date"/></th> <!-- 开始告警日期 -->
|
| | | </tr>
|
| | | <tr>
|
| | | <td>
|
| | | <select name="" id="station_name1">
|
| | | |
| | | </select>
|
| | | <select name="" id="station_name1"></select>
|
| | | </td>
|
| | | <td>
|
| | | <select name="" id="station_name">
|
| | | |
| | | </select>
|
| | | <select name="" id="city"></select>
|
| | | </td>
|
| | | <td>
|
| | | <select name="" id="battgroup_name">
|
| | | |
| | | </select>
|
| | | <select name="" id="county"></select>
|
| | | </td>
|
| | | <td>
|
| | | <select name="" id="station_name"></select>
|
| | | </td>
|
| | | <td>
|
| | | <select name="" id="battgroup_name"></select>
|
| | | </td>
|
| | | <td><input type="text" id="startalm" readonly="readonly" name="bmd.adata.alm_start_time" value="2000-1-1" /></td>
|
| | | <td><input type="text" id="endTalm" readonly="readonly" name="bmd.adata.alm_start_time1" /></td>
|
| | |
| | | </table>
|
| | | <table class="condi-opt">
|
| | | <tr>
|
| | | <input type="hidden" id="usr_id" name="bmd.mainf.usr_id" value="0" class="119001" /><!-- <s:text name="On-line_voltage" /> 在线电压 -->
|
| | | <td><input type="checkbox" id="usr_id" name="bmd.mainf.usr_id" checked="checked" value="0" class="119001" /> <s:text name="On-line_voltage" /></td> <!-- 在线电压 -->
|
| | | <td>
|
| | | <input type="checkbox" id="fault_type_id" name="bmd.mainf.fault_type_id" checked="checked" value="119002" class="119002" /><s:text name="Group_voltage" /> <!-- 组端电压 -->
|
| | | </td>
|
| | |
| | | <input type="hidden" id="master_id" name="bmd.mainf.master_id" value="0" class="119008" /><!-- 连接条阻抗-->
|
| | | <td><input type="checkbox" id="maint_close" name="bmd.mainf.maint_close" checked="checked" value="119007" class="119007"><s:text name="Monomer_resistance" /></td> <!-- 单体内阻 -->
|
| | | <td><input type="checkbox" id='maint_done' name="bmd.mainf.maint_done" checked="checked" value="119006" class="119006"><s:text name="Temperature_monomer" /></td> <!-- 单体温度 -->
|
| | | <td></td>
|
| | | <!-- <td><input type="checkbox" checked="checked" id="hist_alm" class="1"><s:text name="Historical_alarms" /></td> --> <!-- 历史告警 -->
|
| | | <td><input type="checkbox" name="bmd.mainf.master_audit" id="master_audit" checked="checked" value="3" class="3"><s:text name="Level_thr_warn" /></td> <!-- 三级告警 -->
|
| | | <td><input type="checkbox" name="bmd.mainf.appoint_uid" id="appoint_uid" checked="checked" value="4" class="4"><s:text name="Level_four_warn" /></td> <!-- 四级告警 -->
|
| | |
| | | <script type="text/javascript" src="js/myConfirm.js"></script>
|
| | | <script type="text/javascript" src="js/myinterval.js"></script>
|
| | | <script type="text/javascript" src="js/pageUtil.js"></script>
|
| | | <script type="text/javascript" src="src/layui.all.js"></script>
|
| | | <script type="text/javascript">
|
| | | var permits;
|
| | | <% Object obj=session.getAttribute("permits");
|
| | |
| | | }
|
| | |
|
| | |
|
| | | $(function(){
|
| | | //点击查询按钮
|
| | | $('#paging .search').click(function(){
|
| | | searchHistalm();
|
| | | });
|
| | | });
|
| | | |
| | | |
| | | var formjson;
|
| | | //查询历史告警记录
|
| | | function searchHistalm(){
|
| | | loading.showLoading(); |
| | | var load = layer.load(1); |
| | | var json = JSON.stringify(createSearchForm());
|
| | | //console.info(json);
|
| | | $.post("Battalarm_data_historyAction!serchByInfo","json="+json,function(data){
|
| | | data=data.result;
|
| | | data=eval("("+data+")");
|
| | | console.info(data);
|
| | | //console.info(data);
|
| | | if(data.code==1 && data.data.length>0){
|
| | | data=data.data;
|
| | | ArrWarnTb = new Array(); // 用于存放表格数据
|
| | |
| | | }
|
| | | $('#tbHead').text('');
|
| | | createFullTbl($('.tbl-header'), $('.tbl-body'), ArrWarnTh, ArrWarnTb);
|
| | | loading.hideLoading();
|
| | | layer.close(load);
|
| | | }).error(function(){
|
| | | loading.hideLoading();
|
| | | layer.close(load);
|
| | | noContent.showNoContent("查询失败,请检查网络连接!");
|
| | | });
|
| | | }
|
| | |
| | | var temp={
|
| | | page:Page,
|
| | | binf:{
|
| | | StationName1:$('#station_name1').val(), //维护区
|
| | | StationName1:$('#station_name1').val(), // 省
|
| | | StationName2:$('#city').val(),
|
| | | StationName5:$('#county').val(), // 市
|
| | | StationName:$('#station_name').val(), //机房名称
|
| | | BattGroupId:$('#battgroup_name').val(), //电池组名称
|
| | | },
|
| | |
| | | master_audit:$('#master_audit').is(':checked')?$('#master_audit').attr('class'):0, //三级告警
|
| | | num:$('#num').is(':checked')?$('#num').attr('class'):0, //一级告警
|
| | | BattGroupId:$('#BattGroupId').is(':checked')?$('#BattGroupId').attr('class'):0, //二级告警
|
| | | usr_id:$('#usr_id').val(), //在线电压 119001
|
| | | usr_id:$('#usr_id').is(':checked')?$('#usr_id').attr('class'):0, //在线电压 119001
|
| | | fault_type_id:$('#fault_type_id').is(':checked')?$('#fault_type_id').attr('class'):0, //组端电压 119002
|
| | | fault_level:$('#fault_level').is(':checked')?$('#fault_level').attr('class'):0, //充电电流 119003
|
| | | record_uid:$('#record_uid').is(':checked')?$('#record_uid').attr('class'):0, //放电电流 119004
|
| | |
| | | Record_Id:$('#Record_Id').val() //容量更换告警
|
| | | }
|
| | | };
|
| | | //console.info(temp);
|
| | | return temp;
|
| | | }
|
| | |
|
| | | var isNewLoad = true;
|
| | | // 省-市-机房-电池组
|
| | | var filterLoad;
|
| | | $(document).ready(function(){
|
| | | filterLoad = layer.load();
|
| | | var pre_province = getQueryString('province');
|
| | | //页面加载时查询维护区中的枢纽类型
|
| | | $.post("User_battgroup_baojigroup_battgroupAction!serchStationName1InGroup",null,function(data){
|
| | | data=data.result;
|
| | |
| | | }else{
|
| | | $option.text(data.data[i-1]);
|
| | | $option.attr("value",data.data[i-1]);
|
| | | if(pre_province == data.data[i-1] && isNewLoad){
|
| | | $option.attr('selected',true);
|
| | | }
|
| | | }
|
| | | $select.append($option);
|
| | | }
|
| | | }else{
|
| | | $("#station_name1").text('').html('<option>暂无管理的维护区</option>');
|
| | | }
|
| | | findStationNamebyStationname1(); |
| | | findCity(); |
| | | });
|
| | | });
|
| | |
|
| | | //当维护区的值变换时更新机房站点
|
| | | // 根据维护区的内容查询市
|
| | | function findCity(isLoad) {
|
| | | var data = {
|
| | | StationName1: $("#station_name1").val()
|
| | | };
|
| | | // 是否添加等待
|
| | | if(isLoad) {
|
| | | filterLoad = layer.load();
|
| | | }
|
| | | var pre_city = getQueryString("city");
|
| | | // 请求获取当前省下的市
|
| | | $.ajax({ |
| | | type: "post", |
| | | url: "BattInfAction!serchStationName2", |
| | | async:true, |
| | | dataType:'json',
|
| | | data:"json = "+JSON.stringify(data), |
| | | success: function(data){
|
| | | var rs = JSON.parse(data.result);
|
| | | var $select = $("#city");
|
| | | if(rs.code == 1) {
|
| | | var _data= rs.data;
|
| | | // 根据数据构造生成下拉列表的数据
|
| | | var optsList = [];
|
| | | for(var i=0;i<_data.length;i++){
|
| | | var __data = _data[i];
|
| | | var tmp = getOptionsData(__data.StationName2, __data.StationName2, __data);
|
| | | if(pre_city == __data.StationName2 && isNewLoad){
|
| | | tmp = getOptionsData(__data.StationName2, __data.StationName2, __data,{},true);
|
| | | }
|
| | | optsList.push(tmp);
|
| | | }
|
| | | // 根据数据生成下拉列表
|
| | | createOptions($select, optsList, true);
|
| | | }else {
|
| | | $select.text('').html('<option>暂无可测市</option>');
|
| | | }
|
| | | findCounty();
|
| | | }
|
| | | });
|
| | | }
|
| | | |
| | | // 查询区/县
|
| | | function findCounty(isLoad) {
|
| | | var tmp = {
|
| | | StationName1:$("#station_name1").val(),
|
| | | StationName2:$("#city").val(),
|
| | | };
|
| | | // 是否添加等待
|
| | | if(isLoad) {
|
| | | filterLoad = layer.load();
|
| | | }
|
| | | var pre_county = getQueryString('county');
|
| | | // 查询区县
|
| | | $.ajax({
|
| | | type: 'post',
|
| | | async: true,
|
| | | url: "BattInfAction!serchStationName5",
|
| | | data: "json="+JSON.stringify(tmp),
|
| | | success:function(data) {
|
| | | var rs = JSON.parse(data.result);
|
| | | var $select = $("#county");
|
| | | if(rs.code==1){
|
| | | var _data = rs.data;
|
| | | // 根据数据构造生成下拉列表的数据
|
| | | var optsList = [];
|
| | | for(var i=0;i<_data.length;i++){
|
| | | var __data = _data[i];
|
| | | var _attr = {
|
| | | StationId: __data.StationId
|
| | | };
|
| | | var tmp = getOptionsData(__data.StationName5, __data.StationName5, __data, _attr);
|
| | | if(pre_county == __data.StationName5 && isNewLoad){
|
| | | tmp = getOptionsData(__data.StationName5, __data.StationName5, __data, _attr,{},true);
|
| | | }
|
| | | optsList.push(tmp);
|
| | | }
|
| | | |
| | | // 根据数据生成下拉列表
|
| | | createOptions($select, optsList, true);
|
| | | }else{
|
| | | $select.text('').html('<option>暂无可测机房站点</option>');
|
| | | }
|
| | | findStationNamebyStationname1();
|
| | | }
|
| | | });
|
| | | }
|
| | | |
| | | //当维护区的值变换时更新市
|
| | | $('#station_name1').change(function(){
|
| | | findStationNamebyStationname1();
|
| | | findCity(true);
|
| | | });
|
| | |
|
| | | var isNewload = true;
|
| | | //根据维护区查询站点
|
| | | //当维护区的值变换时更新机房站点
|
| | | $('#city').change(function(){
|
| | | findCounty(true);
|
| | | });
|
| | | |
| | | //当区/县的值变换时更新机房站点
|
| | | $('#county').change(function(){
|
| | | findStationNamebyStationname1(true);
|
| | | });
|
| | | |
| | | //根据省,市查询站点
|
| | | function findStationNamebyStationname1(){
|
| | | var user = {
|
| | | UNote:$("#station_name1 option:selected").val()
|
| | | var tmp = {
|
| | | StationName1:$("#station_name1").val(),
|
| | | StationName2:$("#city").val(),
|
| | | StationName5:$("#county").val()
|
| | | };
|
| | | var stationid = getQueryString("stationId");
|
| | | var pre_home = getQueryString('home');
|
| | | //var selectvalue=$("#station_name1 option:selected").val();
|
| | | //alert(selectvalue);
|
| | | $.post("User_battgroup_baojigroup_battgroupAction!serchStationNameInGroup","json="+JSON.stringify(user),function(data){
|
| | | //console.info(data);
|
| | | data=data.result;
|
| | | data=eval("("+data+")");
|
| | | if(data.code==1 && data.data.length>0){
|
| | | $.post("BattInfAction!serchStationName3","json="+JSON.stringify(tmp),function(data){
|
| | | var rs = JSON.parse(data.result);
|
| | | if(rs.code==1){
|
| | | var _data = rs.data;
|
| | | var $select = $("#station_name");
|
| | | $select.text('');
|
| | | for(var i=0;i<=data.data.length;i++){
|
| | | var $option=$("<option></option>");
|
| | | if(i==0){
|
| | | $option.html("<s:text name='All'/>(<s:text name='Common'/>"+data.data.length+"<s:text name='Species'/>)"); |
| | | $option.attr("value", ""); |
| | | }else{
|
| | | $option.text(data.data[i-1]);
|
| | | $option.attr("value",data.data[i-1]);
|
| | | if(stationid!=undefined && stationid == data.data[i-1].StationId && isNewload){
|
| | | $option.attr("selected",true);
|
| | | isNewload = false;
|
| | | } |
| | | } |
| | | $select.append($option);
|
| | | // 根据数据构造生成下拉列表的数据
|
| | | var optsList = [];
|
| | | for(var i=0;i<_data.length;i++){
|
| | | var __data = _data[i];
|
| | | var _attr = {
|
| | | StationId: __data.StationId
|
| | | };
|
| | | var tmp = getOptionsData(__data.StationName3, __data.StationName, __data, _attr);
|
| | | if(pre_home == __data.StationName && isNewLoad){
|
| | | tmp = getOptionsData(__data.StationName3, __data.StationName, __data, _attr,{},true);
|
| | | }
|
| | | optsList.push(tmp);
|
| | | }
|
| | | |
| | | // 根据数据生成下拉列表
|
| | | createOptions($select, optsList, false);
|
| | | }else{
|
| | | $("#station_name").text('').html('<option>暂无管理的机房站点</option>');
|
| | | $("#station_name").text('').html('<option>暂无可测机房站点</option>');
|
| | | }
|
| | | findserchByBattGroupNamebystationname();
|
| | | });
|
| | | }
|
| | |
|
| | | // 根据机房名称查询电池组
|
| | | $('#station_name').change(function(){
|
| | | findserchByBattGroupNamebystationname();
|
| | | findserchByBattGroupNamebystationname(true);
|
| | | });
|
| | |
|
| | | //根据维护区和机房查询蓄电池组
|
| | | function findserchByBattGroupNamebystationname(){
|
| | | var user = {
|
| | | UNote:$("#station_name1 option:selected").val(),
|
| | | UName:$("#station_name option:selected").val()
|
| | | //根据省,市和机房查询蓄电池组
|
| | | function findserchByBattGroupNamebystationname(isLoad){
|
| | | var stationid = $("#station_name").find('option:selected').attr('stationid')?$("#station_name").find('option:selected').attr('stationid'):'';
|
| | | // 构造查询条件
|
| | | var tmp = {
|
| | | StationName1:$("#station_name1").val(),
|
| | | StationName2:$("#city").val(),
|
| | | StationName5:$("#county").val(),
|
| | | StationName: $("#station_name").val(),
|
| | | StationId: stationid
|
| | | };
|
| | | |
| | | // 是否添加等待
|
| | | if(isLoad) {
|
| | | filterLoad = layer.load();
|
| | | }
|
| | | //var station_name1=$("#station_name1 option:selected").val();
|
| | | //var station_name=$("#station_name option:selected").val();
|
| | | |
| | | $.post("User_battgroup_baojigroup_battgroupAction!serchBattgroupidInGroup","json="+JSON.stringify(user),function(data){
|
| | | var pre_battid = getQueryString('battid');
|
| | | $.post("BattInfAction!serchBattByStation","json="+JSON.stringify(tmp),function(data){
|
| | | data=data.result;
|
| | | //console.info(data);
|
| | | data=eval("("+data+")");
|
| | | //console.info(data);
|
| | | if(data.code==1 && data.data.length>0){
|
| | | var $select = $("#battgroup_name");
|
| | | $select.text('');
|
| | | for(var i=0;i<=data.data.length;i++){
|
| | | $option=$("<option></option>");
|
| | | if(i!=0){
|
| | | $option.text(data.data[i-1].BattGroupName+"-"+data.data[i-1].MonCount+"<s:text name='Section'/>");
|
| | | $option.attr("value",data.data[i-1].BattGroupId);
|
| | | $option.attr("stationname",data.data[i-1].StationName);
|
| | | }else{
|
| | | $option.html("<s:text name='All'/>(<s:text name='Common'/>"+data.data.length+"<s:text name='Species'/>)");
|
| | | $option.attr("value", "0");
|
| | | // 根据数据构造生成下拉列表的数据
|
| | | var optsList = [];
|
| | | for(var i=0;i<data.data.length;i++){
|
| | | var _data = data.data[i];
|
| | | var _attr = {
|
| | | stationname: _data.StationName,
|
| | | dev_id: _data.FBSDeviceId,
|
| | | batt_num: _data.GroupIndexInFBSDevice+1
|
| | | };
|
| | | var txt = _data.BattGroupName+'-'+_data.MonCount+"<s:text name='Section'/>";
|
| | | var tmp = getOptionsData(txt, _data.BattGroupId, _data, _attr);
|
| | | if(pre_battid == _data.BattGroupId && isNewLoad){
|
| | | tmp = getOptionsData(txt, _data.BattGroupId, _data, _attr,{},true);
|
| | | }
|
| | | $select.append($option);
|
| | | optsList.push(tmp);
|
| | | }
|
| | | searchHistalm(); //加载完电池组就查询告警
|
| | | |
| | | // 根据数据生成下拉列表
|
| | | createOptions($select, optsList, true);
|
| | | $select.find('option').eq(0).val(0);
|
| | | |
| | | //searchHistalm(); // 查询历史告警
|
| | | }else{
|
| | | $("#battgroup_name").text('').html('<option>暂无管理的蓄电池组</option>');
|
| | | $("#battgroup_name").text('').html('<option>暂无可测蓄电池组</option>');
|
| | | }
|
| | | isNewLoad = false;
|
| | | layer.close(filterLoad);
|
| | | });
|
| | | }
|
| | |
|
| | | |
| | | /* $(function(){
|
| | | //页面加载时查询维护区中的枢纽类型
|
| | | $.post("BattInfAction_serchByStation",null,function(data) {
|
| | | data = data.result;
|
| | | data = eval("(" + data + ")");
|
| | | //console.info(data);
|
| | | if (data.code == 1 && data.data.length > 0) {
|
| | | var $select = $("#station_name1");
|
| | | $select.text('');
|
| | | for ( var i = 0; i <= data.data.length; i++) {
|
| | | var $option = $("<option></option>");
|
| | | if (i == 0) {
|
| | | $option.html("<s:text name='All'/>(<s:text name='Common'/>"+ data.sum+ "<s:text name='Species'/>)");
|
| | | $option.val("");
|
| | | } else {
|
| | | $option.text(data.data[i - 1].StationName1);
|
| | | $option.val(data.data[i - 1].StationName1);
|
| | | }
|
| | | $select.append($option);
|
| | | }
|
| | | }
|
| | | findStationNamebyStationname1();
|
| | | });
|
| | | |
| | | //当维护区的值变换时更新机房站点
|
| | | $('#station_name1').change(function() {
|
| | | findStationNamebyStationname1();
|
| | | });
|
| | | });
|
| | | |
| | | //根据维护区查询站点
|
| | | function findStationNamebyStationname1() {
|
| | | var stationid = getQueryString("stationId");
|
| | | var selectvalue = $("#station_name1 option:selected").val();
|
| | | //alert(selectvalue);
|
| | | $.post("BattInfAction_serchByStationName", "bif.StationName1="+ selectvalue, function(data) {
|
| | | //console.info(data);
|
| | | data = data.result;
|
| | | data = eval("(" + data + ")");
|
| | | if (data.code == 1 && data.data.length > 0) {
|
| | | var $select = $("#station_name");
|
| | | $select.text('');
|
| | | for ( var i = 0; i <= data.data.length; i++) {
|
| | | $option = $("<option></option>");
|
| | | if (i == 0) {
|
| | | $option.text("<s:text name='All'/>(<s:text name='Common'/>" + data.sum + "<s:text name='Species'/>)");
|
| | | $option.attr("value", "");
|
| | | } else {
|
| | | $option.text( data.data[i-1].StationName);
|
| | | $option.attr("value",data.data[i-1].StationName); |
| | | if(stationid != undefined && stationid == data.data[i-1].StationId){
|
| | | $option.attr("selected",true);
|
| | | }
|
| | | }
|
| | | $select.append($option);
|
| | | }
|
| | | }
|
| | | findserchByBattGroupNamebystationname();
|
| | | });
|
| | | }
|
| | | |
| | | $('#station_name').change(function() {
|
| | | findserchByBattGroupNamebystationname();
|
| | | });
|
| | | |
| | | //根据维护区和机房查询蓄电池组
|
| | | function findserchByBattGroupNamebystationname() {
|
| | | var station_name1 = $("#station_name1 option:selected").val();
|
| | | var station_name = $("#station_name option:selected").val();
|
| | | if(station_name.length == 0){
|
| | | var $select = $("#battgroup_name");
|
| | | $select.text('');
|
| | | var $option = $("<option></option>");
|
| | | $option.html("<s:text name='All'/>");
|
| | | $option.attr("value", "0");
|
| | | $select.append($option);
|
| | | searchHistalm();
|
| | | }else{
|
| | | $.post("BattInfAction_serchByBattGroupName","bif.StationName1=" + station_name1 + "&bif.StationName=" + station_name,function(data) {
|
| | | data = data.result;
|
| | | //console.info(data);
|
| | | data = eval("(" + data + ")");
|
| | | //console.info(data.data); |
| | | if (data.code == 1 && data.data.length > 0) {
|
| | | |
| | | var $select = $("#battgroup_name");
|
| | | $select.text('');
|
| | | |
| | | for ( var i = 0; i <= data.data.length; i++) {
|
| | | $option = $("<option></option>");
|
| | | if (i != 0) {
|
| | | $option.text(data.data[i - 1].BattGroupName+ "-"+ data.data[i - 1].MonCount+ "<s:text name='Section'/>");
|
| | | $option.attr("value",data.data[i - 1].BattGroupId);
|
| | | } else {
|
| | | //option.innerHTML = "全部蓄电池组(共" + data.sum + "组)";
|
| | | $option.html("<s:text name='All'/>(<s:text name='Common'/>" + data.sum + "<s:text name='Species'/>)");
|
| | | $option.attr("value", "0");
|
| | | }
|
| | | $select.append($option);
|
| | | }
|
| | | searchHistalm();
|
| | | }
|
| | | });
|
| | | }
|
| | | } */
|
| | | |
| | | // 更新电池组名称查询历史告警
|
| | | $('#battgroup_name').on("change",function(){
|
| | | searchHistalm();
|
| | | });
|