stanley-king 7 lat temu
rodzic
commit
da234c69f7

+ 71 - 10
data/resource/mobile/invite_friend/css/main.css

@@ -151,22 +151,23 @@ html {
     box-sizing: border-box;
 }
 .total {
-    font-size: 20px;
+    font-size: 36px;
     margin-bottom: 18px;
+    color: #f7dd92;
 }
-.price {
+.total .price {
     display: inline-block;
-    background: #f0d179;
     font-size: 48px;
-    padding: 0 17px;
-    color: #ec374e;
-    margin:0 5px;
+    padding-left: 20px;
+    padding-right: 3px;
+    position: relative;
+    top: 3px;
 }
 .bonus_label {
     font-size: 25px;
-    margin-bottom: 9px;
     box-sizing: content-box;
     padding-right: 35px;
+    margin: 23px 73px 13px 0;
 }
 .more_btn {
     box-sizing: content-box;
@@ -191,12 +192,29 @@ html {
     background: #f48897;
     border-radius: 8px;
     padding: 7px 37px 30px 24px;
+    position: relative;
+}
+.bonus_list .bonus_pro {
+    position: absolute;
+    width: 226px;
+    height: 55px;
+    line-height: 55px;
+    color: #ec354e;
+    text-align: center;
+    background: #fff;
+    top: -55px;
+    left: 15px;
+    font-size: 30px;
+    border-top-left-radius:10px;
+    border-top-right-radius:10px;
 }
 .item {
     position: relative;
     height: 113px;
     display: -webkit-box;
     -webkit-box-align: center;
+    cursor: pointer;
+    -webkit-tap-highlight-color: rgba(0,0,0,0.8);
 }
 .item .user_img img{
     width: 60px;
@@ -207,7 +225,7 @@ html {
     margin-right: 17px;
 }
 .item .user_name {
-    width: 160px;
+    width: 508px;
     font-size: 30px;
 }
 .item .bonus_pro {
@@ -242,12 +260,14 @@ html {
     height: 39px;
     background: url("../images/bag.png") no-repeat;
     background-size: 100%;
+    position: relative;
+    top: 4px;
 }
 .rules {
     position: absolute;
     font-size: 25px;
-    right: -13px;
-    top: 251px;
+    right: 3px;
+    top: -52px;
     padding: 10px;
 }
 .pop {
@@ -296,3 +316,44 @@ html {
     font-size: 32px;
     margin-top: 24px;
 }
+.arrow {
+    display: inline-block;
+    width: 40px;
+    height: 40px;
+    background: url("../images/arrow.png") no-repeat;
+    background-size: 100%;
+}
+.invite_msg {
+    font-size: 20px;
+    margin-top: 10px;
+}
+.invite_msg span.price {
+    color: #f7dd92;
+}
+@-webkit-keyframes coin {
+    0% {
+        opacity: 0;
+        -webkit-transform: rotateY(0deg);
+    }
+    100% {
+        opacity: 1;
+        -webkit-transform: rotateY(360deg);
+    }
+}
+.gold_coin{
+    -webkit-animation: coin 1s ease-out ;
+}
+.open_bouns{
+    position: absolute;
+    width: 150px;
+    height: 150px;
+    left: 50%;
+    bottom: 0;
+    margin-left: -75px;
+    background: url(../images/icon_open.png) no-repeat;
+    background-size: 100% 100%;
+}
+.open_bouns_link {
+    position: relative;
+    height: 200px;
+}

BIN
data/resource/mobile/invite_friend/images/arrow.png


BIN
data/resource/mobile/invite_friend/images/center_bg.jpg


BIN
data/resource/mobile/invite_friend/images/icon_open.png


+ 2 - 0
helper/predeposit_helper.php

@@ -745,6 +745,8 @@ class predeposit_helper
                 return "评论奖励红包";
             case bonus\type::MakeInviteRewardType:
                 return "邀请好友,奖励红包";
+            case bonus\type::MakeVoteType:
+                return "投票或答题红包";
             default:
                 return "";
         }

+ 20 - 15
mobile/control/invite_friend.php

@@ -109,12 +109,8 @@ class tpl_invite_friend
                         <div class=\"user_name\">{$minfo->nickname()}</div>
                     </div>
                     <div class=\"get_bonus\">
+                        <div class=\"bonus_label\">累计收益</div>
                         <div class=\"total\"><span class=\"bag_icon\"></span><span class=\"price\">{$minfo->reward_amount()}</span>元</div>
-                        <div class=\"bonus_label\">累计获得100%红包</div>
-                        <div class=\"more_btn\">
-                            <a href=\"javascript:void(0)\">查看更多余额>></a>
-                        </div>
-                        <span class=\"rules\" id=\"rules\">查看规则>></span>
                     </div>
                 </div>";
         echo $str;
@@ -123,25 +119,34 @@ class tpl_invite_friend
     private function show_bonus()
     {
         $url = url_helper::bonus_grab_url($this->mTypesn);
+        echo "<div class=\"open_bouns_link\">
+                <span id=\"coin\" class=\"open_bouns\"></span>
+              </div>";
+
     }
 
     private function show_invitees()
     {
         echo "<div class=\"bonus_list\">";
+        echo "<div class=\"bonus_pro\">赚红包记录</div>
+              <span class=\"rules\" id=\"rules\">查看规则>></span>";
         foreach ($this->mInvitees as $minfo)
         {
+            $user = $minfo->member_id();
+            $url = BASE_SITE_URL . "/mobile/index.php?act=invite_friend&op=index&client_type=wap&relay_id={$user}";
             $str = "<div class=\"item\">
-                        <div class=\"user_img\">
+                        <a href=\"{$url}\">
+                            <div class=\"user_img\">
                             <img src=\"{$minfo->avatar()}\">
-                        </div>
-                        <div class=\"user_name text-overflow\">
-                            {$minfo->nickname()}
-                        </div>
-                        <div class=\"bonus_pro text-overflow\">
-                        </div>
-                        <div class=\"bonus_price text-overflow\">
-                            <span>{$minfo->reward_amount()}</span>元
-                        </div>
+                            </div>
+                            <div class=\"user_name text-overflow\">
+                              <p class=\"text-overflow\"> {$minfo->nickname()}</p>
+                              <p class=\"invite_msg\">已邀请{$minfo->invitees()}人,收益<span class=\"price\">{$minfo->reward_amount()}</span>元</p>
+                            </div>
+                            <div class=\"look_btn\">
+                                <span class=\"arrow\"></span>
+                            </div>
+                        </a>
                     </div>";
             echo $str;
         }

+ 1 - 1
mobile/control/member_bonus.php

@@ -951,7 +951,7 @@ class member_bonusControl extends mbMemberControl
             case bonus\type::MakeShakeGainType: //摇
                 return $type->sender_name();
             case bonus\type::MakeVoteType:
-                return "投票答题红包";
+                return "投票答题红包";
             case bonus\type::MakeEvaluateType:
             case bonus\type::MakeInviteType:
             case bonus\type::MakeBonusRefundType: //退

+ 9 - 2
mobile/templates/default/invite_friend/invite.php

@@ -54,6 +54,7 @@
         </div>
     </div>
 </div>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/mobile/bonus/js/zepto.min.js?<?php echo bonus_version(); ?>"></script>
 <script type="text/javascript">
     window.onload = function(){
         var window_no_scroll = function(e){
@@ -62,8 +63,7 @@
             }
             e.preventDefault();
         };
-        document.getElementById('rules').addEventListener('touchend',function(e){
-            e.preventDefault();
+        document.getElementById('rules').addEventListener('click',function(e){
             document.getElementById('pop').style.display = 'block';
             window.addEventListener('touchmove',window_no_scroll);
         });
@@ -72,6 +72,13 @@
             document.getElementById('pop').style.display = 'none';
             window.removeEventListener('touchmove',window_no_scroll);
         });
+        $('.open_bouns').on('click',function(){
+            $(this).addClass('gold_coin');
+            var grab_url='http://www.baidu.com';
+            setTimeout(function(){
+                window.location.href=grab_url;
+            },300);
+        });
     }
 </script>
 <script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js?<?php echo bonus_version(); ?>"></script>