feat: tune visual of web app admin panel, tune limit messages and etc

This commit is contained in:
3252a8
2026-05-12 15:42:17 +03:00
parent 8af59750c6
commit 475a1953d1
34 changed files with 2777 additions and 114 deletions
+4 -2
View File
@@ -314,10 +314,12 @@ class SeverPayService:
user_id=payment.user_id,
amount=float(payment.amount),
currency=payment.currency,
months=int(payment_months) if sale_mode != "traffic" else 0,
traffic_gb=payment_months if sale_mode == "traffic" else None,
months=int(payment_months) if sale_base == "subscription" else 0,
traffic_gb=float(payment_months) if sale_base in {"traffic", "traffic_package", "topup", "premium_topup"} else None,
payment_provider="severpay",
username=db_user.username if db_user else None,
traffic_is_premium=sale_base == "premium_topup",
tariff_key=getattr(payment, "tariff_key", None),
)
except Exception:
logging.exception("SeverPay webhook: failed to notify admins.")