var code =localStorage.getItem("code"); $(function(){ layui.use('laydate', function(){ var laydate = layui.laydate; //日期时间选择器 laydate.render({ elem: '#startTime', done:function (data) { var endTime=$("#endTime").val(); if(data>endTime && endTime!=''){ layer.msg("开始时间不能大于结束时间"); $("#startTime").val(''); } } }); laydate.render({ elem: '#endTime', done:function (data) { var startTime=$("#startTime").val(); if(data0){ var leng = (pageNum - 1) * pageSize; for(var i = 0;i"; //基础数据,待填(部分字段需确认) html+=""+JY.Object.notEmpty(l.code)+""; html+=""+JY.Object.notEmpty(l.typeName)+""; html+=""+JY.Object.notEmpty(l.deviceModel)+""; html+=""+JY.Object.notEmpty(l.deviceCode)+""; html+=""+JY.Object.notEmpty(l.lon)+""; html+=""+JY.Object.notEmpty(l.lat)+""; html+=""+JY.Object.notEmpty(l.upTime)+""; var posTypeInfo = l.posType; if(posTypeInfo =="LBS" || posTypeInfo =="lbs"){ posTypeInfo = "基站定位"; } if(posTypeInfo =="GPS" || posTypeInfo =="gps"){ posTypeInfo = "卫星定位"; } if(posTypeInfo =="WIFI" || posTypeInfo =="wifi"){ posTypeInfo = "WIFI定位"; } if(posTypeInfo =="BEACON" || posTypeInfo =="beacon"){ posTypeInfo = "蓝牙定位"; } html+=""+JY.Object.notEmpty(posTypeInfo)+""; html+=""+JY.Object.notEmpty(l.address)+""; html+=""+JY.Object.notEmpty(l.useUnit)+""; html+=""+JY.Object.notEmpty(l.useTime)+""; html+=""+JY.Object.notEmpty(l.proName)+""; html+=""; } $("#baseTable tbody").append(html); JY.Page.setPage("baseForm", "pageing", pageSize,pageNum, totalRecord, "getbaseList"); }else{ html+="没有相关数据"; $("#baseTable tbody").append(html); $("#pageing ul").empty();//清空分页 } JY.Model.loadingClose(); }); } function getTypeName(num,name,selectId){ $("#"+selectId).html(""); JY.Ajax.doRequest(null,bonuspath +'/backstage/position/getTypeName',null,function(data){ var l = data.obj.list; var str=''; str+=''; for(var i=0;i'+l[i].name+''; }else{ if(num==l[i].id){ str+=''; }else{ str+=''; } } } $("#"+selectId).append(str); }); } function getDeviceModel(num,name,selectId){ $("#"+selectId).html(""); JY.Ajax.doRequest(null,bonuspath +'/backstage/position/getDeviceModel',null,function(data){ var l = data.obj.list; var str=''; for(var i=0;i'+l[i].name+''; }else{ if(num==l[i].id){ str+=''; }else{ str+=''; } } } $("#"+selectId).append(str); }); } function getDeviceCode(num,name,selectId){ $("#"+selectId).html(""); JY.Ajax.doRequest(null,bonuspath +'/backstage/position/getDeviceCode',null,function(data){ var l = data.obj.list; var str=''; for(var i=0;i'+l[i].name+''; }else{ if(num==l[i].id){ str+=''; }else{ str+=''; } } } $("#"+selectId).append(str); }); } function getCode(num,name,selectId){ $("#"+selectId).html(""); JY.Ajax.doRequest(null,bonuspath +'/backstage/position/getCodes',null,function(data){ var l = data.obj.list; var str=''; for(var i=0;i'+l[i].name+''; }else{ if(num==l[i].id){ str+=''; }else{ str+=''; } } } $("#"+selectId).append(str); }); } function exportOldData(){ var c = document.getElementById("code").value; if(c != null && c !=''){ code = c; } $("#baseForm").attr("onsubmit","return true;"); $("#baseForm").attr("action",bonuspath +'/backstage/position/exportOldGPS?codes='+code); $("#baseForm").attr("target","downloadFrame");//iframe的名字 $("#baseForm").submit(); }