|
|
@@ -28,8 +28,9 @@ class SendTelegramMessageJob implements ShouldQueue
|
|
|
* @param array $buttons
|
|
|
* @param string|null $image
|
|
|
*/
|
|
|
- public function __construct( $text, $buttons = [], $image = null ,$isTop = false)
|
|
|
+ public function __construct($chatId, $text, $buttons = [], $image = null ,$isTop = false)
|
|
|
{
|
|
|
+ $this->chatId = $chatId;
|
|
|
$this->text = $text;
|
|
|
$this->buttons = $buttons;
|
|
|
$this->image = $image;
|
|
|
@@ -39,7 +40,7 @@ class SendTelegramMessageJob implements ShouldQueue
|
|
|
public function handle()
|
|
|
{
|
|
|
try {
|
|
|
- BaseService::bettingGroupNotice($this->text, $this->buttons, $this->image,$this->isTop);
|
|
|
+ BaseService::sendMessage($this->chatId ,$this->text, $this->buttons, $this->image);
|
|
|
} catch (\Telegram\Bot\Exceptions\TelegramResponseException $e) {
|
|
|
// 捕获 Too Many Requests
|
|
|
if (str_contains($e->getMessage(), 'Too Many Requests')) {
|