Kaynağa Gözat

change:充值模板调整;
fix:陆盆地也唤起次数;

Wang Chen 4 yıl önce
ebeveyn
işleme
9f560b80fe

+ 1 - 1
app/Http/Controllers/QuickApp/Order/OrdersController.php

@@ -142,7 +142,7 @@ class OrdersController extends BaseController
                 $template_id = 10679;
             }
 
-            if (in_array($account, ['hanyh', 'liwh', 'caicf', 'wangdd', 'zhangtt'])) {
+            if (in_array($account, ['hanyh', 'liwh', 'caicf', 'wangdd', 'zhangtt', 'hanyh2', 'hanyh33'])) {
                 $template_id = 9999;
             }
         }

+ 69 - 0
app/Libs/Push/VPush/VPush.php

@@ -140,6 +140,66 @@ class VPush
         return $this->getData(config('push.server.vivo.sendAll'), $data);
     }
 
+    /**
+     * 标签推
+     * @param $tag
+     * @return mixed
+     * @throws GuzzleException
+     */
+    public function tagPush($tag)
+    {
+        // 校验参数
+        $this->checkParam();
+        $data = [
+            'requestId'       => Utils::randCode(),
+            'title'           => $this->_title,
+            'content'         => $this->_content,
+            'notifyType'      => $this->_notifyType,
+            'timeToLive'      => $this->_timeToLive,
+            'skipType'        => $this->_skipType,
+            'skipContent'     => $this->_skipContent,
+            'networkType'     => $this->_networkType,
+            'clientCustomMap' => (object)[],
+            'tagExpression'   => [
+                'andTags' => [$tag],
+                'notTags' => [],
+                'orTags'  => []
+            ]
+        ];
+
+        return $this->getData(config('push.server.vivo.tagPush'), $data, 'POST');
+    }
+
+    /**
+     * 新增标签
+     * @param $tag
+     * @return false|mixed
+     * @throws GuzzleException
+     */
+    public function addTag($tag)
+    {
+        if (empty($tag)) {
+            return false;
+        }
+
+        // token授权
+        $this->getAccessToken();
+
+        // 拼接链接
+        $url = config('push.server.vivo.addTag');
+
+        return $this->getData($url, [
+            'name' => $tag
+        ], 'POST');
+    }
+
+    /**
+     * 给用户绑定tag
+     * @param $tag
+     * @param $regIds
+     * @return false|mixed
+     * @throws GuzzleException
+     */
     public function addTagForUsers($tag, $regIds)
     {
         if (empty($tag) || empty($regIds)) {
@@ -148,6 +208,15 @@ class VPush
 
         // token授权
         $this->getAccessToken();
+
+        // 拼接链接
+        $url = config('push.server.vivo.addMembers');
+
+        return $this->getData($url, [
+            'name' => $tag,
+            'type' => 1,
+            'ids'  => $regIds
+        ], 'POST');
     }
 
     /**

+ 3 - 3
resources/views/qapp/start.blade.php

@@ -314,11 +314,11 @@
     function showH5Page() {
         var time = QYY.isIos ? 0 : 5000;
         //2S后自动刷新
-        setTimeout(function () {
+        /* setTimeout(function () {
             if(!getQueryString('isResh')){
                 location.href= window.location.href + '?isResh=1'
             }
-        },1700)
+        },1700) */
         //5秒显示失败页面
         setTimeout(function () {
             $(".content-wrap").show();
@@ -345,7 +345,7 @@
                 appRouter(QYY.packName, "/" + QYY.entry, parmas);
             }else{
                 routerAHap(parmas);
-                appRouter(QYY.packName, "/" + QYY.entry, parmas);
+                //appRouter(QYY.packName, "/" + QYY.entry, parmas);
             }
             //尝试直接拉起
         } catch (e) {