Merge branch 'dev_lxw' of https://whyclj@gitlab.com/whyclxw1/gx_tieta.git into dev_lxw
| | |
| | | function searchBattLife(isLoad){
|
| | | var temp = createSearchParam();
|
| | | var json = JSON.stringify(temp);
|
| | | var arrTd = new Array();
|
| | | arrTd = new Array();
|
| | | var load;
|
| | | if(isLoad) {
|
| | | load = layer.load(1);
|
| | |
| | | Page.pageAll = data[data.length-1].page.pageAll;
|
| | | var pageNum=Math.ceil(Page.pageAll/Page.pageSize);
|
| | | $('#total').text(Page.pageAll);
|
| | | $('#current').text(Page.pageCurr+"/"+pageNum);
|
| | | createAllTbl(tblHd, tblBd, arrTh, arrTd, tblStatus);
|
| | | $('#current').text(Page.pageCurr+"/"+pageNum); |
| | | }
|
| | | |
| | | }
|
| | | createAllTbl(tblHd, tblBd, arrTh, arrTd, tblStatus); |
| | | } |
| | | });
|
| | | |
| | | }
|
| | | //首页
|
| | | $('#home').click(function(){
|
| | |
| | | <link rel="stylesheet" type="text/css" href="css/dischargeplan_layout.css">
|
| | | <link rel="stylesheet" type="text/css" href="css/progress.css">
|
| | | <link rel="stylesheet" type="text/css" href="css/popup.css">
|
| | | |
| | | <link href="src/css/layui.css" type="text/css" rel="stylesheet">
|
| | | <!-- 导入Echarts的js包 -->
|
| | | <script type="text/javascript" src="js/echarts.js"></script>
|
| | | <!-- 导入frame.js -->
|
| | |
| | | <tr class="fWeight">
|
| | | <td>省</td> <!-- 省 -->
|
| | | <td>市</td> <!-- 市 -->
|
| | | <td>区/县</td> <!-- 区/县 -->
|
| | | <td><s:text name="Computer_site"/></td> <!-- 机房站点(或机房设备) -->
|
| | | <td><s:text name="Battery"/></td> <!-- 蓄电池组 -->
|
| | | <td><s:text name="Test"/><s:text name="Status"/></td> <!-- 测试状态 -->
|
| | |
| | | <select id="city" name="station_name2"></select>
|
| | | </td>
|
| | | <td>
|
| | | <select id="station_name" name="station_name">
|
| | | |
| | | </select>
|
| | | <select id="county" name="station_name5"></select>
|
| | | </td>
|
| | | <td>
|
| | | <select id="battgroup_name" name="battgroup_name">
|
| | | |
| | | </select>
|
| | | <select id="station_name" name="station_name"></select>
|
| | | </td>
|
| | | <td>
|
| | | <select id="battgroup_name" name="battgroup_name"></select>
|
| | | </td>
|
| | | <td>
|
| | | <select id="discharge-state" name="discharge-state">
|
| | |
| | | <script type="text/javascript" src="js/popup.js"></script>
|
| | | <!-- 导入Jquery -->
|
| | | <script type="text/javascript" src="js/jquery-ui.js"></script>
|
| | | <script type="text/javascript" src="src/layui.all.js"></script>
|
| | | <script type="text/javascript">
|
| | | var Page = {
|
| | | pageSize:10, //每页的行数
|
| | |
| | |
|
| | | var formjson;
|
| | | function searchDischarge(){
|
| | | loading.showLoading(); |
| | | var load = layer.load(1); |
| | | var jsontemp = $('#search_form').serialize();
|
| | | if(formjson != jsontemp){
|
| | | Page.pageCurr = 1;
|
| | |
| | | async:true,
|
| | | dataType:'text',
|
| | | data:"json="+json,
|
| | | success: function(data){ |
| | | success: function(data){
|
| | | arrTd = new Array();
|
| | | data = eval('('+data+')');
|
| | | var model = eval('('+data.result+')');
|
| | |
| | | $('#page_num').val(Page.pageCurr);
|
| | | //console.info(arrTd);
|
| | | changeTblByStatus();
|
| | | loading.hideLoading(); |
| | | layer.close(load); |
| | | }
|
| | | }).error(function(){
|
| | | noContent.showNoContent("<s:text name='Search'/><s:text name='Fail'/>,<s:text name='Please'/><s:text name='Examine'/><s:text name='Network'/><s:text name='Connect'/>!"); //查询失败,请检查网络连接
|
| | | loading.hideLoading();
|
| | | layer.close(load);
|
| | | });
|
| | | }
|
| | |
|
| | |
| | | $('#end-discharge-end-date').val(new Date().format('yyyy-MM-dd'));
|
| | |
|
| | | // 省-市-机房-电池组
|
| | | var filterLoad;
|
| | | $(document).ready(function(){
|
| | | filterLoad = layer.load();
|
| | | //页面加载时查询维护区中的枢纽类型
|
| | | $.post("User_battgroup_baojigroup_battgroupAction!serchStationName1InGroup",null,function(data){
|
| | | data=data.result;
|
| | |
| | | });
|
| | |
|
| | | // 根据维护区的内容查询市
|
| | | function findCity() {
|
| | | function findCity(isLoad) {
|
| | | var data = {
|
| | | StationName1: $("#station_name1").val()
|
| | | };
|
| | | // 是否添加等待
|
| | | if(isLoad) {
|
| | | filterLoad = layer.load();
|
| | | }
|
| | | // 请求获取当前省下的市
|
| | | $.ajax({
|
| | | type: "post",
|
| | |
| | | }else {
|
| | | $select.text('').html('<option>暂无可测市</option>');
|
| | | }
|
| | | findStationNamebyStationname1();
|
| | | findCounty();
|
| | | }
|
| | | });
|
| | | }
|
| | |
|
| | | // 查询区/县
|
| | | function findCounty(isLoad) {
|
| | | var tmp = {
|
| | | StationName1:$("#station_name1").val(),
|
| | | StationName2:$("#city").val(),
|
| | | };
|
| | | // 是否添加等待
|
| | | if(isLoad) {
|
| | | filterLoad = layer.load();
|
| | | }
|
| | | // 查询区县
|
| | | $.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);
|
| | | 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();
|
| | | }
|
| | | // 查询区县
|
| | | $.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);
|
| | | optsList.push(tmp);
|
| | | }
|
| | | |
| | | // 根据数据生成下拉列表
|
| | | createOptions($select, optsList, true);
|
| | | }else{
|
| | | $select.text('').html('<option>暂无可测机房站点</option>');
|
| | | }
|
| | | findStationNamebyStationname1();
|
| | | }
|
| | | });
|
| | | }
|
| | | |
| | | //当维护区的值变换时更新市
|
| | | $('#station_name1').change(function(){
|
| | | findCity();
|
| | | findCity(true);
|
| | | });
|
| | |
|
| | | //当维护区的值变换时更新机房站点
|
| | | $('#city').change(function(){
|
| | | findStationNamebyStationname1();
|
| | | findCounty(true);
|
| | | });
|
| | | |
| | | //当区/县的值变换时更新机房站点
|
| | | $('#county').change(function(){
|
| | | findStationNamebyStationname1(true);
|
| | | });
|
| | |
|
| | | //根据省,市查询站点
|
| | | function findStationNamebyStationname1(){
|
| | | function findStationNamebyStationname1(isLoad){
|
| | | var tmp = {
|
| | | StationName1:$("#station_name1").val(),
|
| | | StationName2:$("#city").val()
|
| | | StationName2:$("#city").val(),
|
| | | StationName5:$("#county").val()
|
| | | };
|
| | | // 是否添加等待
|
| | | if(isLoad) {
|
| | | filterLoad = layer.load();
|
| | | }
|
| | | //var selectvalue=$("#station_name1 option:selected").val();
|
| | | //alert(selectvalue);
|
| | | $.post("BattInfAction!serchStationName3","json="+JSON.stringify(tmp),function(data){
|
| | |
| | |
|
| | | // 根据机房名称查询电池组
|
| | | $('#station_name').change(function(){
|
| | | findserchByBattGroupNamebystationname();
|
| | | findserchByBattGroupNamebystationname(true);
|
| | | });
|
| | |
|
| | | //根据省,市和机房查询蓄电池组
|
| | | function findserchByBattGroupNamebystationname(){
|
| | | 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();
|
| | | }
|
| | | $.post("BattInfAction!serchBattByStation","json="+JSON.stringify(tmp),function(data){
|
| | | data=data.result;
|
| | | //console.info(data);
|
| | |
| | | }else{
|
| | | $("#battgroup_name").text('').html('<option>暂无可测蓄电池组</option>');
|
| | | }
|
| | | |
| | | layer.close(filterLoad);
|
| | | });
|
| | | }
|
| | |
|
| | |
| | | var temp = {
|
| | | binf:{
|
| | | StationName:$('#station_name').val(),
|
| | | StationName5:$('#county').val(),
|
| | | StationName2:$('#city').val(),
|
| | | StationName1:$('#station_name1').val(),
|
| | | BattGroupId:$('#battgroup_name').val(),
|
| | |
| | | StationName:$('#station_name').val(),
|
| | | StationName2:$('#city').val(),
|
| | | StationName1:$('#station_name1').val(),
|
| | | StationNmae5:$('#county').val(),
|
| | | StationName5:$('#county').val(),
|
| | | BattGroupId:$('#battgroup_name').val(),
|
| | | BattProducer:$('#producer').val(),
|
| | | BattInUseDate:$('#startinusedate').val()+" 00:00:00",
|
| | |
| | | put("devalarm","home_warn.gif");
|
| | | put("precharge","home_warn.gif");
|
| | | put("onlinecharge","home_warn.gif");
|
| | | put("poff","poff.gif");
|
| | | put("install","install.gif");
|
| | | }
|
| | | };
|
| | |
|
| | |
| | | uc.setChart_pre_charge(files.get(i));
|
| | | }else if("onlinecharge".equals(ftype.get(i))){
|
| | | uc.setChart_online_charge(files.get(i));
|
| | | }else if("poff".equals(ftype.get(i))){
|
| | | uc.setChart_poff(files.get(i));
|
| | | }else if("install".equals(ftype.get(i))){
|
| | | uc.setChart_install(files.get(i));
|
| | | }
|
| | |
|
| | | }
|
New file |
| | |
| | | package com.fgkj.actions.ram;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | import com.fgkj.actions.ActionUtil;
|
| | | import com.fgkj.dao.FBS9100_ComBase;
|
| | | import com.fgkj.dao.UinfDaoFactory;
|
| | | import com.fgkj.dto.BattInf;
|
| | | import com.fgkj.dto.ServiceModel;
|
| | | import com.fgkj.dto.User_log;
|
| | | import com.fgkj.dto.ram.Fbs9100_setparam;
|
| | | import com.fgkj.dto.ram.Fbs9100_sysparam;
|
| | | import com.fgkj.services.User_logService;
|
| | | import com.fgkj.services.ram.Fbs9100_sysparamService;
|
| | | import com.google.gson.reflect.TypeToken;
|
| | |
|
| | | public class Fbs9100_sysparamAction extends ActionUtil{
|
| | | private Fbs9100_sysparamService service=new Fbs9100_sysparamService();
|
| | | private User_logService uservice=new User_logService();
|
| | | private String json;
|
| | | private String result;
|
| | | |
| | | //修改系统参数
|
| | | public String update() {
|
| | | Fbs9100_sysparam sys = getGson().fromJson(json, Fbs9100_sysparam.class);
|
| | | ServiceModel model = service.update(sys);
|
| | | { String msg="";
|
| | | if(sys.getNum()==FBS9100_ComBase.CMD_SetDischargeParm){
|
| | | msg="修改"+sys.getDev_id()+"的设备放电参数";
|
| | | }else if(sys.getNum()==FBS9100_ComBase.CMD_Start){
|
| | | msg="启动"+sys.getDev_id()+"的设备放电";
|
| | | }else if(sys.getNum()==FBS9100_ComBase.CMD_Stop){
|
| | | msg="停止"+sys.getDev_id()+"的设备放电";
|
| | | }
|
| | | User_log ulog=UinfDaoFactory.CreateULog(UinfDaoFactory.Alter, msg);
|
| | | uservice.add(ulog);//将用户的操作记录下来
|
| | | }
|
| | | result = tojson(model); |
| | | return SUCCESS; |
| | | }
|
| | | //根据设备id查询系统参数(一定是被管理的)
|
| | | public String serchByCondition(){
|
| | | Fbs9100_sysparam sys= getGson().fromJson(json, Fbs9100_sysparam.class);
|
| | | ServiceModel model = service.serchByCondition(sys);
|
| | | result = tojson(model);
|
| | | return SUCCESS;
|
| | | }
|
| | | |
| | | public String getResult() {
|
| | | return result;
|
| | | }
|
| | | public void setJson(String json) {
|
| | | this.json = json;
|
| | | }
|
| | | |
| | | |
| | |
|
| | | }
|
| | |
| | |
|
| | | public static final int STATIONTRAFFIC=95;
|
| | |
|
| | | public static final int FBS9100_SYSPARAM=96;
|
| | | |
| | | public boolean add(Object obj); // 添加
|
| | |
|
| | | public boolean update(Object obj); // 更新
|
| | |
| | | import com.fgkj.dao.impl.ram.Bts_station_stateImpl;
|
| | | import com.fgkj.dao.impl.ram.Fbs9100_setparamImpl;
|
| | | import com.fgkj.dao.impl.ram.Fbs9100_stateImpl;
|
| | | import com.fgkj.dao.impl.ram.Fbs9100_sysparamImpl;
|
| | | import com.fgkj.dao.impl.ram.Fbs9100s_dcdc_stateImpl;
|
| | | import com.fgkj.dao.impl.ram.Fbs9100s_dfu_stateImpl;
|
| | | import com.fgkj.dao.impl.ram.Fbs9600_stateImpl;
|
| | |
| | | case 93:return new Battinf_exImpl();
|
| | | case 94:return new Deverror_recordImpl();
|
| | | case 95:return new StationtrafficImpl();
|
| | | case 96:return new Fbs9100_sysparamImpl();
|
| | | default :return null;
|
| | | }
|
| | | }
|
| | |
| | | //FBS9600S设备内阻测试的启动命令
|
| | | final public static int CMD_9600_Start=1;
|
| | |
|
| | | //系统参数命令
|
| | | public static final int CMD_GetSYSSetParamAck = 0x7E; //126
|
| | | public static final int CMD_SetSYSSetParamAck = 0x7F; //127
|
| | | public static final int CMD_GetSYSSetParam = 0x80;//获取系统参数128
|
| | | public static final int CMD_SetSYSSetParam = 0x81;//设置系统参数129
|
| | | public static final int CMD_ResetSystemAck = 0x0F;//15
|
| | | public static final int CMD_ResetSystem = 0x10;//重启16
|
| | |
|
| | | //6185设备工作状态对应关系workstate
|
| | | final public static int DEV_ONLINE_CHARGE=0; //在线浮充
|
| | |
| | | binf.setBattInUseDate1(ActionUtil.getSimpDate(date2));
|
| | | binf.setStationName1("");
|
| | | binf.setStationName("");
|
| | | binf.setStationName2("");
|
| | | binf.setStationName5("");
|
| | | binf.setBattGroupId(0);
|
| | | binf.setBattProducer("");
|
| | | Page page=new Page();
|
| | |
| | | bmd.setUinf(uinf);
|
| | | List<Batt_Maint_Dealarm> list=bimpl.serchByInfo(bmd);
|
| | | for (Batt_Maint_Dealarm b : list) {
|
| | | System.out.println(b.getBdmon());
|
| | | System.out.println(b);
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | " from db_battinf.tb_battinf " +
|
| | | " left outer join (select * from db_battinf.tb_battinf_rebuild where tb_battinf_rebuild.rebuild_clear_type=1 ) as battinf_re " +
|
| | | " on BattGroupId=battinf_re.new_battgroupid or BattGroupId=battinf_re.old_battgroupid " +
|
| | | " where stationname2 like ? stationname5 like ? ";
|
| | | " where stationname2 like ? and stationname5 like ? ";
|
| | | //用户管理
|
| | | String userSql=" and StationId in(" +
|
| | | " select distinct db_user.tb_user_battgroup_baojigroup_battgroup.StationId from db_user.tb_user_battgroup_baojigroup_battgroup,db_user.tb_user_battgroup_baojigroup_usr where db_user.tb_user_battgroup_baojigroup_battgroup.baoji_group_id=db_user.tb_user_battgroup_baojigroup_usr.baoji_group_id and db_user.tb_user_battgroup_baojigroup_usr.uId=?" +
|
| | |
| | | list.add(uchart.getChart_dev_alarm());
|
| | | list.add(uchart.getChart_pre_charge());
|
| | | list.add(uchart.getChart_online_charge());
|
| | | String sql="insert into web_site.tb_user_Chart(chart_name,chart_file,Chart_logo,Chart_normal,Chart_behind,Chart_warn,Chart_timeout,Chart_nuclear_cap,Chart_dev_alarm,Chart_pre_charge,Chart_online_charge) values(?,?,?,?,?,?,?,?,?,?,?)";
|
| | | list.add(uchart.getChart_poff());
|
| | | list.add(uchart.getChart_install());
|
| | | String sql="insert into web_site.tb_user_Chart(chart_name,chart_file,Chart_logo,Chart_normal,Chart_behind,Chart_warn,Chart_timeout,Chart_nuclear_cap,Chart_dev_alarm,Chart_pre_charge,Chart_online_charge,Chart_poff,Chart_install) values(?,?,?,?,?,?,?,?,?,?,?,?,?)";
|
| | | boolean bl=DAOHelper.executeUpdatePicture(DBUtil.getConn(), sql, list);
|
| | | return bl;
|
| | | }
|
| | |
| | | list.add(uchart.getChart_online_charge());
|
| | | sql+=online_chargeSql;
|
| | | }
|
| | | //Chart_poff图片
|
| | | String poffSql=" Chart_poff=? ";
|
| | | if(uchart.getChart_poff()!=null&&uchart.getChart_poff().length()>0){
|
| | | if(list.size()>0){
|
| | | sql+=",";
|
| | | }
|
| | | list.add(uchart.getChart_poff());
|
| | | sql+=poffSql;
|
| | | }
|
| | | //Chart_install图片
|
| | | String installSql=" Chart_install=? ";
|
| | | if(uchart.getChart_install()!=null&&uchart.getChart_install().length()>0){
|
| | | if(list.size()>0){
|
| | | sql+=",";
|
| | | }
|
| | | list.add(uchart.getChart_install());
|
| | | sql+=installSql;
|
| | | }
|
| | | //endSql
|
| | | String endSql=" where chart_file=?";
|
| | | String endSql=" where chart_file=? ";
|
| | | list.add(uchart.getChart_file());
|
| | | sql+=endSql;
|
| | | //System.out.println(list.size()+" "+sql);
|
| | |
| | | import com.fgkj.dao.UinfDaoFactory;
|
| | | import com.fgkj.db.DBUtil;
|
| | | import com.fgkj.dto.BattInf;
|
| | | import com.fgkj.dto.BattMap_information;
|
| | | import com.fgkj.dto.Page;
|
| | | import com.fgkj.dto.User_inf;
|
| | | import com.fgkj.dto.ram.Bts_station_state;
|
| | |
| | | }
|
| | | return nums;
|
| | | }
|
| | | //查询当前机房停电数(根据station_id )
|
| | | public int serchByStationId(Object obj) {
|
| | | BattMap_information binformation=(BattMap_information) obj;
|
| | | String sql="select count(num) as nums from db_ram_db.tb_bts_station_state " +
|
| | | " where station_stat&2>1 " +
|
| | | " and station_id=? " +
|
| | | " limit 1 ";
|
| | | //System.out.println(sql);
|
| | | List list=DAOHelper.executeQuery(sql, DBUtil.getConn(), new Object[]{binformation.getStationId()}, new CallBack() {
|
| | | |
| | | public List getResults(ResultSet rs) {
|
| | | List list=new ArrayList();
|
| | | try {
|
| | | while(rs.next()){
|
| | | int nums=rs.getInt("nums");
|
| | | list.add(nums);
|
| | | }
|
| | | } catch (SQLException e) {
|
| | | e.printStackTrace();
|
| | | }
|
| | | return list;
|
| | | }
|
| | | });
|
| | | int nums=0;//最后的结果
|
| | | if(list!=null&&list.size()>0){
|
| | | nums=(Integer) list.get(list.size()-1);
|
| | | }
|
| | | return nums;
|
| | | }
|
| | | public List serchByInfo(Object obj) {
|
| | | // TODO Auto-generated method stub
|
| | | return null;
|
| | |
| | | //System.out.println(bs.getStation_stat_diaozhan()+" "+bs.getStation_stat_dooropen()+" "+bs.getStation_stat_fadian()+" "+bs.getStation_stat_xuhang()+" "+bs.getStation_stat_poff());
|
| | | System.out.println(bs);
|
| | | }
|
| | | /*int nums=bimpl.serchByState(uinf);
|
| | | System.out.println(nums);*/
|
| | | /*int nums=bimpl.serchByState(uinf);*/
|
| | | BattMap_information bm=new BattMap_information();
|
| | | bm.setStationId("42000570");
|
| | | int nums=bimpl.serchByStationId(bm);
|
| | | System.out.println(nums);
|
| | | }
|
| | |
|
| | |
|
| | |
| | | case FBS9100_ComBase.CMD_GetDischargeParm: m_cmd_ack = FBS9100_ComBase.CMD_GetDischargeParmAck; break;
|
| | | case FBS9100_ComBase.CMd_SetIp_Tem: m_cmd_ack = FBS9100_ComBase.CMd_SetIpAck; break;
|
| | | case FBS9100_ComBase.CMd_SetIp_Per: m_cmd_ack = FBS9100_ComBase.CMd_SetIpAck; break;
|
| | | case FBS9100_ComBase.CMD_ResetSystem: m_cmd_ack = FBS9100_ComBase.CMD_ResetSystemAck; break;
|
| | | default: return false;
|
| | | }
|
| | | String sql_end = "";
|
New file |
| | |
| | | package com.fgkj.dao.impl.ram;
|
| | |
|
| | | import java.sql.Connection;
|
| | | import java.sql.PreparedStatement;
|
| | | import java.sql.ResultSet;
|
| | | import java.sql.SQLException;
|
| | | import java.util.ArrayList;
|
| | | import java.util.List;
|
| | |
|
| | | import com.fgkj.dao.BaseDAO;
|
| | | import com.fgkj.dao.CallBack;
|
| | | import com.fgkj.dao.DAOHelper;
|
| | | import com.fgkj.dao.FBS9100_ComBase;
|
| | | import com.fgkj.db.DBUtil;
|
| | | import com.fgkj.dto.ram.Fbs9100_sysparam;
|
| | |
|
| | | public class Fbs9100_sysparamImpl implements BaseDAO,CallBack{
|
| | |
|
| | | public List getResults(ResultSet rs) {
|
| | | // TODO Auto-generated method stub
|
| | | return null;
|
| | | }
|
| | | |
| | | public boolean add(Object obj) {
|
| | | // TODO Auto-generated method stub
|
| | | return false;
|
| | | }
|
| | | //修改系统参数
|
| | | public boolean update(Object obj) {
|
| | | Fbs9100_sysparam sys=(Fbs9100_sysparam) obj;
|
| | | String sql=" update db_ram_db.tb_fbs9100_sysparam set IPADDR=?,SubIPADDR=?,NetGateADDR=?,GroupVolRange=?,GroupVolSorce=?,CurrentRange=?,CurrentTyte=?,MonomerOrder=?,BackLightTime=?" +
|
| | | ",MACADDR=?,LoaderCount=?,DtCardCount=?,PowerBreakChargeCurr=?,MajorBattGroupNum=?,POF_BG_Boost_Cnt=?,POF_BG_Boost_VolStop=?,POF_BG_Boost_VolStart=? " +
|
| | | "where dev_id=? ";
|
| | | boolean bl=DAOHelper.executeUpdate(DBUtil.getConn(), sql, new Object[]{sys.getIPADDR(),sys.getSubIPADDR(),sys.getNetGateADDR(),sys.getGroupVolRange(),sys.getGroupVolSorce(),sys.getCurrentRange(),sys.getCurrentTyte(),sys.getMonomerOrder(),sys.getBackLightTime()
|
| | | ,sys.getMACADDR(),sys.getLoaderCount(),sys.getDtCardCount(),sys.getPowerBreakChargeCurr(),sys.getMajorBattGroupNum(),sys.getPOF_BG_Boost_Cnt(),sys.getPOF_BG_Boost_VolStop(),sys.getPOF_BG_Boost_VolStart(),sys.getDev_id()});
|
| | | return bl;
|
| | | }
|
| | |
|
| | | public boolean del(Object obj) {
|
| | | // TODO Auto-generated method stub
|
| | | return false;
|
| | | }
|
| | |
|
| | | public List searchAll() {
|
| | | // TODO Auto-generated method stub
|
| | | return null;
|
| | | }
|
| | | //根据设备id查询系统参数(一定是被管理的)
|
| | | public List serchByCondition(Object obj) {
|
| | | Fbs9100_sysparam sys=(Fbs9100_sysparam) obj;
|
| | | String sql=" select distinct dev_ip,dev_id,op_cmd,IPADDR,SubIPADDR,NetGateADDR,GroupVolRange,GroupVolSorce,CurrentRange,CurrentTyte,MonomerOrder,BackLightTime" +
|
| | | " ,MACADDR,LoaderCount,DtCardCount,PowerBreakChargeCurr,MajorBattGroupNum,POF_BG_Boost_Cnt,POF_BG_Boost_VolStop,POF_BG_Boost_VolStart" +
|
| | | " ,db_battinf.tb_battinf.FBSDeviceName,db_battinf.tb_battinf.StationName " +
|
| | | " from db_ram_db.tb_fbs9100_sysparam,db_battinf.tb_battinf " +
|
| | | " where db_ram_db.tb_fbs9100_sysparam.dev_id=db_battinf.tb_battinf.FBSDeviceId " +
|
| | | " and db_ram_db.tb_fbs9100_sysparam.dev_id=? " ;
|
| | | List list=DAOHelper.executeQuery(sql, DBUtil.getConn(), new Object[]{sys.getDev_id()}, new CallBack() {
|
| | | |
| | | public List getResults(ResultSet rs) {
|
| | | List list=new ArrayList();
|
| | | try {
|
| | | while(rs.next()){
|
| | | Fbs9100_sysparam fbs_sys=new Fbs9100_sysparam();
|
| | | fbs_sys.setDev_ip(rs.getString("dev_ip"));
|
| | | fbs_sys.setDev_id(rs.getInt("dev_id"));
|
| | | fbs_sys.setOp_cmd(rs.getInt("op_cmd"));
|
| | | fbs_sys.setIPADDR(rs.getString("iPADDR"));
|
| | | fbs_sys.setSubIPADDR(rs.getString("subIPADDR"));
|
| | | fbs_sys.setNetGateADDR(rs.getString("netGateADDR"));
|
| | | fbs_sys.setGroupVolRange(rs.getInt("groupVolRange"));
|
| | | fbs_sys.setGroupVolSorce(rs.getInt("groupVolSorce"));
|
| | | fbs_sys.setCurrentRange(rs.getInt("currentRange"));
|
| | | fbs_sys.setCurrentTyte(rs.getInt("currentTyte"));
|
| | | fbs_sys.setMonomerOrder(rs.getInt("monomerOrder"));
|
| | | fbs_sys.setBackLightTime(rs.getInt("backLightTime"));
|
| | | fbs_sys.setMACADDR(rs.getString("mACADDR"));
|
| | | fbs_sys.setLoaderCount(rs.getInt("loaderCount"));
|
| | | fbs_sys.setDtCardCount(rs.getInt("dtCardCount"));
|
| | | fbs_sys.setPowerBreakChargeCurr(rs.getFloat("powerBreakChargeCurr"));
|
| | | fbs_sys.setMajorBattGroupNum(rs.getInt("majorBattGroupNum"));
|
| | | fbs_sys.setPOF_BG_Boost_Cnt(rs.getInt("pOF_BG_Boost_Cnt"));
|
| | | fbs_sys.setPOF_BG_Boost_VolStop(rs.getFloat("pOF_BG_Boost_VolStop"));
|
| | | fbs_sys.setPOF_BG_Boost_VolStart(rs.getFloat("pOF_BG_Boost_VolStart"));
|
| | | fbs_sys.setFBSDeviceName(rs.getString("FBSDeviceName"));
|
| | | fbs_sys.setStationName(rs.getString("stationName"));
|
| | | list.add(fbs_sys);
|
| | | }
|
| | | } catch (SQLException e) {
|
| | | // TODO Auto-generated catch block
|
| | | e.printStackTrace();
|
| | | }
|
| | | |
| | | return list;
|
| | | }
|
| | | });
|
| | | return list;
|
| | | }
|
| | | //系统参数命令操作设备时的cmd和ack校验 |
| | | public boolean sendCmdToFBS9100Dev(int cmd,int dev_id)
|
| | | { |
| | | int m_cmd = cmd;
|
| | | int m_cmd_ack = cmd;
|
| | | switch(m_cmd) {
|
| | | case FBS9100_ComBase.CMD_GetSYSSetParam: m_cmd_ack = FBS9100_ComBase.CMD_GetSYSSetParamAck; break;
|
| | | case FBS9100_ComBase.CMD_SetSYSSetParam: m_cmd_ack = FBS9100_ComBase.CMD_SetSYSSetParamAck; break;
|
| | | default: return false;
|
| | | }
|
| | | boolean res_exe = false;
|
| | | String sql = "UPDATE db_ram_db.tb_fbs9100_sysparam SET "
|
| | | + " op_cmd=? " |
| | | + " WHERE dev_id=? ";
|
| | | Boolean bl=DAOHelper.executeUpdate(DBUtil.getConn(), sql, new Object[]{m_cmd,dev_id});
|
| | | if(true == bl)
|
| | | {
|
| | | sql = "SELECT op_cmd FROM db_ram_db.tb_fbs9100_sysparam "+
|
| | | " WHERE dev_id="+dev_id;
|
| | | Connection conn=DBUtil.getConn();
|
| | | PreparedStatement ps = null;
|
| | | ResultSet rs = null;
|
| | | for(int n=0; n<20; n++)
|
| | | {
|
| | | try {
|
| | | ps = conn.prepareStatement(sql);
|
| | | rs=ps.executeQuery();
|
| | | if(rs.next())
|
| | | {
|
| | | if(rs.getInt("op_cmd") == m_cmd_ack)
|
| | | {
|
| | | res_exe = true;
|
| | | break;
|
| | | }
|
| | | }
|
| | | } catch (SQLException e) {
|
| | | // TODO Auto-generated catch block
|
| | | e.printStackTrace();
|
| | | }
|
| | | |
| | | try {
|
| | | Thread.sleep(250);
|
| | | } catch (InterruptedException e) {
|
| | | // TODO Auto-generated catch block
|
| | | e.printStackTrace();
|
| | | }
|
| | | }
|
| | | DBUtil.close(rs, ps, conn);
|
| | | }
|
| | | return res_exe;
|
| | | }
|
| | | public List serchByInfo(Object obj) {
|
| | | // TODO Auto-generated method stub
|
| | | return null;
|
| | | }
|
| | | |
| | | public static void main(String[] args) {
|
| | | Fbs9100_sysparamImpl fimpl=new Fbs9100_sysparamImpl();
|
| | | Fbs9100_sysparam sys=new Fbs9100_sysparam();
|
| | | sys.setDev_id(910000011);
|
| | | List list=fimpl.serchByCondition(sys);
|
| | | System.out.println(list.size());
|
| | | }
|
| | |
|
| | | }
|
| | |
| | | private File Chart_behind;
|
| | | private File Chart_warn;
|
| | | private File Chart_timeout;
|
| | | private File Chart_poff; //停电
|
| | | private File Chart_install;//未添加的图标
|
| | |
|
| | | private File Chart_nuclear_cap;//核容放电
|
| | | private File Chart_dev_alarm;//设备告警
|
| | |
| | | public void setChart_timeout_blob(Blob chart_timeout_blob) {
|
| | | Chart_timeout_blob = chart_timeout_blob;
|
| | | }
|
| | | public File getChart_poff() {
|
| | | return Chart_poff;
|
| | | }
|
| | | public void setChart_poff(File chart_poff) {
|
| | | Chart_poff = chart_poff;
|
| | | }
|
| | | public File getChart_install() {
|
| | | return Chart_install;
|
| | | }
|
| | | public void setChart_install(File chart_install) {
|
| | | Chart_install = chart_install;
|
| | | }
|
| | | @Override
|
| | | public String toString() {
|
| | | return "User_Chart [num=" + num + ", Chart_name=" + Chart_name
|
| | | + ", Chart_file=" + Chart_file + ", Chart_logo=" + Chart_logo
|
| | | + ", Chart_normal=" + Chart_normal + ", Chart_behind="
|
| | | + Chart_behind + ", Chart_warn=" + Chart_warn
|
| | | + ", Chart_timeout=" + Chart_timeout + ", Chart_nuclear_cap="
|
| | | + Chart_nuclear_cap + ", Chart_dev_alarm=" + Chart_dev_alarm
|
| | | + ", Chart_timeout=" + Chart_timeout + ", Chart_poff="
|
| | | + Chart_poff + ", Chart_install=" + Chart_install
|
| | | + ", Chart_nuclear_cap=" + Chart_nuclear_cap
|
| | | + ", Chart_dev_alarm=" + Chart_dev_alarm
|
| | | + ", Chart_pre_charge=" + Chart_pre_charge
|
| | | + ", Chart_online_charge=" + Chart_online_charge
|
| | | + ", Chart_logo_blob=" + Chart_logo_blob
|
| | |
| | | }
|
| | |
|
| | |
|
| | | |
| | | }
|
New file |
| | |
| | | package com.fgkj.dto.ram;
|
| | |
|
| | | import java.io.Serializable;
|
| | |
|
| | | public class Fbs9100_sysparam implements Serializable{
|
| | | private int num;
|
| | | private String dev_ip;
|
| | | private int dev_id;
|
| | | private int op_cmd;
|
| | | private String IPADDR;
|
| | | private String SubIPADDR;
|
| | | private String NetGateADDR;
|
| | | private int GroupVolRange;
|
| | | private int GroupVolSorce;
|
| | | private int CurrentRange;
|
| | | private int CurrentTyte;
|
| | | private int MonomerOrder;
|
| | | private int BackLightTime;
|
| | | private String MACADDR;
|
| | | private int LoaderCount;
|
| | | private int DtCardCount;
|
| | | private float PowerBreakChargeCurr;
|
| | | private int MajorBattGroupNum;
|
| | | private int POF_BG_Boost_Cnt;
|
| | | private float POF_BG_Boost_VolStop;
|
| | | private float POF_BG_Boost_VolStart;
|
| | | private String stationName;
|
| | | private String FBSDeviceName;
|
| | | private String note;
|
| | | public int getNum() {
|
| | | return num;
|
| | | }
|
| | | public void setNum(int num) {
|
| | | this.num = num;
|
| | | }
|
| | | public String getDev_ip() {
|
| | | return dev_ip;
|
| | | }
|
| | | public void setDev_ip(String dev_ip) {
|
| | | this.dev_ip = dev_ip;
|
| | | }
|
| | | public int getDev_id() {
|
| | | return dev_id;
|
| | | }
|
| | | public void setDev_id(int dev_id) {
|
| | | this.dev_id = dev_id;
|
| | | }
|
| | | public int getOp_cmd() {
|
| | | return op_cmd;
|
| | | }
|
| | | public void setOp_cmd(int op_cmd) {
|
| | | this.op_cmd = op_cmd;
|
| | | }
|
| | | public String getIPADDR() {
|
| | | return IPADDR;
|
| | | }
|
| | | public void setIPADDR(String iPADDR) {
|
| | | IPADDR = iPADDR;
|
| | | }
|
| | | public String getSubIPADDR() {
|
| | | return SubIPADDR;
|
| | | }
|
| | | public void setSubIPADDR(String subIPADDR) {
|
| | | SubIPADDR = subIPADDR;
|
| | | }
|
| | | public String getNetGateADDR() {
|
| | | return NetGateADDR;
|
| | | }
|
| | | public void setNetGateADDR(String netGateADDR) {
|
| | | NetGateADDR = netGateADDR;
|
| | | }
|
| | | public int getGroupVolRange() {
|
| | | return GroupVolRange;
|
| | | }
|
| | | public void setGroupVolRange(int groupVolRange) {
|
| | | GroupVolRange = groupVolRange;
|
| | | }
|
| | | public int getGroupVolSorce() {
|
| | | return GroupVolSorce;
|
| | | }
|
| | | public void setGroupVolSorce(int groupVolSorce) {
|
| | | GroupVolSorce = groupVolSorce;
|
| | | }
|
| | | public int getCurrentRange() {
|
| | | return CurrentRange;
|
| | | }
|
| | | public void setCurrentRange(int currentRange) {
|
| | | CurrentRange = currentRange;
|
| | | }
|
| | | public int getCurrentTyte() {
|
| | | return CurrentTyte;
|
| | | }
|
| | | public void setCurrentTyte(int currentTyte) {
|
| | | CurrentTyte = currentTyte;
|
| | | }
|
| | | public int getMonomerOrder() {
|
| | | return MonomerOrder;
|
| | | }
|
| | | public void setMonomerOrder(int monomerOrder) {
|
| | | MonomerOrder = monomerOrder;
|
| | | }
|
| | | public int getBackLightTime() {
|
| | | return BackLightTime;
|
| | | }
|
| | | public void setBackLightTime(int backLightTime) {
|
| | | BackLightTime = backLightTime;
|
| | | }
|
| | | public String getMACADDR() {
|
| | | return MACADDR;
|
| | | }
|
| | | public void setMACADDR(String mACADDR) {
|
| | | MACADDR = mACADDR;
|
| | | }
|
| | | public int getLoaderCount() {
|
| | | return LoaderCount;
|
| | | }
|
| | | public void setLoaderCount(int loaderCount) {
|
| | | LoaderCount = loaderCount;
|
| | | }
|
| | | public int getDtCardCount() {
|
| | | return DtCardCount;
|
| | | }
|
| | | public void setDtCardCount(int dtCardCount) {
|
| | | DtCardCount = dtCardCount;
|
| | | }
|
| | | public float getPowerBreakChargeCurr() {
|
| | | return PowerBreakChargeCurr;
|
| | | }
|
| | | public void setPowerBreakChargeCurr(float powerBreakChargeCurr) {
|
| | | PowerBreakChargeCurr = powerBreakChargeCurr;
|
| | | }
|
| | | public int getMajorBattGroupNum() {
|
| | | return MajorBattGroupNum;
|
| | | }
|
| | | public void setMajorBattGroupNum(int majorBattGroupNum) {
|
| | | MajorBattGroupNum = majorBattGroupNum;
|
| | | }
|
| | | public int getPOF_BG_Boost_Cnt() {
|
| | | return POF_BG_Boost_Cnt;
|
| | | }
|
| | | public void setPOF_BG_Boost_Cnt(int pOF_BG_Boost_Cnt) {
|
| | | POF_BG_Boost_Cnt = pOF_BG_Boost_Cnt;
|
| | | }
|
| | | public float getPOF_BG_Boost_VolStop() {
|
| | | return POF_BG_Boost_VolStop;
|
| | | }
|
| | | public void setPOF_BG_Boost_VolStop(float pOF_BG_Boost_VolStop) {
|
| | | POF_BG_Boost_VolStop = pOF_BG_Boost_VolStop;
|
| | | }
|
| | | public float getPOF_BG_Boost_VolStart() {
|
| | | return POF_BG_Boost_VolStart;
|
| | | }
|
| | | public void setPOF_BG_Boost_VolStart(float pOF_BG_Boost_VolStart) {
|
| | | POF_BG_Boost_VolStart = pOF_BG_Boost_VolStart;
|
| | | }
|
| | | public String getStationName() {
|
| | | return stationName;
|
| | | }
|
| | | public void setStationName(String stationName) {
|
| | | this.stationName = stationName;
|
| | | }
|
| | | |
| | | public String getNote() {
|
| | | return note;
|
| | | }
|
| | | public void setNote(String note) {
|
| | | this.note = note;
|
| | | }
|
| | | public String getFBSDeviceName() {
|
| | | return FBSDeviceName;
|
| | | }
|
| | | public void setFBSDeviceName(String fBSDeviceName) {
|
| | | FBSDeviceName = fBSDeviceName;
|
| | | }
|
| | | @Override
|
| | | public String toString() {
|
| | | return "Fbs9100_sysparam [num=" + num + ", dev_ip=" + dev_ip
|
| | | + ", dev_id=" + dev_id + ", op_cmd=" + op_cmd + ", IPADDR="
|
| | | + IPADDR + ", SubIPADDR=" + SubIPADDR + ", NetGateADDR="
|
| | | + NetGateADDR + ", GroupVolRange=" + GroupVolRange
|
| | | + ", GroupVolSorce=" + GroupVolSorce + ", CurrentRange="
|
| | | + CurrentRange + ", CurrentTyte=" + CurrentTyte
|
| | | + ", MonomerOrder=" + MonomerOrder + ", BackLightTime="
|
| | | + BackLightTime + ", MACADDR=" + MACADDR + ", LoaderCount="
|
| | | + LoaderCount + ", DtCardCount=" + DtCardCount
|
| | | + ", PowerBreakChargeCurr=" + PowerBreakChargeCurr
|
| | | + ", MajorBattGroupNum=" + MajorBattGroupNum
|
| | | + ", POF_BG_Boost_Cnt=" + POF_BG_Boost_Cnt
|
| | | + ", POF_BG_Boost_VolStop=" + POF_BG_Boost_VolStop
|
| | | + ", POF_BG_Boost_VolStart=" + POF_BG_Boost_VolStart
|
| | | + ", stationName=" + stationName + ", FBSDeviceName="
|
| | | + FBSDeviceName + ", note=" + note + "]";
|
| | | }
|
| | | |
| | | |
| | | |
| | | }
|
| | |
| | | import com.fgkj.dao.impl.BattMap_informationImpl;
|
| | | import com.fgkj.dao.impl.Batt_rtstateDAOImpl;
|
| | | import com.fgkj.dao.impl.Battalarm_dataDAOImpl;
|
| | | import com.fgkj.dao.impl.ram.Bts_station_stateImpl;
|
| | | import com.fgkj.dao.impl.ram.Fbs9100_stateImpl;
|
| | | import com.fgkj.db.DBUtil;
|
| | | import com.fgkj.dto.BattInf;
|
| | |
| | | int numBadBatt=0;
|
| | | int numAlarm=0;
|
| | | int numPlan=0;
|
| | | int numPoff=0;
|
| | | if(list!=null&&list.size()>0){
|
| | | for(int i=0;i<list.size();i++){
|
| | | state="item-normal";
|
| | |
| | | binf.setFBSDeviceId(binformation.getFBSDeviceId());
|
| | | state=(new Fbs9100_stateImpl().seachDevNow(binf));
|
| | | }else{
|
| | | numPoff=(new Bts_station_stateImpl()).serchByStationId(binformation); //停电数
|
| | | numBadBatt=(new BadBatt_monImpl()).serchByStationId(binformation); //落后总数
|
| | | numAlarm=(new Battalarm_dataDAOImpl()).serchByStationId(binformation); //告警总数
|
| | | numPlan=(new BattDischarge_planImpl()).serchByStationId(binformation); //延迟总数
|
| | | if(numBadBatt>0){
|
| | | state="item-behind"; //落后机房
|
| | | if(numPoff>0){ |
| | | state="item-poff"; //停电
|
| | | }else{
|
| | | if(numAlarm > 0){
|
| | | state="item-warn"; //告警机房
|
| | | if(numBadBatt>0){
|
| | | state="item-behind"; //落后机房
|
| | | }else{
|
| | | if(numPlan > 0){
|
| | | state="item-timeout"; //延迟机房
|
| | | if(numAlarm > 0){
|
| | | state="item-warn"; //告警机房
|
| | | }else{
|
| | | if(numPlan > 0){
|
| | | state="item-timeout"; //延迟机房
|
| | | }
|
| | | }
|
| | | }
|
| | | }
|
| | | |
| | | }
|
| | | if("0".equals(list.get(i).getInformation())){
|
| | | state=""; //若机房未安装将指定的机房设置成灰色的
|
| | | state="item-install"; //若机房未安装将指定的机房设置成灰色的
|
| | | }
|
| | | model.setData(list.get(i));
|
| | | model.setData(list.get(i)); |
| | | model.setMsgO(String.valueOf(numPoff)); //停电数
|
| | | model.setCode(numAlarm); //告警总数
|
| | | model.setSum(numBadBatt); //落后总数
|
| | | model.setNewsum(numPlan); //延时总数
|
New file |
| | |
| | | package com.fgkj.services.ram;
|
| | |
|
| | | import java.util.ArrayList;
|
| | | import java.util.List;
|
| | |
|
| | | import com.fgkj.dao.BaseDAO;
|
| | | import com.fgkj.dao.BaseDAOFactory;
|
| | | import com.fgkj.dao.FBS9100_ComBase;
|
| | | import com.fgkj.dao.impl.ram.Fbs9100_setparamImpl;
|
| | | import com.fgkj.dao.impl.ram.Fbs9100_sysparamImpl;
|
| | | import com.fgkj.dto.ServiceModel;
|
| | | import com.fgkj.dto.ram.Fbs9100_sysparam;
|
| | |
|
| | | public class Fbs9100_sysparamService {
|
| | | private BaseDAO dao;
|
| | | private ServiceModel model;
|
| | | |
| | | public Fbs9100_sysparamService() {
|
| | | super();
|
| | | dao=BaseDAOFactory.getBaseDAO(BaseDAO.FBS9100_SYSPARAM);
|
| | | model=new ServiceModel();
|
| | | }
|
| | | //修改系统参数
|
| | | public ServiceModel update(Object obj) {
|
| | | Fbs9100_sysparam fbs_sys=(Fbs9100_sysparam) obj;
|
| | | Boolean b=dao.update(obj);
|
| | | boolean bl=false;
|
| | | if(b){
|
| | | if(fbs_sys.getNum()==FBS9100_ComBase.CMD_ResetSystem){//重启
|
| | | bl=(new Fbs9100_setparamImpl()).sendCmdToFBS9100Dev(fbs_sys.getNum(),0, fbs_sys.getDev_id());
|
| | | }else{
|
| | | bl=((Fbs9100_sysparamImpl)dao).sendCmdToFBS9100Dev(fbs_sys.getNum(), fbs_sys.getDev_id());
|
| | | }
|
| | | if(bl){
|
| | | model.setCode(1);
|
| | | model.setMsg("修改成功!");
|
| | | }else{
|
| | | model.setCode(0);
|
| | | model.setMsg("设置9100参数失败,请检查网络!");
|
| | | }
|
| | | }else{
|
| | | model.setCode(0);
|
| | | model.setMsg("修改失败!");
|
| | | } |
| | | return model; |
| | | }
|
| | | |
| | | //根据设备id查询系统参数(一定是被管理的)
|
| | | public ServiceModel serchByCondition(Object obj){
|
| | | List list = dao.serchByCondition(obj);
|
| | | if(list!=null && list.size()>0){
|
| | | model.setCode(1);
|
| | | model.setData(list);
|
| | | model.setMsg("查询成功!");
|
| | | }else{
|
| | | model.setCode(0);
|
| | | model.setMsg("查询失败!");
|
| | | }
|
| | | return model;
|
| | | } |
| | | |
| | |
|
| | | }
|