feat(bot): implement admin review bot, inline keyboards and channel config
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
from typing import List
|
||||
from telethon import Button
|
||||
from db.models import TargetChannel
|
||||
|
||||
def get_review_keyboard(post_id: int, targets: List[TargetChannel]) -> List[List[Button]]:
|
||||
keyboard = []
|
||||
# Add a button for each target channel
|
||||
for target in targets:
|
||||
title = target.title or f"Target #{target.id}"
|
||||
keyboard.append([
|
||||
Button.inline(f"🚀 Send to {title}", data=f"appr:{post_id}:{target.id}")
|
||||
])
|
||||
|
||||
# Add Reject button
|
||||
keyboard.append([
|
||||
Button.inline("❌ Reject Post", data=f"rej:{post_id}")
|
||||
])
|
||||
return keyboard
|
||||
Reference in New Issue
Block a user