AIMS/BeginScreen/D_SYD.aspx
2022-08-23 21:12:59 +08:00

380 lines
15 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="D_SYD.aspx.cs" Inherits="BeginScreen.D_SYD" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" style="height: 100%;">
<head id="Head1" runat="server">
<script src="js/jquery.min.js" type="text/javascript"></script>
<script src="js/speak.js"></script>
<script language="javascript" src="js/url.js" charset="utf-8"></script>
<style type="text/css">
thead tr:last-child td {
height: 50px;
}
tbody td {
background: none !important;
color: #fff !important;
border-bottom: 15px solid #62906900 !important;
}
tbody td div {
width: 100%;
height: 100%;
line-height: 50px;
background: #E46705 !important;
border-top: 1.9px solid #fff;
border-bottom: 1.9px solid #fff;
}
tbody tr td:first-child {
padding-left: 1%;
}
tbody tr td:last-child {
padding-right: 1%;
}
tbody tr td:first-child div {
border-left: 1.9px solid #fff;
border-top-left-radius: 30px;
border-bottom-left-radius: 30px;
}
tbody tr td:last-child div {
border-right: 1.9px solid #fff;
border-top-right-radius: 30px;
border-bottom-right-radius: 30px;
}
</style>
</head>
<body style="margin: 0; /*background: linear-gradient(#08413C,#28A1A9); */background: linear-gradient(#0E101A,#DF8A53); height: 100%;" bgcolor="#000000" id="Mybody">
<%-- <a id="wert" onclick="OpenDoc(1,0,'fffff.docx')" href="javascript:;">关闭</a>
<a onclick="OpenDoc(1,1,'手麻系统项目实施文档.doc')" href="javascript:;">关闭</a>
<a id="test" href="javascript:;">触发</a>X:<input id="xxx" type="text" />
Y:<input id="yyy" type="text" />
<a id="we11rt" onclick="GetClickOpenFile('测试关闭.docx',1)" href="javascript:;">测试触发</a>--%>
<table id="table" table border="0" width='100%' height='100%' cellpadding="0" cellspacing="0">
<thead>
<tr style="/*background: black; */ background: linear-gradient(#08413C,#28A1A9); color: white; margin-bottom: 6px; font-size: 40px; font-weight: bold;">
<td colspan="10" align="center" valign="middle" height="10%" style="padding: 6px;">
<div onclick="speak('爱上对方过后就哭了');" style="left: 10px; top: 22px; position: absolute; /*color: #62D377; */ font-size: 27px;">
屯留县人民医院
</div>
今日手术
<div style="right: 250px; top: 22px; position: absolute; /*color: #62D377; */ font-size: 27px;">
<div id="currentTime">
</div>
<div id="currentHour"></div>
</div>
<div style="right: 20px; top: 22px; position: absolute; /*color: #62D377; */ font-size: 27px;">
<div id="js">
</div>
</div>
</td>
</tr>
<tr style="/*background: #2D9131; */ color: white; margin-bottom: 6px; font-size: 24px; font-weight: bold;">
<td width="3%" align="center" valign="middle" height="5%" style="padding: 6px;"></td>
<td width="20%" align="center" valign="middle" height="5%" style="padding: 6px;">科室
</td>
<td width="15%" align="center" valign="middle" height="5%" style="padding: 6px;">床号
</td>
<td width="16%" align="center" valign="middle" height="5%" style="padding: 6px;">姓名
</td>
<%-- <td width="24%" align="center" valign="middle" height="5%" style="padding: 6px;">
手术间
</td>--%>
<td width="24%" align="center" valign="middle" height="5%" style="padding: 6px;">状态
</td>
</tr>
</thead>
<tbody id="Mytbody" style="background: linear-gradient(#221A1C,#DF8A53);">
</tbody>
</table>
<table id="table1" table border="0" width='100%' height='0' cellpadding="0" cellspacing="0">
<tbody id="Mytbody1" style="background: linear-gradient(#221A1C,#DF8A53);">
<tr style="position: fixed; bottom: 0; width: 100%;">
<td colspan="10" style="border-bottom: 0 !important; display: block;">
<div style="background: #016768 !important; border-bottom-left-radius: 0; border-bottom-right-radius: 0; border-bottom: 0; padding: 0 5%; height: 60px; width: 89%; position: relative;">
<div style="background: #17233B!important; width: 99%; height: 40px; margin-top: 10px; padding: 0 0px;">
<marquee id="marquee" direction="left" scrollamount="12" style="font-family: sans-serif; font-size: 25px; color: #fff; height: 40px; line-height: 40px; font-weight: bold;"></marquee>
</div>
<span style="display: block; width: 20px; height: 20px; background: red; position: absolute; left: 1.8%; top: 22px; border-radius: 50%; border: 1px solid #fff;"></span>
<span style="display: block; width: 20px; height: 20px; background: red; position: absolute; right: 1.8%; top: 22px; border-radius: 50%; border: 1px solid #fff;"></span>
</div>
</td>
</tr>
</tbody>
</table>
<div id="officeId" style="width: 4%; height: 100%; background: #ff000000; position: fixed; left: 0; top: 0; z-index: 100000;">
</div>
<script language="javascript" src="js/webofficetip.js" charset="utf-8"></script>
<script language="javascript">
SetupTip();
</script>
</body>
<script type="text/javascript">
////document上绑定自定义事件ondataavailable
//document.addEventListener('ondataavailable', function (event) {
// //alert(event.eventType);
//}, false);
//var obj = document.getElementById("wert");
////obj元素上绑定click事件
//obj.addEventListener('click', function (event) {
// //alert(event.eventType);
//}, false);
////调用document对象的 createEvent 方法得到一个event的对象实例。
//var event = document.createEvent('HTMLEvents');
//// initEvent接受3个参数
//// 事件类型,是否冒泡,是否阻止浏览器的默认行为
//event.initEvent("ondataavailable", true, true);
//event.eventType = 'message';
////触发document上绑定的自定义事件ondataavailable
//document.dispatchEvent(event);
//var event1 = document.createEvent('HTMLEvents');
//event1.initEvent("click", true, true);
////event1.eventType = 'message';
////触发obj元素上绑定click事件
//document.getElementById("test").onclick = function () {
// obj.dispatchEvent(event1);
//};
///打开或关闭文件
function GetClickOpenFile(fileName, isClose) {
$("#officeId").attr("onclick", "OpenDoc(1," + isClose + ",'" + fileName + "')");
$.ajax({
type: "POST",
url: "RelationsWaitingAreaBigScreenSYDHandler.ashx?cmd=GetOpenFile",
dataType: 'json',
async: false,
success: function (result) {
}
});
}
</script>
<script type="text/javascript">
//function mousePosition(ev) {
// if (ev.pageX || ev.pageY) {
// return { x: ev.pageX, y: ev.pageY };
// }
// return {
// x: ev.clientX + document.body.scrollLeft - document.body.clientLeft,
// y: ev.clientY + document.body.scrollTop - document.body.clientTop
// };
//}
//function mouseMove(ev) {
// ev = ev || window.event;
// var mousePos = mousePosition(ev);
// document.getElementById('xxx').value = mousePos.x;
// document.getElementById('yyy').value = mousePos.y;
// //mousePos.y = 5000;
// //document.getElementById('yyy').value = mousePos.y;
// $("#xxx").focus();
// document.getElementById('yyy').value = mousePos.y;
//}
///*onmousemove事件委托在document对象上调用mouseMove函数*/
//document.onmousemove = mouseMove;
</script>
<script type="text/javascript">
// 新式注入
//CefSharp.BindObjectAsync("jsObj");
var messId = 0;
var sendType = "";
var tbodyobj = document.getElementById('Mytbody');
setInterval(load, 10000);
var WorkerCurrentPage = 1;
var countPage;
//load();
function load() {
if (WorkerCurrentPage > countPage) {
WorkerCurrentPage = 1;
}
$.ajax({
type: "POST",
url: "RelationsWaitingAreaBigScreenSYDHandler.ashx?cmd=GetHtml&WorkerCurrentPage=" + WorkerCurrentPage,
dataType: 'json',
async: false,
success: function (result) {
var data = eval(result);
if (data.success) {
tbodyobj.innerHTML = data.html;
if (data.systemType == "1") {
//location.href = "https://www.baidu.com";//重症大屏地址
}
if (data.sendType == "0") {
if (typeof jsObj == "undefined") {
//html
if (sendType == "1") {
GetClickOpenFile('测试关闭.docx', 0);
}
$("#Mytbody1 marquee").html(data.msg);
} else {
//winform
jsObj.bbb("WindowLoad", "", "");
jsObj.bbb("SendNotice", data.msg.toString(), data.messId.toString());
$("#Mytbody1 marquee").html(data.msg);
}
} else {
$("#Mytbody1 marquee").html("");
if (data.sendType == "1") {
if (sendType != data.sendType) {
if (typeof jsObj == "undefined") {
//html
GetClickOpenFile(data.msg, 1);
} else {
//winform
jsObj.bbb("SendFile", data.msg.toString(), data.messId.toString());
}
} else if (messId != data.messId) {//如果不是同一消息,则打开文件
if (typeof jsObj == "undefined") {
//html
GetClickOpenFile(data.msg, 1);
} else {
//winform
jsObj.bbb("SendFile", data.msg.toString(), data.messId.toString());
}
}
}
}
sendType = data.sendType;
messId = data.messId;
countPage = data.countPage;
$("#js").html('(第' + WorkerCurrentPage + '屏/共' + data.countPage + '屏)');
}
}
});
WorkerCurrentPage = WorkerCurrentPage + 1
}
Date.prototype.format = function (format) {
var o = {
"M+": this.getMonth() + 1, //month
"d+": this.getDate(), //day
"h+": this.getHours(), //hour
"m+": this.getMinutes(), //minute
"s+": this.getSeconds(), //second
"q+": Math.floor((this.getMonth() + 3) / 3), //quarter
"S": this.getMilliseconds() //millisecond
}
if (/(y+)/.test(format)) {
format = format.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));
}
var week = {
"0": "日",
"1": "一",
"2": "二",
"3": "三",
"4": "四",
"5": "五",
"6": "六"
};
if (/(E+)/.test(format)) {
format = format.replace(RegExp.$1, ((RegExp.$1.length > 1) ? (RegExp.$1.length > 2 ? "星期" : "周") : "") + week[this.getDay() + ""]);
}
for (var k in o) {
if (new RegExp("(" + k + ")").test(format)) {
format = format.replace(RegExp.$1, RegExp.$1.length == 1 ? o[k] : ("00" + o[k]).substr(("" + o[k]).length));
}
}
return format;
}
$(function () {
var _timestamp
//setInterval("$('#currentHour').text(new Date(_timestamp).format('hh:mm:ss'));",1000);
$.ajax({
type: "POST",
url: "OpeRoomPlanNoticeHandler.ashx?cmd=GetHtmlTime",
async: false,
success: function (result) {
_timestamp = Date.parse(result);
$("#currentTime").text(new Date(_timestamp).format("yyyy年MM月dd日") + " " + GetWeek());// EEE
//_timestamp = _timestamp.toString().match(/^\d$/) ? _timestamp : new Date().getTime();
setInterval(function () {
$("#currentTime").text(new Date(_timestamp).format("yyyy年MM月dd日") + " " + GetWeek());
_timestamp += 1000;
}, 1000);
}
});
});
function GetWeek() {
var a = new Array("日", "一", "二", "三", "四", "五", "六");
var week = new Date().getDay();
var str = "星期" + a[week];
return str;
}
$("#marquee").bind('DOMNodeInserted', function (e) {
speak($(e.target).html());
});
//所有键盘抬起触发
document.addEventListener('keyup', function (e) {
//alert(1);
var event = e || window.event // e:非IE浏览器使用window.event是IE浏览器使用
console.log(event.shiftKey, event.altKey, event.ctrlKey, event.key, event.keyCode);
var key = event.key.toString().toLowerCase()
if (key == "f11" || event.keyCode == 122) {
if (typeof jsObj != "undefined") {
jsObj.bbb("FullScreen", "", "");
}
}
if (key == "escape" || event.keyCode == 27) {
if (typeof jsObj != "undefined") {
jsObj.bbb("EscFullScreen", "", "");
}
}
}, false);
///设置字体颜色
function SetFontColor(family, size, color, weight, style) {
if (family != "") {
$("#marquee").css("font-family", family);
}
if (size != "") {
$("#marquee").css("font-size", size + "px");
}
if (color != "") {
$("#marquee").css("color", color);
}
if (weight != "") {
$("#marquee").css("font-weight", weight);
}
if (style != "") {
$("#marquee").css("font-style", style);
}
}
</script>
<script language="javascript" type="text/javascript">
function OpenDoc(flag, isClose, filename) {
var strPath = 'WebOffice.aspx?fileid=' + flag + '&close=' + isClose + "&filename=" + escape(filename); //fileid为文件编号
//console.log(strPath);
ShowPage(strRoot, strPath);
}
</script>
</html>