123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289 |
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="UTF-8">
- <title>查看物流</title>
- <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1, user-scalable=no">
- <meta name="apple-mobile-web-app-capable" content="yes">
- <meta name="apple-mobile-web-app-status-bar-style" content="black">
- <link rel="stylesheet" type="text/css" href="//css.iamberry.com/wateroPF/css/mui.min.css">
- <link rel="stylesheet" type="text/css" href="//css.iamberry.com/wateroPF/css/iconfont.css" />
- <link rel="stylesheet" type="text/css" href="//css.iamberry.com/wateroPF/css/style.css" />
- <style>
- body{ text-align:center}
- article, section, time, aside {
- display: block;
- }
- .point-time {
- content: "";
- position: absolute;
- width: 13px;
- height: 13px;
- top: 12px;
- left: 30%;
- background: #1c87bf;
- margin-left: -4px;
- border-radius: 50%;
- box-shadow: 0 0 0 2px #fff;
- }
- .text-red {
- color: #ff5b5b;
- }
- .text-blue {
- color: #1c87bf;
- }
- .text-green {
- color: #95c91e;
- }
- .text-yellow {
- color: #ffb902;
- }
- .text-purple {
- color: #d32d93;
- }
- .point-red {
- background-color: #ff5b5b;
- }
- .point-blue {
- background-color: #38d1f7;
- }
- .point-green {
- background-color: #95c91e;
- }
- .point-yellow {
- background-color: #ffb902;
- }
- .point-purple {
- background-color: #d32d93;
- }
- .content {
- width: 100%;
- margin: 0 auto;
- }
- .content article {
- position: relative;
- }
- .content article > h3 {
- width: 100%;
- height: 20px;
- line-height: 20px;
- text-align: left;
- text-indent: 3%;
- font-size: 1.4em;
- color: #fff;
- padding: 10px 0 20px;
- background-color: #dd6d01;
- }
- .content article section {
- padding: 0 10px 10px;
- position: relative;
- }
- .content article section:before {
- content: "";
- width: 2px;
- top: 17px;
- bottom: -17px;
- left: 30.54%;
- background: #73dff9;
- position: absolute;
- -webkit-transform: scaleX(.5);
- }
- .content article section:last-child:before {
- display: none;
- }
- .content article section time {
- width: 25%;
- display: block;
- position: absolute;
- padding: 8px 0;
- }
- .content article section time > span {
- display: block;
- text-align: center;
- }
- .content article section aside {
- color: #3a3a38;
- margin-left: 42%;
- padding-bottom: 15px;
- text-align: left;
- }
- .content article section .brief {
- color: #9f9f9f;
- }
- .my-box-w{position: absolute;left: 50%;top: 50%;background: rgba(255,255,255,.1);width: 100px;height: 100px;border-radius: 50%;margin-left: -50px;margin-top: -60px;padding: 8px;}
- .my-box-n{background: rgba(255,255,255,.2);position: relative;height: 100%;width: 100%;border-radius: 50%;}
- .my-box-machine{position: absolute;left: 50%;top: 50%;width: auto;color: #fff;-webkit-transform:translateX(-50%) translateY(-20%);}
- .machine-num{position: absolute;left: 50%;top: 50%;margin-top:40px;-webkit-transform: translateX(-50%);color: #fff;}
- </style>
- <script>
- // 屏蔽分享
- window.hiddenAllWechatMenu = true;
- </script>
- </head>
- <body style="background: #fff;">
- <!-- <div class="loading-bg">
- <div class="mui-loading">
- <div class="mui-spinner">
- </div>
- 加载中...
- </div>
- </div> -->
- <div class="mui-content" style="background: #fff;">
- <div style="position: relative;height: 100px;padding:20px 15px;background: #6bc5e3;">
- <img style="float: left;" width="60px" src="//s.iamberry.com/wateroPF/new/images/logistics.png">
- <ul style="display: inline-block;float: left;text-align: left;color: #fff;line-height: 30px;padding: 0 0 0 10px;">
- <li id="billName"></li>
- <li>单号:<span id="billCode"></span></li>
- </ul>
- </div>
- <div id="pullrefresh" class="content">
- <article class="my-tab-view-pull">
- </article>
- </div>
- <div id="orderlist" class="content" style="display:none;padding: 10px 0;">
- 暂无物流信息
- </div>
- </div>
- <script src="//s.iamberry.com/wateroPF/js/mui.min.js"></script>
- <script src="//s.iamberry.com/wateroPF/js/jquery-2.1.1.min.js"></script>
- <script src="//s.iamberry.com/wateroPF/js/shop/main.js"></script>
- <!-- <script src="//s.iamberry.com/wateroPF/js/shop/wechat-utils-1.0.js"></script> -->
- <script type="text/javascript">
- function pullupRefresh() {
- var billCode = getParam("billCode"),billName = getParam("billName");
- mui.ajax(domanUrl + '/wateroPF/logistics/getExpressInfo?dates=' + new Date().getTime(), {
- data: {
- "com": billName,
- "nu": billCode
- },
- dataType: 'json',
- type: 'post',
- timeout: 15000,
- success: function(dt) {
- console.log(dt);
- if(dt.status) {
- var name='';
- switch (billName){
- case "sto":
- name= "申通快递";
- break;
- case "yto":
- name= "圆通快递";
- break;
- case "zto":
- name= "中通速递";
- break;
- case "sf":
- name= "顺丰快递";
- break;
- case "ems":
- name= "邮政EMS";
- break;
- case "eyb":
- name= "E邮宝";
- break;
- case "zjs":
- name= "宅急送";
- break;
- case "yunda":
- name= "韵达快递";
- break;
- case "cces":
- name= "cces快递";
- break;
- case "pick":
- name= "上门提货";
- break;
- case "htky":
- name= "汇通快递";
- break;
- case "ttkdex":
- name= "天天快递";
- break;
- case "stars":
- name= "星晨急便";
- break;
- case "jd":
- name= "京东快递";
- break;
- case "01":
- name= "其他";
- break;
- case "02":
- name= "上门送货";
- break;
- case "longbanwuliu":
- name= "龙邦快递";
- break;
- default:
- break;
- }
- $("#billName").text(name);
- $("#billCode").text(billCode);
- if(dt.data.status=="1"){
- var renewal_data = [];
- renewal_data = dt.data.data;
- var table = document.body.querySelector('.my-tab-view-pull');
- mui(renewal_data).each(function(index) {
- var li = document.createElement('section');
- var color='point-blue',text='';
- if(index==0){
- color='point-red';
- //text="text-red";
- }
- li.innerHTML = ' <span class="point-time '+color+'"></span><time class="'+text+'">'+this.time+'</time><aside><p class="things">'+this.location+'</p><p class="brief" style="padding-top: 4%;">'+this.context+'</p></aside>';
- table.appendChild(li);
- })
- }else{
- $("#orderlist").show();
- }
- }else{
- $("#pullrefresh").hide();
- $("#orderlist").show();
- }
- },
- error: function(xhr, type, errorThrown) {
- console.log(xhr)
- }
- });
- }
- mui.ready(function(){
- //页面首次加载时拉取一次数据
- pullupRefresh();
- });
- function format(now) {
- now = new Date(now);
- var year=now.getFullYear();
- var month=now.getMonth()+1;
- var date=now.getDate();
- var hour=now.getHours();
- var minute=now.getMinutes();
- var second=now.getSeconds();
- if(month <10 && month > 0){
- month = "0"+month;
- }
- if(date <10 && date > 0){
- date = "0"+date;
- }
- return year+"-"+month+"-"+date;
- }
- </script>
- </body>
- </html>
|