def bot_delete(message): if message.text == '/delete': bot.send_chat_action(message.chat.id, 'typing') bot.send_message(message.chat.id, '/delete 123456789\n像这样把汝的运单编号加到 /delete 之后就好啦~/') else: msg = kuaidi100.delete(message.text[8:]) bot.send_chat_action(message.chat.id, 'typing') bot.send_message(message.chat.id, msg)
def bot_quick_delete(message): if message.reply_to_message is None: bot.send_chat_action(message.chat.id, 'typing') bot.send_message(message.chat.id, utils.reply_refuse()) else: s = message.reply_to_message.text msg = kuaidi100.delete(s.split()[0]) bot.send_chat_action(message.chat.id, 'typing') bot.send_message(message.chat.id, msg)
def bot_delete(message): if message.text == '/delete': bot.send_chat_action(message.chat.id, 'typing') bot.send_message( message.chat.id, '`/delete 123456789`\n像这样把汝的运单编号加到 `/delete` 之后就好啦~/', parse_mode='Markdown') else: msg = kuaidi100.delete(message.text[8:]) bot.send_chat_action(message.chat.id, 'typing') bot.send_message(message.chat.id, msg)