allen há 3 anos atrás
pai
commit
994675f9e2
3 ficheiros alterados com 9 adições e 0 exclusões
  1. 3 0
      addDrawCount.sql
  2. 5 0
      app/index/controller/Index.php
  3. 1 0
      app/index/view/video/index.html

+ 3 - 0
addDrawCount.sql

@@ -0,0 +1,3 @@
+
+
+ALTER TABLE `awards_user_info` ADD `draw_count` INT(11)  NULL  DEFAULT '0'  COMMENT '抽奖次数' AFTER `count`;

+ 5 - 0
app/index/controller/Index.php

@@ -483,6 +483,11 @@ class Index extends Controller
      */
     public function getLuckDraw()
     {
+        $userInfo = Db::table('awards_user_info')->where('uid', Safe::$user['uid'])->find();
+        if ($userInfo >= 30) {
+            return $this->response(5002, '抽奖次数已达上线~');
+        }
+
         $orders = Db::table('awards_order')->where('uid', Safe::$user['uid'])->where('type', 1)->find();
         $isWinAward = 0;
         if ($orders) {

+ 1 - 0
app/index/view/video/index.html

@@ -588,6 +588,7 @@
             cdata = `一起来#微博电影之夜# 测测你的影迷DNA吧:https://ac.movie.weibo.com/video 顺道#解锁你的电影彩蛋# 我在微博电影之城集齐全部15枚电影彩蛋。喜提【一代阅片宗师】称号期待大奖降临~`
         }
 
+        cdata = encodeURIComponent(cdata)
 
         var sendArr = ['sinaweibo://sendweibo?content='+cdata+'&pics=%5B%7B%22thumbnail%22%3A%22https%3A%2F%2Fwx1.sinaimg.cn%2Flarge%2F002ckVKbly8h4b2gm1vyaj60kg0w2tfe02.jpg%22%2C%22original%22%3A%22https%3A%2F%2Fwx4.sinaimg.cn%2Flarge%2F002ckVKbly8h4b2gm1vyaj60kg0w2tfe02.jpg%22%2C%22pid%22%3A%22002ckVKbly8h4b2gm1vyaj60kg0w2tfe02%22%7D%5D%0A',