Skip to content
  • P
    Projects
  • G
    Groups
  • S
    Snippets
  • Help

libai / footsen

  • This project
    • Loading...
  • Sign in
Go to a project
  • Project
  • Repository
  • Issues 0
  • Merge Requests 0
  • Pipelines
  • Wiki
  • Snippets
  • Members
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Files
  • Commits
  • Branches
  • Tags
  • Contributors
  • Graph
  • Compare
  • Charts
Switch branch/tag
  • footsen
  • footseen
  • Nesting
  • dew
  • consum.html
Find file
BlameHistoryPermalink
  • dabai's avatar
    footseen h5 移植 · 6161a8cd
    dabai committed 4 years ago
    6161a8cd
consum.html 4.81 KB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no"/>
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
    <meta content="telephone=no" name="format-detection">
    <meta name="wap-font-scale" content="no">
    <link rel="stylesheet" href="css/base.css">
    <link rel="stylesheet" href="css/index.css?v='20180716'">
    <link rel="stylesheet" href="../../css/background.css">
    <script src="lib/fsize.js"></script>
    <title></title>
    <style type="text/css">
    	.cord-ul li{
    		background-color: #11101A;
    	}
    	.cord-ul li img{
    		margin-top: -.1rem;
    	}
    </style>
</head>
<body>
<div style="width: 10rem;" class="bg">
    <ul class="cord-ul">
        <!--<li>-->
            <!--消費 <img src="images/gold.png" alt=""><span class="cord-money"> -99</span>-->
            <!--<span class="cord-Type">這是消費類型</span>-->
            <!--<span class="cord-time">2018-04-28 12:08:54</span>-->
        <!--</li>-->
        <!--<li>-->
            <!--消費 <img src="images/gold.png" alt=""><span class="cord-money"> -99</span>-->
            <!--<span class="cord-Type">這是消費類型</span>-->
            <!--<span class="cord-time">2018-04-28 12:08:54</span>-->
        <!--</li>-->
        <!--<li>-->
            <!--消費 <img src="images/gold.png" alt=""><span class="cord-money"> -99</span>-->
            <!--<span class="cord-Type">這是消費類型</span>-->
            <!--<span class="cord-time">2018-04-28 12:08:54</span>-->
        <!--</li>-->
    </ul>
</div>

</body>
<script src="lib/jquery-3.1.1.min.js"></script>
<script src="../../lib/langchange.js?v=201909121028"></script>

<script>
	 $("title").text(langList[langType].dewconsumTitle);
    //消费记录
    next = false;
    more = true;
    if(sessionStorage.bbb==undefined){
        var bbb = location.href;
        var data = url_get_params(bbb)
        sessionStorage.kkk = data.method; //t
        if(data.method==undefined){
            sessionStorage.kkk=data.token;
        }
        sessionStorage.bbb = data.uid; //u
    }
    function url_get_params(url_path) {
        var url = url_path;
        var theRequest = new Object();
        if (url.indexOf("?") != -1) {
            var str = url.substr(url.indexOf("?") + 1);
            strs = str.split("&");
            for (var i = 0; i < strs.length; i++) {
                theRequest[strs[i].split("=")[0]] = unescape(strs[i].split("=")[1]);
            }
        }
        return theRequest;
    }
    Mpage = 1
    money(Mpage)
    function money(m) {
        $.ajax({
            url: $ip + '/user/getUserFireFlyTrade.html',
            type: "post",
            data: {
                type: 2,
                uid: sessionStorage.bbb,
                lang: sessionStorage.lang,
                page: m,
                pageSize: 15,
                cid: "web_gw",
                os: "WEB",
                token: sessionStorage.kkk
            },
            error: function (msg) {
                console.log('error!');
            },
            success: function (msg) {
                var data = JSON.parse(msg);
                console.log(data);
                var html = [];
                if(data.result.length!=0){
                    for (var i = 0; i < data.result.length; i++) {
                        html+='<li>';
                        html+='<img src="images/gold.png" alt=""><span class="cord-money">' + data.result[i].num + '</span>';
                        html+='<span class="cord-Type" style="'+(langType==2?'direction: rtl;':'')+'">' + data.result[i].title + '</span>';
                        html+='<span class="cord-time">' + data.result[i].times + '</span>';
                        html+='</li>';
                    }
                }else{
                    html+='<div style="text-align: center;padding-top: 2.5rem;">'
                    html+='<img style="width:3.09rem;height:3.42rem;" src="images/no-pay.png" alt="">'
                    html+='<p style="margin-top: 0.5rem;font-size: 0.45rem; color:#B3B3B3;">'+langList[langType].dewconsumno+'</p>'
                    html+='</div> '
                }
                $(".cord-ul").append(html);
                Mpage++;
                next = true;
                if (data.result[14] == null) {
                    more = false;

                }
            }
        })
    }

    var end = 1;
    $(window).bind("scroll", function () {
        if ($(document).scrollTop() + $(window).height() > $(document).height() - 1 && end != 0 && next)// 接近底部100px
        {
            next == false;
            if (more == true) {
                money(Mpage)
            }


        }
    });
</script>
</html>