add command params
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
from aiogram.types import Message, CallbackQuery
|
||||
from ..context import CallbackCommand
|
||||
|
||||
from ..navigation import (
|
||||
from ....utils.navigation import (
|
||||
get_navigation_context,
|
||||
save_navigation_context,
|
||||
pop_navigation_context,
|
||||
@@ -41,7 +41,12 @@ async def route_callback(message: Message | CallbackQuery, back: bool = True, **
|
||||
await form_item.entity_item(message, **kwargs)
|
||||
elif context.command == CallbackCommand.FIELD_EDITOR:
|
||||
await editor.field_editor(message, **kwargs)
|
||||
elif context.command == CallbackCommand.USER_COMMAND:
|
||||
import qbot.bot.handlers.user_handlers.main as user_handler
|
||||
|
||||
await user_handler.cammand_handler(
|
||||
message, from_callback_query=True, **kwargs
|
||||
)
|
||||
else:
|
||||
raise ValueError(f"Unknown command {context.command}")
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user