Fix some telegram exceptions while editing the same content + add forward option to users search

This commit is contained in:
hteppl
2025-01-18 04:09:21 +03:00
parent 0ca0d47a7b
commit 347c459c7c
2 changed files with 35 additions and 22 deletions
+10 -11
View File
@@ -27,6 +27,13 @@ def build_user_edit_kb(tg_id: int, key_records: list) -> InlineKeyboardMarkup:
).pack()
)
builder.button(
text="✉️ Сообщение",
callback_data=AdminUserEditorCallback(
action="users_send_message",
tg_id=tg_id
).pack()
)
builder.button(
text="💸 Изменить баланс",
callback_data=AdminUserEditorCallback(
@@ -35,15 +42,7 @@ def build_user_edit_kb(tg_id: int, key_records: list) -> InlineKeyboardMarkup:
).pack()
)
builder.button(
text=" Сообщение",
callback_data=AdminUserEditorCallback(
action="users_send_message",
tg_id=tg_id
).pack()
)
builder.button(
text="🔄 Восстановить триал",
text=" Восстановить триал",
callback_data=AdminUserEditorCallback(
action="users_trial_restore",
tg_id=tg_id
@@ -188,14 +187,14 @@ def build_key_edit_kb(key_details: dict, email: str) -> InlineKeyboardMarkup:
return builder.as_markup()
def build_key_delete_kb(tg_id: int, client_id: str) -> InlineKeyboardMarkup:
def build_key_delete_kb(tg_id: int, email: str) -> InlineKeyboardMarkup:
builder = InlineKeyboardBuilder()
builder.row(
InlineKeyboardButton(
text="✅ Да, удалить",
callback_data=AdminUserEditorCallback(
action="users_delete_key_confirm",
data=client_id,
data=email,
tg_id=tg_id
).pack()
)