<%@ page language="java" import="java.util.*" pageEncoding="gbk"%>
<!DOCTYPE html>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=gbk" />
		<%@include file="../../../frame/assets/header-all.jsp"%>
		<link rel="stylesheet" type="text/css" href="<%=basePath%>/yw/homepage/alarmdetail/alarmDetail.css"/>
		<style>
			body{display:flex;justify-content:center;padding-top: 20px;}
			.alarm-info{margin-left: 14px;position:relative; width: 232px;}
			.alarm-info li{margin-bottom: 8px;line-height: 20px;color:#545454;font-size:12px;color:black;}
			.alarm-info li span:nth-child(1){display: inline-block;width: 80px;}
			.alarm-info li span:nth-child(2){display: inline-block; vertical-align: top;width:152px;}
		</style>
	</head>
	<body>
				<div style="display:flex;">
					    <div title="图片"  style="display:block;margin-left: -10px;margin-top: -10px;">
					    	<div style="width:490px;height:300px;" id="picture">
							<!-- 	<img src=""  alt=""  width="100%" height="100%"/> -->
					    		<img src alt="" width="100%" height="100%" onerror="$.loadErrorPic(this);"/>
					    	</div>
					    </div>
						<div class="alarm-info" style="display:block;">
							 <ul>
							 	<li><span>报警编号:</span><span id="fxbjbh"></span></li>
							 	<li><span>报警类型:</span><span id="bjzwmc"></span></li>
							 	<li><span>设备名称:</span><span id="fxtdbm"></span></li>
							 	<li><span>设备类型:</span><span id="fxtdlx"></span></li>
						  		<li><span>设备IP:</span><span id="fxsbip"></span></li>
						  		<li><span>设备编号:</span><span id="fxsbbh"></span></li>
						  		<li><span>通道编号:</span><span id="fxtdbh"></span></li>
						  		<li><span>告警开始时间:</span><span id="fwdsdksbjsj" ></span></li>
						  		<li><span>告警结束时间:</span><span id="fwdsdjsbjsj"></span></li>
							 </ul>
						</div>
			</div>
	</body>
</html>	

<script type="text/javascript">
	var bjxxid = $.getUrlParam("bjxxid");
	console.log("==== bjxxid :  ",bjxxid);
	$(function() {
		
		$.ajax({
			type : 'post',
			dateType : 'json',
			url : 'gdwdaqmxxAction!get_Gdwdaqmxx.do',
			data : {'bjxxid':bjxxid},
			success : function(res){
			//	console.log("返回值：",res);
				if(res){
					$('#fwdsdksbjsj').html(res.fwdsdksbjsj);
					$('#fwdsdjsbjsj').html(res.fwdsdjsbjsj);
					$('#bjzwmc').html(res.bjzwmc);
					$('#fxsbmc').html(res.fxsbmc);
					$('#fxsbip').html(res.fxsbip);
					$('#fxbjbh').html(res.fxbjbh);
					$('#fxtdbm').html(res.fxtdbm);
					$('#fxtdlx').html(res.fxtdlx);
					$('#fxsbbh').html(res.fxsbbh);
					$('#fxtdbh').html(res.fxtdbh);
					
					var picUrl = res.bjtplj;
					if(picUrl != null){
						var proName = window.location.pathname.split("/")[1];
						var sysUrl = "http://"+window.location.host+"/"+proName;
					 	var picProxyGetUrl = sysUrl+"/sourceProxy?fileType=picUrlProxy&picUrl="+picUrl;
					 	$('#picture img').load(function(){
					 		$('#picture img').attr("src",picProxyGetUrl);
					 	})
					}
				}
			}
		})
	});
	
</script>
