Product edition

This commit is contained in:
Artyom Ashirov
2024-11-16 17:53:43 +03:00
parent 772cd738ca
commit ec96f67dfe
2 changed files with 176 additions and 3 deletions

View File

@@ -100,6 +100,11 @@ bot.on('message', async (msg) => {
return;
}
// Check for product edition
if (await adminProductHandler.handleProductEditImport(msg)) {
return;
}
logDebug(msg.text, 'handleMessage');
switch (msg.text) {
@@ -278,6 +283,9 @@ bot.on('callback_query', async (callbackQuery) => {
} else if (action.startsWith('view_product_')) {
logDebug(action, 'handleViewProduct');
await adminProductHandler.handleViewProduct(callbackQuery);
} else if (action.startsWith('edit_product_')) {
logDebug(action, 'handleProductEdit');
await adminProductHandler.handleProductEdit(callbackQuery)
} else if (action.startsWith('delete_product_')) {
logDebug(action, 'handleViewProduct');
await adminProductHandler.handleProductDelete(callbackQuery);