old_01
This commit is contained in:
30
doners/Shop-bot/handlers/user/menu.py
Normal file
30
doners/Shop-bot/handlers/user/menu.py
Normal file
@@ -0,0 +1,30 @@
|
||||
|
||||
from aiogram.types import Message, CallbackQuery, ReplyKeyboardMarkup
|
||||
from loader import dp
|
||||
from filters import IsAdmin, IsUser
|
||||
|
||||
catalog = '🛍️ Каталог'
|
||||
balance = '💰 Баланс'
|
||||
cart = '🛒 Корзина'
|
||||
delivery_status = '🚚 Статус заказа'
|
||||
|
||||
settings = '⚙️ Настройка каталога'
|
||||
orders = '🚚 Заказы'
|
||||
questions = '❓ Вопросы'
|
||||
|
||||
@dp.message_handler(IsAdmin(), commands='menu')
|
||||
async def admin_menu(message: Message):
|
||||
markup = ReplyKeyboardMarkup(selective=True)
|
||||
markup.add(settings)
|
||||
markup.add(questions, orders)
|
||||
|
||||
await message.answer('Меню', reply_markup=markup)
|
||||
|
||||
@dp.message_handler(IsUser(), commands='menu')
|
||||
async def user_menu(message: Message):
|
||||
markup = ReplyKeyboardMarkup(selective=True)
|
||||
markup.add(catalog)
|
||||
markup.add(balance, cart)
|
||||
markup.add(delivery_status)
|
||||
|
||||
await message.answer('Меню', reply_markup=markup)
|
||||
Reference in New Issue
Block a user