160 lines
4.4 KiB
HTML
160 lines
4.4 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<script src="../js/jquery-1.11.3.js"></script>
|
|
<script src="../js/xlPaging.js"></script>
|
|
<!-- <script src="https://cdn.bootcdn.net/ajax/libs/jquery/1.9.1/jquery.min.js"></script> -->
|
|
|
|
<title>入园记录</title>
|
|
<style type="text/css">
|
|
/**************分页*******************/
|
|
#page {
|
|
margin: 20px auto;
|
|
color: #666;
|
|
display: block;
|
|
text-align: center;
|
|
}
|
|
|
|
#page li {
|
|
display: inline-block;
|
|
min-width: 30px;
|
|
height: 28px;
|
|
cursor: pointer;
|
|
color: #666;
|
|
font-size: 13px;
|
|
line-height: 28px;
|
|
background-color: #f9f9f9;
|
|
border: 1px solid #dce0e0;
|
|
text-align: center;
|
|
margin: 0 4px;
|
|
-webkit-appearance: none;
|
|
-moz-appearance: none;
|
|
appearance: none;
|
|
}
|
|
|
|
.xl-nextPage,
|
|
.xl-prevPage {
|
|
width: 60px;
|
|
color: #0073A9;
|
|
height: 28px;
|
|
}
|
|
.swiper-container{
|
|
margin-top: .7rem;
|
|
z-index: -1;
|
|
}
|
|
#page li.xl-disabled {
|
|
opacity: .5;
|
|
cursor: no-drop;
|
|
}
|
|
|
|
#page li.xl-active {
|
|
background-color: #0073A9;
|
|
border-color: #0073A9;
|
|
color: #FFF
|
|
}
|
|
tr td{
|
|
border: 1px solid #eee;
|
|
height:40px;
|
|
}
|
|
tr th{
|
|
border: 1px solid #eee;
|
|
height:40px;
|
|
background: #EEEEEE;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<table border="0" cellspacing="0" cellpadding="0" width="100%" class="ids" style="border: 1px solid #eee;text-align: center;">
|
|
</table>
|
|
<div id="page"></div>
|
|
</body>
|
|
|
|
<script type="text/javascript">
|
|
var page=1,pages=1, cph='';
|
|
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 getlist(cph){
|
|
let _this=this;
|
|
$.ajax({
|
|
dataType: "json",
|
|
type: "post",
|
|
url:'http://zhyq.toommi.com/api/Index/apppost',
|
|
data: {
|
|
action:'Screen/vehicle_park_list',
|
|
page:page,
|
|
limit:20,
|
|
vehicleNo:cph
|
|
},
|
|
success: function(res) {
|
|
if (res.code == 200) {
|
|
var list =res.data.list;
|
|
var title='<tr>'+'<th>'+'序号'+'</th>'+'<th>'+'车牌号'+'</th>'+'<th>'+'入园目的'+'</th>'+'<th>'+'审核状态'+'</th>'+'<th>'+'申请时间'+'</th>'+'</tr>';
|
|
var ht='';
|
|
pages=res.data.pages;
|
|
for(var i=0;i<list.length;i++){
|
|
if(list[i].mission==1){
|
|
list[i].mudi='转货/卸货'
|
|
}else if(list[i].mission==2){
|
|
list[i].mudi='维修/洗车/停车'
|
|
}else if(list[i].mission==3){
|
|
list[i].mudi='常驻'
|
|
}else if(list[i].mission==4){
|
|
list[i].mudi='维修'
|
|
}else if(list[i].mission==5){
|
|
list[i].mudi='洗车'
|
|
}else if(list[i].mission==6){
|
|
list[i].mudi='停车'
|
|
}else if(list[i].mission==7){
|
|
list[i].mudi='检测'
|
|
}else if(list[i].mission==8){
|
|
list[i].mudi='洗罐'
|
|
}
|
|
if(list[i].status==1){
|
|
list[i].pass='已通过'
|
|
}else if(list[i].status==0){
|
|
list[i].pass='审核中'
|
|
}else{
|
|
list[i].pass='已驳回'
|
|
}
|
|
ht+=
|
|
'<tr>'+'<td>'+Number((page-1)*20+(i+1))+'</td>'+'<td>'+list[i].tractor_license+'</td>'+'<td>'+list[i].mudi+'</td>'+'<td>'+list[i].pass+'</td>'+'<td>'+list[i].create_time+'</td>'+'</tr>'
|
|
}
|
|
var html=title+ht;
|
|
$('table').append(html);
|
|
$("#page").paging({
|
|
nowPage: page, // 当前页码
|
|
pageNum:pages, // 总页码
|
|
buttonNum:5, //要展示的页码数量
|
|
callback: function (num) { //回调函数
|
|
$('table').html('');
|
|
page=num;
|
|
getlist(cph);
|
|
},
|
|
});
|
|
|
|
} else {
|
|
}
|
|
|
|
},
|
|
});
|
|
}
|
|
window.onload=function(){
|
|
var obj=GetRequest();
|
|
cph=decodeURI(obj.cph);
|
|
getlist(cph);
|
|
}
|
|
</script>
|
|
</html>
|