| | |
| | | * 获取时间 |
| | | */ |
| | | function getDate() { |
| | | http.get(baseUrl+"/monitor/date", null, function (res) { |
| | | if (res.code === 200){ |
| | | http.get(baseUrl + "/monitor/date", null, function (res) { |
| | | if (res.code === 200) { |
| | | year = res.data.year; |
| | | month = res.data.month; |
| | | day = res.data.day; |
| | |
| | | minute = res.data.minute; |
| | | second = res.data.second; |
| | | week = res.data.week; |
| | | } else if (res.code === 403){ |
| | | parent.location.href = baseUrl+"/login"; |
| | | } else { |
| | | } else if (res.code === 403) { |
| | | parent.location.href = baseUrl + "/login"; |
| | | } else { |
| | | layer.msg("连接服务器失败", {icon: 2}); |
| | | } |
| | | }) |
| | |
| | | * 获取其他数据 |
| | | */ |
| | | function getOther() { |
| | | http.get(baseUrl+"/monitor/other", {crnId: getUrlVal("crnId"), ledId: getUrlVal("ledId")}, function (res) { |
| | | if (res.code === 200){ |
| | | http.get(baseUrl + "/monitor/other", {crnId: getUrlVal("crnId"), ledId: getUrlVal("ledId")}, function (res) { |
| | | if (res.code === 200) { |
| | | |
| | | // 左 |
| | | $('#xDistance').text(res.data.xDistance); |
| | |
| | | $('#led-p-content').text(""); |
| | | } |
| | | |
| | | } else if (res.code === 403){ |
| | | parent.location.href = baseUrl+"/login"; |
| | | } else { |
| | | } else if (res.code === 403) { |
| | | parent.location.href = baseUrl + "/login"; |
| | | } else { |
| | | layer.msg("连接服务器失败", {icon: 2}); |
| | | } |
| | | }) |
| | |
| | | function exitFull() { |
| | | if (document.exitFullscreen) { |
| | | document.exitFullscreen(); |
| | | } |
| | | else if (document.mozCancelFullScreen) { |
| | | } else if (document.mozCancelFullScreen) { |
| | | document.mozCancelFullScreen(); |
| | | } |
| | | else if (document.webkitCancelFullScreen) { |
| | | } else if (document.webkitCancelFullScreen) { |
| | | document.webkitCancelFullScreen(); |
| | | } |
| | | else if (document.msExitFullscreen) { |
| | | } else if (document.msExitFullscreen) { |
| | | document.msExitFullscreen(); |
| | | } |
| | | } |
| | |
| | | document.addEventListener("fullscreenchange", function () { |
| | | try { |
| | | fullscreenState.innerHTML = (document.fullscreen) ? "" : "not "; |
| | | } catch (e) {} |
| | | } catch (e) { |
| | | } |
| | | }, false); |
| | | document.addEventListener("mozfullscreenchange", function () { |
| | | fullscreenState.innerHTML = (document.mozFullScreen) ? "" : "not "; |