Ken 1 долоо хоног өмнө
parent
commit
8906164419

+ 1 - 1
app/Jobs/SendTelegramGroupMessageJob.php

@@ -43,7 +43,7 @@ class SendTelegramGroupMessageJob implements ShouldQueue
     {
 
         try {
-            BaseService::bettingGroupNotice($this->text, $this->buttons, $this->image, $this->isTop);
+            BaseService::bettingGroupNotice($this->text, $this->buttons, $this->image, $this->isTop,$this->separator);
         } catch (\Telegram\Bot\Exceptions\TelegramResponseException $e) {
             // // 捕获 Too Many Requests
             // if (str_contains($e->getMessage(), 'Too Many Requests')) {

+ 5 - 4
app/Services/BaseService.php

@@ -191,12 +191,13 @@ class BaseService
 
     /**
      * @description: 群组通知
-     * @param {string} $text 通知内容
-     * @param {array} $keyboard 操作按钮
-     * @param {*string} $image  图片
+     * @param string $text 通知内容
+     * @param array $keyboard 操作按钮
+     * @param string $image 图片
      * @param string $separator 分隔符
+     * @param boolean $isTop 是否置顶
      */
-    public static function bettingGroupNotice($text, $keyboard = [], $image = '', $isTop = false, string $separator = "\n"): void
+    public static function bettingGroupNotice(string $text, array $keyboard = [], string $image = '', $isTop = false, string $separator = "\n"): void
     {
         $bettingGroup = Config::where('field', 'betting_group')->first()->val;
         $array = explode($separator, $text);