<%@ page language="java" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<c:set var="contextPath" value="${pageContext.request.contextPath}"></c:set>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>筛选基本信息</title>
<meta name="description" content="">
<meta name="keywords" content="">
<link href="${contextPath}/static/weixin/ssdb/css/common.css" rel="stylesheet">
<link href="${contextPath}/static/weixin/ssdb/css/main.css" rel="stylesheet">
<link href="${contextPath}/static/weixin/ssdb/css/ssdb.css" rel="stylesheet"/>
<script src="${contextPath}/static/js/flexible.min.js"></script>
</head>
<body class="bg-grey">
	<section>
		<div class="fs-16 color555 bg-white mar-tb-20 pad-l-25">
			<p class="retinabt">
			<p class="pad-t-15"><span>法院:</span><span class="pad-l-5" id="courtName"></span></p>
			<p class="pad-t-10 pad-b-5"><span>诉讼阶段:</span><span class="pad-l-5" id="stage"></span></p>
			<p class="pad-tb-5"><span>担保机构:</span><span class="pad-l-5" id="companyName"></span></p>
			<p class="pad-tb-5"><span>担保金额:</span><span class="pad-l-5" id="sqbd"></span></p>
			<p class="pad-b-10"><span>标的类型：</span><span class="pad-l-5" id="bdCode"></span></p>
			<p class="pad-b-10"><span>担保金额：</span><span class="pad-l-5" id="bf"></span></p>
			<p class="pad-b-10"><span>积分：</span><span class="pad-l-5" id="points"></span></p>
		</div>
	</section>
	<script type="text/javascript" src="${contextPath}/static/js/jquery-1.12.0.min.js"></script>
	<script type="text/javascript" src="${contextPath}/static/js/layer/layer.js"></script>
    <script type="text/javascript" src="${contextPath}/static/js/requestutil.js"></script>
    <script type="text/javascript" src="${contextPath}/static/js/jstorage.js"></script>
     <script type="text/javascript">
 	$(document).ready(function() {
  		var baseURL='<%=com.fadu.app.util.AppConfig.url_duowenapp_b%>';
  		var companyId="${companyId}";
  		var searchId="${searchId}";
  		var token=$.jStorage.get("token");
  		var jsonReq={};
  		jsonReq.companyId=companyId;
  		jsonReq.token=token;
  		jsonReq.searchId=searchId;
  		jsonReq.actionCode="B518";
  		var url=baseURL+"/B/android/";
  		console.log(jsonReq);
  		requestData(url,jsonReq,success,fail);
  		function success(json){
  				console.log(json);
  				 if(json){
	  					if(json.success==true){
	  						//筛选基本信息
	  						var courtName=json.courtName;
	  						var stage=json.stage;
	  						var companyName=json.companyName;
	  						var sqbd=json.sqbd;
	  						var bdCode=json.bdCode;
	  						var bf=json.bf;
	  						var points=json.points;
	  						if(stage==0){//(诉讼前:0;诉讼中:1)
	  							stage="诉讼前";
	  						}
	  						if(stage==1){//(诉讼前:0;诉讼中:1)
	  							stage="诉讼中";
	  						}
	  						var bdCode=getKbyV(bdCode);
	  						$("#courtName").text(courtName);
	  						$("#stage").text(stage);
	  						$("#companyName").text(companyName);
	  						$("#sqbd").text(sqbd);
	  						$("#bdCode").text(bdCode);
	  						$("#bf").text(bf);
	  						$("#points").text(points);
	  					}else{
	  						layer.msg(json.message);	
	  					}
	  				}else{
	  					layer.msg("获取信息失败!!");
	  				}	
  			}
  			function fail(resp){
  				console.log(resp);
  			}
  			//标的类型 中文转换
  			function getKbyV(key){
  				var v="";
  				switch(key) {
				    case "S101":
				        v="房产";
				        break;
				    case "S102":
				        v="银行账户类";
				        break;
				    case "S103":
				        v="土地使用权";
				        break;
				    case "S104":
				        v="非上市公司股权";
				        break;
				    case "S105":
				        v="应收债权";
				        break;
				    case "S106":
				        v="采矿权";
				        break;
				    case "S201 ":
				        v="车辆";
				        break;
				    case "S202":
				        v="船舶";
				        break;
				    case "S203":
				        v="不易腐朽损坏货物";
				        break;
				    case "S204":
				        v="机器设备";
				        break;
				    case "S205":
				        v="商标专利";
				        break;
				    case "S301":
				        v="上市公司股票";
				        break;
				    case "S302":
				        v="非固定收益基金账户";
				        break;
				    case "S303":
				        v="易腐朽损坏货物";
				        break;
				    default:
					    v="";
					    break;
				}
				return v;
  			}
  
   });
  </script>
</body>
</html>
