fix(tgbot): restore the admin's client link and QR buttons (#6986)

The v3.11.0 bot rebuild left the admin's client card without the subscription link, individual links and QR code, so an admin could not hand a config to a client who cannot reach Telegram yet. The card now carries Links and QR code buttons that open the existing screens. Closes #6984.
This commit is contained in:
25f2002654
2026-11-03 20:22:35 +05:30
committed by GitHub
parent 19f2f21d81
commit 83ea59fb69
6 changed files with 163 additions and 6 deletions
@@ -140,6 +140,12 @@ func (t *Tgbot) clientRows(email string) [][]telego.InlineKeyboardButton {
t.btn("tgbot.buttons.setTGUser", t.encodeQuery("tg_user "+email)),
t.btn("tgbot.buttons.inviteLink", t.encodeQuery("client_invite_link "+email)),
),
// An invite link needs the client to reach Telegram; a subscription URL
// and a QR code do not, so they are the admin's way to hand one over.
tu.InlineKeyboardRow(
t.btn("tgbot.buttons.links", t.encodeQuery("client_sub_links "+email)),
t.btn("tgbot.buttons.qrCode", t.encodeQuery("client_qr_links "+email)),
),
tu.InlineKeyboardRow(t.btn("tgbot.buttons.toggle", t.encodeQuery("toggle_enable "+email))),
t.backRow(),
}