feat: admin product deletion
This commit is contained in:
@@ -79,3 +79,16 @@ def edit_product(product: Product):
|
||||
[InlineKeyboardButton(text="⬅️", callback_data=f"cat:{product.category_id}")],
|
||||
]
|
||||
).as_markup()
|
||||
|
||||
|
||||
def confirm_product_deletion(product_id: int) -> InlineKeyboardMarkup:
|
||||
return InlineKeyboardBuilder(
|
||||
[
|
||||
[
|
||||
InlineKeyboardButton(
|
||||
text="✅ Да, удалить", callback_data=f"delete_product:confirm:{product_id}"
|
||||
),
|
||||
InlineKeyboardButton(text="❌ Отмена", callback_data=f"product:{product_id}"),
|
||||
]
|
||||
]
|
||||
).as_markup()
|
||||
|
||||
Reference in New Issue
Block a user