<%@ page language="java" import="java.util.*" pageEncoding="gbk"%>
<!DOCTYPE html>
<html>
<head lang="en">
	<meta http-equiv="Content-Type" content="text/html; charset=gbk" />
 	<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
 	<%@include file="../../../../../frame/assets/header-all.jsp"%>
	<style>
	.form-line .text-content{width: 100px;}
	body{
		overflow: hidden;
		padding: 15px;
	}
	#LIKEjiLianCode + span,
	#LIKEjiLianCode + span input{
		 width: 416px !important;
	}
	.help-span  {
		cursor: help;
	}
	.icon-help {
		display: inline-block;
		width: 16px;
		height: 16px;
		margin-left: -15px;
		margin-right: 3px;
		vertical-align: text-top;
	}
	.img-btn {
  		display: inline-block;
  		width: 25px;
  		height: 16px;
  		vertical-align: middle;
  		margin-left: -45px;
  		position: relative;
	}
	</style>
</head>
<body>
<form id="childform" class="easyui-form" data-options="novalidate:true">
		<div class="form-line clearfix" >
			<div style="display:none">
				<span>主键：</span>
				<input id="id">
			</div>
			<div class="fl">
				<span class="text-content"><em class="must"></em>设备编号：</span> 
				<input id="LIKEsbbh" class="easyui-textbox" data-options="required:false" missingMessage="必填项" readonly="readonly"> 
			</div> 
			<div class="fl">
				<span class="text-content"><em class="must"></em>通道编号：</span> 
				<input id="LIKEtdbh" class="easyui-textbox" data-options="required:false" missingMessage="必填项" readonly="readonly"> 
			</div> 
	   </div>
	   <div class="form-line clearfix">
			<div class="fl">
				<span class="text-content"><em class="must"></em><font color="red"> * </font>摄像头名称：</span> 
				<input id="LIKEtdmc" class="easyui-textbox" data-options="required:false" missingMessage="摄像头名称必填项" readonly="readonly"> 
			</div> 
			<div class="fl">
				<span class="text-content"><em class="must"></em><font color="red"> * </font>摄像头状态：</span> 
				<input id="LIKEsfzx" class="easyui-textbox" data-options="required:false" missingMessage="摄像头状态必填项" readonly="readonly"> 
			</div> 
	  </div>
	  <div class="form-line clearfix">
			<div class="fl">
				<span class="text-content"><em class="must"></em><font color="red"> * </font>摄像头类型：</span> 
				<input id="LIKEtdlx" class="easyui-textbox" data-options="required:false" missingMessage="摄像头类型必填项" readonly="readonly"> 
			</div> 
			<div class="fl">
				<span class="text-content"><em class="must"></em>行政目录：</span> 
				<input id="xzmc" data-options="required:false" missingMessage="必填项"  class="easyui-textbox" readonly="readonly">
			</div> 
	 </div>
	 <div class="form-line clearfix">
			<div class="fl">
				<span class="text-content"><em class="must"></em>经度：</span> 
				<input id="LIKEjd" class="easyui-textbox" data-options="required:false" missingMessage="必填项" readonly="readonly"> 
			</div> 
			<div class="fl">
				<span class="text-content"><em class="must"></em>纬度：</span> 
				<input id="LIKEwd" class="easyui-textbox" data-options="required:false" missingMessage="必填项" readonly="readonly"> 
			</div> 
	 </div>
	 <div class="form-line clearfix">
			<div class="fl">
				<span class="text-content"><em class="must"></em>外部编号：</span> 
				<input id="LIKEwbbh" class="easyui-textbox" data-options="required:false" missingMessage="必填项" readonly="readonly"> 
			</div> 
	 </div>
</form>
</body>
</html>
<script type="text/javascript">
var wId = $.getUrlParam("winId") ;
var records = top.$("#"+wId).panel("options").data;
$(function(){
	initForms();
});

function initForms(){
	if(records){
		$("#id").val(records.id);
		$("#LIKEsbbh").textbox("setValue",records.sbbh);
		$("#LIKEtdbh").textbox("setValue",records.tdbh);
		$("#LIKEtdmc").textbox("setValue",records.tdmc);
		$("#LIKEsfzx").textbox("setValue",records.sfzx=="1"?"在线":"不在线");
		$.ajax({
			type:'post',
			dataType : 'json',
			url:'xtclAction!query_Xtcl.do?csdl=channelSmallType&csdm='+records.tdlx,
			success:function(data){
				if(data&&data.length>0){
					$("#LIKEtdlx").textbox("setValue",data[0].csmc); 
				}
			}
		});	
		$.ajax({
			type:'post',
			dataType : 'json',
			url:'ptxzsAction!query_Ptxzs.do?xzbh='+records.xzbh,
			success:function(data){
				if(data&&data.length>0){
					$("#xzmc").textbox("setValue",data[0].xzmc); 
				}
			}
		});	
		$("#LIKEjd").textbox("setValue",records.jd);
		$("#LIKEwd").textbox("setValue",records.wd);
		$("#LIKEwbbh").textbox("setValue",records.wbbh);
	}else{
		var datenow = new Date();
	}
}
</script>
