send
This commit is contained in:
@@ -49,23 +49,29 @@ class Daemon(base.BaseDaemon, queues.TasksHandlerMixin):
|
||||
|
||||
def reply(self, text: str, chat_id: int, message_id: int):
|
||||
queues.set_task(
|
||||
'pizda_bot_mailbox',
|
||||
'botalka_mailbox',
|
||||
{
|
||||
'action': 'reply',
|
||||
'message': text,
|
||||
'reply_to': message_id,
|
||||
'chat_id': chat_id
|
||||
'project': 'pizda-bot',
|
||||
'name': 'telegram-bot',
|
||||
'body': {
|
||||
'message': text,
|
||||
'reply_to_message_id': message_id,
|
||||
'chat_id': chat_id,
|
||||
}
|
||||
},
|
||||
1,
|
||||
)
|
||||
|
||||
def send(self, text: str, chat_id: int):
|
||||
queues.set_task(
|
||||
'pizda_bot_mailbox',
|
||||
'botalka_mailbox',
|
||||
{
|
||||
'action': 'send',
|
||||
'message': text,
|
||||
'chat_id': chat_id
|
||||
'project': 'pizda-bot',
|
||||
'name': 'telegram-bot',
|
||||
'body': {
|
||||
'message': text,
|
||||
'chat_id': chat_id,
|
||||
}
|
||||
},
|
||||
1,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user