86 lines
2.9 KiB
HTML
86 lines
2.9 KiB
HTML
|
|
<!DOCTYPE html>
|
||
|
|
<html>
|
||
|
|
<head>
|
||
|
|
<meta charset="utf-8">
|
||
|
|
<script src="../js/jquery-1.11.3.js"></script>
|
||
|
|
<title>车辆信息</title>
|
||
|
|
<style type="text/css">
|
||
|
|
.content{
|
||
|
|
width: 800px;
|
||
|
|
margin: auto;
|
||
|
|
}
|
||
|
|
h2{
|
||
|
|
text-align: center;
|
||
|
|
margin: 40px 0;
|
||
|
|
}
|
||
|
|
.content>div>p{
|
||
|
|
margin: 30px 0;
|
||
|
|
}
|
||
|
|
.content>div>p>span{
|
||
|
|
display: inline-block;
|
||
|
|
}
|
||
|
|
.content>div>p>span:nth-child(1){
|
||
|
|
width: 200px;
|
||
|
|
float: left;
|
||
|
|
}
|
||
|
|
.content>div>p>span:nth-child(2){
|
||
|
|
width: 600px;
|
||
|
|
}
|
||
|
|
</style>
|
||
|
|
</head>
|
||
|
|
<body>
|
||
|
|
<div class="content">
|
||
|
|
<h2>车辆信息</h2>
|
||
|
|
</div>
|
||
|
|
<script type="text/javascript">
|
||
|
|
function GetRequest() {
|
||
|
|
var url = location.search; //获取url中"?"符后的字串
|
||
|
|
var theRequest = new Object();
|
||
|
|
if(url.indexOf("?") != -1) {
|
||
|
|
var str = url.substr(1);
|
||
|
|
strs = str.split("&");
|
||
|
|
for(var i = 0; i < strs.length; i++) {
|
||
|
|
theRequest[strs[i].split("=")[0]] = (strs[i].split("=")[1]);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
return theRequest;
|
||
|
|
}
|
||
|
|
function getdata(id){
|
||
|
|
let _this=this;
|
||
|
|
$.ajax({
|
||
|
|
dataType: "json",
|
||
|
|
type: "post",
|
||
|
|
url:'http://zhyq.toommi.com/api/Index/apppost',
|
||
|
|
data: {
|
||
|
|
action:'Screen/vehicle_detail',
|
||
|
|
id:id,
|
||
|
|
},
|
||
|
|
success: function(res) {
|
||
|
|
if (res.code == 200) {
|
||
|
|
var data=res.data;
|
||
|
|
$('.content').append(
|
||
|
|
'<div>'+
|
||
|
|
'<p>'+'<span>车牌号:</span>'+'<span>'+data.vehicleNo+'</span>'+'</p>'+
|
||
|
|
'<p>'+'<span>承运商:</span>'+'<span>'+data.ownerName+'</span>'+'</p>'+
|
||
|
|
'<p>'+'<span>经营范围:</span>'+'<span>'+data.businessScopeName+'</span>'+'</p>'+
|
||
|
|
'<p>'+'<span>运输证号:</span>'+'<span>'+data.transCertificateCode+'</span>'+'</p>'+
|
||
|
|
'<p>'+'<span>期限开始日期:</span>'+'<span>'+data.certificateEffdate+'</span>'+'</p>'+
|
||
|
|
'<p>'+'<span>期限结束日期:</span>'+'<span>'+data.certificateExpdate+'</span>'+'</p>'+
|
||
|
|
'<p>'+'<span>发证机关:</span>'+'<span>'+data.licenseIssueOrganCode+'</span>'+'</p>'+
|
||
|
|
'</div>'
|
||
|
|
)
|
||
|
|
} else {
|
||
|
|
}
|
||
|
|
|
||
|
|
},
|
||
|
|
});
|
||
|
|
};
|
||
|
|
window.onload=function(){
|
||
|
|
var obj=GetRequest();
|
||
|
|
id=decodeURI(obj.id);
|
||
|
|
getdata(id);
|
||
|
|
}
|
||
|
|
</script>
|
||
|
|
</body>
|
||
|
|
</html>
|