| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172 |
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="utf-8">
- <meta name="referrer" content="origin">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
- <meta content="telephone=no" name="format-detection" />
- <title>我的账号</title>
- <style>
- *{
- margin:0;
- padding:0;
- font:16px/1.5 Arial, '\5FAE\8F6F\96C5\9ED1';
- color:#000;
- }
- img{
- border:none;
- vertical-align:middle;
- }
- a{
- text-decoration:none;
- }
- a:hover{
- text-decoration:none;
- }
- body{
- background:#fff;
- }
- ul,li{list-style:none;}
- .header{
- padding:10px 5px 10px 15px;
- font-weight:bold;
- }
- .header img{
- width: 40px;
- height: 40px;
- border-radius: 50%;
- }
- .header .coin{
- font-weight:bold;
- }
-
- .header .user-id{
- float:right;
- line-height:40px;
- margin-right:15px;
- }
- .line{
- background:#eee;
- height:10px;
- }
- .content{
-
- }
- .list{
-
- }
- .list li{
- padding:10px 15px;
- border-bottom:1px solid #eee;
- }
- .list li.on{
- border:1px solid #FED25C;
- }
-
- .list li:after{
- content:".";
- display:block;
- height:0;
- clear:both;
- visibility:hidden;
- overflow:hidden;
- }
- .list li .li-left{
- float:left;
- line-height:30px;
- font-size:16px;
- }
- .list li .li-left img{
- width:20px;
- height:20px;
- margin-right:5px;
- }
- .list li .li-left span{
- font-size:14px;
- }
- .list li .li-right{
- float:right;
- }
- .list li .li-right a{
- display:block;
- background:#FED25C;
- border-radius:4px;
- padding:5px 10px;
- text-align:center;
- font-weight:bold;
- width:70px;
- }
- .footer{
- text-align:center;
-
- }
- .footer a{
- color:#3e97f8;
- line-height:50px;
- margin-left:3px;
- margin-right:3px;
- }
- </style>
- </head>
- <body >
- <div class="header">
- 充值账号:<img src="{$userinfo['avatar_thumb']}"> <span class="coin">{$userinfo['user_nickname']}</span> <span class="user-id">ID:{$userinfo['id']}</span>
- </div>
- <div class="header">
- 余额: <span class="coin">{$userinfo['coin']|default=0}</span>
- </div>
- <div class="line"></div>
- <div class="line"></div>
-
- <div class="content">
- <ul class="list">
- <volist name="chargelist" id="v">
- <li data-price="{$v['money']}" data-id="{$v['id']}">
- <div class="li-left">
- <img src="__STATIC__/wxshare/share/images/coin.png"> {$v['coin']} <if condition="$v['give'] gt 0"><span>赠送{$v['give']}</span></if>
- </div>
- <div class="li-right">
- <a href="javascript:void(0);" data-price="{$v['money']}">
- ¥{$v['money']}
- </a>
- </div>
- </li>
- </volist>
- </ul>
- </div>
- <div class="footer">
-
- </div>
-
- <script src="__STATIC__/js/jquery.js"></script>
- <script>
- $(function(){
- $(".content .list li").on("click",function(){
-
- var money=$(this).attr("data-price");
- var chargeid=$(this).attr("data-id");
- $.ajax({
- url:'/wxshare/Share/getOrderId',
- data:{ chargeid: chargeid },
- dataType:'json',
- success:function(data){
- console.log(data);
- if(data.code == 0) {
- location.href='/wxpay/jsapi-wx.php?uid='+data.data.uid+'&money='+data.data.money+'&orderid='+data.data.orderid;
- return !1;
- } else {
- alert(data.msg);
- }
- },
- error:function(e){
- console.log(e);
- }
-
- })
- })
- })
- </script>
- </body>
- </html>
|