Переглянути джерело

'修复加脚本增加华为'

zhuchengjie 3 роки тому
батько
коміт
89d551b854
1 змінених файлів з 4 додано та 0 видалено
  1. 4 0
      app/Console/Commands/Push/PushTagBind.php

+ 4 - 0
app/Console/Commands/Push/PushTagBind.php

@@ -4,6 +4,7 @@ namespace App\Console\Commands\Push;
 
 
 use App\Consts\PushConst;
+use App\Libs\Push\HuaWei\HwPushCommon;
 use App\Libs\Push\VPush\VPush;
 use App\Libs\Push\OPPOPush\OPPOPushCommon;
 use App\Modules\Push\Services\PushAppService;
@@ -71,6 +72,9 @@ class PushTagBind extends Command
                 }elseif ($provider === PushConst::PROVIDER_VIVO) {
                     $client = new VPush($appId, $appKey, $appSecret);
                     $client->addTagForUsers($tag, $regIds);
+                } else if ($provider === PushConst::PROVIDER_HW) {
+                    $client = new HwPushCommon($appId, $appSecret);
+                    $client->subscribeTopic($tag, $regIds);
                 }
             }