Fix: missing
Browse files- akn/manage/bots_manage.py +13 -11
akn/manage/bots_manage.py
CHANGED
@@ -417,15 +417,17 @@ async def delete_confirmationdl(client: Client, callback: CallbackQuery):
|
|
417 |
if result.modified_count == 1:
|
418 |
await callback.message.edit_text(
|
419 |
"ποΈ **Bot Deleted**\n\n"
|
420 |
-
f"All data for `{bots_uuid}` has been removed"
|
|
|
421 |
reply_markup=InlineKeyboardMarkup([
|
422 |
-
[InlineKeyboardButton("
|
423 |
])
|
424 |
)
|
425 |
await notify_admins(
|
426 |
-
|
427 |
-
f"
|
428 |
-
|
|
|
429 |
user_id=user_id,
|
430 |
bots_uuid=bots_uuid
|
431 |
)
|
@@ -442,7 +444,6 @@ async def delete_confirmationdl(client: Client, callback: CallbackQuery):
|
|
442 |
f"π§ Error: <code>{str(e)}</code>"
|
443 |
)
|
444 |
|
445 |
-
|
446 |
@ren.on_callback_query(filters.regex(r"^resubmitdl_(\w+)$"))
|
447 |
async def xresubmission(client: Client, callback: CallbackQuery):
|
448 |
try:
|
@@ -609,7 +610,8 @@ async def confirm_resubmission(client: Client, callback: CallbackQuery):
|
|
609 |
])
|
610 |
)
|
611 |
await notify_admins(
|
612 |
-
|
|
|
613 |
user_id=user_id,
|
614 |
bots_uuid=bots_uuid
|
615 |
)
|
@@ -626,16 +628,16 @@ async def confirm_resubmission(client: Client, callback: CallbackQuery):
|
|
626 |
f"π§ Error: <code>{str(e)}</code>"
|
627 |
)
|
628 |
|
629 |
-
async def notify_admins(message, user_id, bots_uuid):
|
630 |
admin_buttons = InlineKeyboardMarkup([
|
631 |
[InlineKeyboardButton("β
Approve", callback_data=f"approved_alldl_{user_id}_{bots_uuid}"),
|
632 |
InlineKeyboardButton("β Reject", callback_data=f"rejected_alldl_{user_id}_{bots_uuid}")],
|
633 |
[InlineKeyboardButton("π€ View User", url=f"tg://user?id={user_id}")]
|
634 |
])
|
635 |
return await client.send_message(
|
636 |
-
|
637 |
-
|
638 |
-
|
639 |
)
|
640 |
|
641 |
@ren.on_callback_query(filters.regex(r"^cancel_resubmitdl_"))
|
|
|
417 |
if result.modified_count == 1:
|
418 |
await callback.message.edit_text(
|
419 |
"ποΈ **Bot Deleted**\n\n"
|
420 |
+
f"All data for `{bots_uuid}` has been removed\n"
|
421 |
+
f"Average review time: 24-48 hours",
|
422 |
reply_markup=InlineKeyboardMarkup([
|
423 |
+
[InlineKeyboardButton("Β« Back", callback_data="customzie_bot")],
|
424 |
])
|
425 |
)
|
426 |
await notify_admins(
|
427 |
+
client=client,
|
428 |
+
message=f"ποΈ <b>Bot Deleted</b>\n\n"
|
429 |
+
f"User: {user_mention}\n"
|
430 |
+
f"UUID: {bots_uuid}\n",
|
431 |
user_id=user_id,
|
432 |
bots_uuid=bots_uuid
|
433 |
)
|
|
|
444 |
f"π§ Error: <code>{str(e)}</code>"
|
445 |
)
|
446 |
|
|
|
447 |
@ren.on_callback_query(filters.regex(r"^resubmitdl_(\w+)$"))
|
448 |
async def xresubmission(client: Client, callback: CallbackQuery):
|
449 |
try:
|
|
|
610 |
])
|
611 |
)
|
612 |
await notify_admins(
|
613 |
+
client=client,
|
614 |
+
message=f"Bot resubmitted: {bots_uuid} by {callback.from_user.mention}",
|
615 |
user_id=user_id,
|
616 |
bots_uuid=bots_uuid
|
617 |
)
|
|
|
628 |
f"π§ Error: <code>{str(e)}</code>"
|
629 |
)
|
630 |
|
631 |
+
async def notify_admins(client, message, user_id, bots_uuid):
|
632 |
admin_buttons = InlineKeyboardMarkup([
|
633 |
[InlineKeyboardButton("β
Approve", callback_data=f"approved_alldl_{user_id}_{bots_uuid}"),
|
634 |
InlineKeyboardButton("β Reject", callback_data=f"rejected_alldl_{user_id}_{bots_uuid}")],
|
635 |
[InlineKeyboardButton("π€ View User", url=f"tg://user?id={user_id}")]
|
636 |
])
|
637 |
return await client.send_message(
|
638 |
+
PRIVATE_LOGS,
|
639 |
+
text=message,
|
640 |
+
reply_markup=admin_buttons
|
641 |
)
|
642 |
|
643 |
@ren.on_callback_query(filters.regex(r"^cancel_resubmitdl_"))
|