| | |
| | | <head> |
| | | <meta charset="utf-8"> |
| | | <meta http-equiv="X-UA-Compatible" content="IE=edge"> |
| | | <meta name="viewport" |
| | | content="width=device-width, initial-scale=1, maximum-scale=1, shrink-to-fit=no"> |
| | | <meta name="viewport" content="width=device-width, initial-scale=1"> |
| | | <title>切换地图</title> |
| | | |
| | | <link rel="icon" type="image/x-icon" href="/hxzkoa/hxzk/assets/img/favicon.ico" /> |
| | |
| | | <script src="/hxzkoa/hxzk/plugins/table/datatable/button-ext/jszip.min.js"></script> |
| | | <script src="/hxzkoa/hxzk/plugins/table/datatable/button-ext/buttons.html5.min.js"></script> |
| | | <script src="/hxzkoa/hxzk/plugins/table/datatable/button-ext/buttons.print.min.js"></script> |
| | | <script src="/hxzkoa/hxzk/assets/js/custom.js"></script> |
| | | <script> |
| | | var result; |
| | | var department = []; |
| | |
| | | |
| | | $('.header-page').load('/hxzkoa/hxzk/top.html'); $('.login-page').load('/hxzkoa/hxzk/head.html'); |
| | | </script> |
| | | <script src="/hxzkoa/hxzk/assets/js/custom.js"></script> |
| | | |
| | | <!-- END GLOBAL MANDATORY SCRIPTS --> |
| | | |
| | | <!-- > BEGIN PAGE FUNCTION SCRIPTS --> |
| | |
| | | |
| | | if (data.length == 1) { |
| | | $("#f1").css("display", "block") |
| | | $("#boxfloor").css("height","50px") |
| | | } |
| | | if (data.length == 2) { |
| | | $("#f2").css("display", "block") |
| | |
| | | return [anchorList_on, anchorList_off] |
| | | }; |
| | | |
| | | /**该方法用来绘制一个有填充色的圆角矩形 |
| | | *@param cxt:canvas的上下文环境 |
| | | *@param x:左上角x轴坐标 |
| | | *@param y:左上角y轴坐标 |
| | | *@param width:矩形的宽度 |
| | | *@param height:矩形的高度 |
| | | *@param radius:圆的半径 |
| | | *@param fillColor:填充颜色 |
| | | /**该方法用来绘制一个有填充色的圆角矩形 |
| | | *@param cxt:canvas的上下文环境 |
| | | *@param x:左上角x轴坐标 |
| | | *@param y:左上角y轴坐标 |
| | | *@param width:矩形的宽度 |
| | | *@param height:矩形的高度 |
| | | *@param radius:圆的半径 |
| | | *@param fillColor:填充颜色 |
| | | **/ |
| | | function fillRoundRect(cxt, x, y, width, height, radius, /*optional*/ fillColor) { |
| | | //圆的直径必然要小于矩形的宽高 |
| | | //圆的直径必然要小于矩形的宽高 |
| | | if (2 * radius > width || 2 * radius > height) { return false; } |
| | | |
| | | cxt.save(); |
| | | cxt.translate(x, y); |
| | | //绘制圆角矩形的各个边 |
| | | //绘制圆角矩形的各个边 |
| | | drawRoundRectPath(cxt, width, height, radius); |
| | | cxt.fillStyle = fillColor || "#000"; //若是给定了值就用给定的值否则给予默认值 |
| | | cxt.fillStyle = fillColor || "#000"; //若是给定了值就用给定的值否则给予默认值 |
| | | cxt.fill(); |
| | | cxt.restore(); |
| | | } |
| | | |
| | | function drawRoundRectPath(cxt, width, height, radius) { |
| | | cxt.beginPath(0); |
| | | //从右下角顺时针绘制,弧度从0到1/2PI |
| | | //从右下角顺时针绘制,弧度从0到1/2PI |
| | | cxt.arc(width - radius, height - radius, radius, 0, Math.PI / 2); |
| | | |
| | | //矩形下边线 |
| | | //矩形下边线 |
| | | cxt.lineTo(radius, height); |
| | | |
| | | //左下角圆弧,弧度从1/2PI到PI |
| | | //左下角圆弧,弧度从1/2PI到PI |
| | | cxt.arc(radius, height - radius, radius, Math.PI / 2, Math.PI); |
| | | |
| | | //矩形左边线 |
| | | //矩形左边线 |
| | | cxt.lineTo(0, radius); |
| | | |
| | | //左上角圆弧,弧度从PI到3/2PI |
| | | //左上角圆弧,弧度从PI到3/2PI |
| | | cxt.arc(radius, radius, radius, Math.PI, Math.PI * 3 / 2); |
| | | |
| | | //上边线 |
| | | //上边线 |
| | | cxt.lineTo(width - radius, 0); |
| | | |
| | | //右上角圆弧 |
| | | //右上角圆弧 |
| | | cxt.arc(width - radius, radius, radius, Math.PI * 3 / 2, Math.PI * 2); |
| | | |
| | | //右边线 |
| | | //右边线 |
| | | cxt.lineTo(width, height - radius); |
| | | cxt.closePath(); |
| | | } |
| | |
| | | |
| | | |
| | | // var anckicon = '/hxzkoa/hxzk/image/anchor/lingjin.png'; |
| | | // imgList['anchor']=anckicon; |
| | | // imgList['anchor']=anckicon; |
| | | var anckicon_on = '/hxzkoa/hxzk/image/anchor/基站在线.png'; |
| | | //var anckicon_on = '/hxzkoa/hxzk/image/anchor/lingjin.png'; |
| | | imgList['anchor_online'] = anckicon_on; |
| | |
| | | this.playMark; //正在展示的标记 |
| | | this.playAchor; //正在展示的基站 |
| | | this.playAchorli; //正在展示的基站 |
| | | this.playMarkInKaoQin;//当前标记是否在考勤区域内 |
| | | this.playMarkInKaoQin;//当前标记是否在考勤区域内 |
| | | this.trackNow; //当前轨迹 |
| | | |
| | | this.onlineAnchorList;//当前基站列表 |
| | |
| | | |
| | | can.globalCompositeOperation = "source-over"; |
| | | var images = _this.imgLoadList; |
| | | |
| | | |
| | | //画地图 |
| | | can.drawImage(_this.img, 0, 0, _this.img.naturalWidth, _this.img.naturalHeight, _this.imgXList['map'], _this.imgYList['map'], _this.img.naturalWidth * _this.imgScaleList['map'] * _this.rateNumList['map'], _this.img.naturalHeight * _this.imgScaleList['map'] * _this.rateNumList['map']); |
| | | |
| | |
| | | var pm = _this.playMark; |
| | | |
| | | function ftn(current_floor, pm, tn, rtk, ctt, rtc, igxm, igym, igslm, rnlm, xr, yr, xx0, yy0) { |
| | | alert(tn) |
| | | //trackNow = getTracknow(current_floor, pm[0], rtk) |
| | | if (tn.length == 0) { |
| | | trackNow = []; |
| | |
| | | _this.trackNow = []; |
| | | } |
| | | var isSos = _this.playMark[i][7]; |
| | | |
| | | |
| | | if (_this.playMark[i][8] == "1") { |
| | | if (sousuoType) { |
| | | can.drawImage(images[_this.playMark[i][10]], 0, 0, images[key].naturalWidth, images[key].naturalHeight, x_cor_now - (images[key].naturalWidth * _this.imgScaleList[key] * _this.rateNumList[key]) / 2, y_cor_now - (images[key].naturalHeight * _this.imgScaleList[key] * _this.rateNumList[key]), images[key].naturalWidth * _this.imgScaleList[key] * _this.rateNumList[key], images[key].naturalHeight * _this.imgScaleList[key] * _this.rateNumList[key]); |
| | |
| | | var track_now = Date.parse(new Date()); //timestamp为毫秒单位 |
| | | track_now = track_now / 1000; |
| | | var track_now_head = track_now - _this.real_trak_time; |
| | | //当前track最开始的时间 |
| | | //当前track最开始的时间 |
| | | var track_head_date = new Date(); |
| | | track_head_date.setTime(track_now_head * 1000 + 8 * 3600 * 1000); |
| | | var track_head_date_str = track_head_date.toJSON().substr(0, 19).replace('T', ' '); |