예제 #1
0
def set_group(message):
    # arguments = []
    # print(message.text.split(" ")[1:])
    arguments = message.text.split(" ")[1:]
    print(arguments)
    arguments.insert(2, arguments.pop(0))
    print(arguments)
    print(
        st.update_tg_login(arguments[0], arguments[1], arguments[2],
                           message.chat.username))
    bot.send_message(
        message.chat.id,
        st.update_tg_login(arguments[0], arguments[1], arguments[2],
                           message.chat.username))
예제 #2
0
def set_group(message):
    args = Utils.get_args_from_message(message)
    user_login = message.from_user.username
    if len(args) < 3:
        bot.send_message(message.chat.id, CommonMessages.invalid_arguments)
        UserStatus.del_user_status(user_login)
        return
    response = Students.update_tg_login(
        args[1], args[2], args[0], message.chat.id,
        message.from_user.username)  # name, surname, group, username
    bot.send_message(message.chat.id, response)
    UserStatus.del_user_status(user_login)
예제 #3
0
def testSt_u_TG_Login():
    st.update_tg_login("Stashevskii", "Ian", "3530904/70105", "@Animehin")