aboutsummaryrefslogtreecommitdiff
path: root/models/payment.py
diff options
context:
space:
mode:
authorTolmachev Igor <me@igorek.dev>2026-03-22 19:56:47 +0300
committerTolmachev Igor <me@igorek.dev>2026-03-22 20:19:27 +0300
commit536d022e8a55f6e53f01dfb7e0fae2ef24385aad (patch)
tree721d7195db7fc12c725b27301f77e345df64d1b4 /models/payment.py
downloadvpn_manager_bot-536d022e8a55f6e53f01dfb7e0fae2ef24385aad.tar.gz
vpn_manager_bot-536d022e8a55f6e53f01dfb7e0fae2ef24385aad.zip
Init project
Diffstat (limited to 'models/payment.py')
-rw-r--r--models/payment.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/models/payment.py b/models/payment.py
new file mode 100644
index 0000000..2b1cb90
--- /dev/null
+++ b/models/payment.py
@@ -0,0 +1,16 @@
1from datetime import datetime
2
3from sqlalchemy import ForeignKey
4from sqlalchemy.orm import Mapped, mapped_column
5
6from models import BaseTable, Invoice, User
7
8
9class Payment(BaseTable):
10 __tablename__ = "payment"
11
12 id: Mapped[int] = mapped_column(primary_key=True, autoincrement=True)
13 user_id: Mapped[int] = mapped_column(ForeignKey(User.id))
14 invoice_id: Mapped[int] = mapped_column(ForeignKey(Invoice.id))
15 receipt_file_id: Mapped[str]
16 datetime: Mapped[datetime]