from vkwave.bots import DefaultRouter, SimpleBotEvent, simple_bot_message_handler, PayloadContainsFilter, BotEvent, \
    EventTypeFilter
from vkwave.types.bot_events import BotEventType

import locales

teacher_router = DefaultRouter()


@teacher_router.registrar.with_decorator(
    EventTypeFilter(BotEventType.MESSAGE_NEW.value),
    PayloadContainsFilter("teacher"),
)
async def teacher_menu(event: BotEvent):
    sevent = SimpleBotEvent(event)
    return await sevent.answer(
        message=locales.TC_MENU,
        keyboard=locales.TC_KB.get_keyboard(),
    )