diff --git a/api/schemas/misc.py b/api/schemas/misc.py index 3537d917..6511c9d4 100644 --- a/api/schemas/misc.py +++ b/api/schemas/misc.py @@ -8,7 +8,14 @@ class PaymentBase(BaseModel): tg_id: int amount: float payment_system: str - status: Literal["success", "pending", "failed"] + status: Literal[ + "awaiting_choice", + "issued", + "processing", + "success", + "failed", + "cancelled", + ] class PaymentResponse(PaymentBase): diff --git a/handlers/payments/cryptobot/handlers.cpython-312-x86_64-linux-gnu.so b/handlers/payments/cryptobot/handlers.cpython-312-x86_64-linux-gnu.so index 7f8cbc32..b4f5ad09 100644 Binary files a/handlers/payments/cryptobot/handlers.cpython-312-x86_64-linux-gnu.so and b/handlers/payments/cryptobot/handlers.cpython-312-x86_64-linux-gnu.so differ diff --git a/middlewares/direct_start_blocker.py b/middlewares/direct_start_blocker.py index 566e9e46..ca7ee338 100644 --- a/middlewares/direct_start_blocker.py +++ b/middlewares/direct_start_blocker.py @@ -108,7 +108,7 @@ class DirectStartBlockerMiddleware(BaseMiddleware): else: ok = ( await session.execute( - select(Gift.id) + select(Gift.gift_id) .where( Gift.gift_id == gift_id, Gift.is_used.is_(False),