Skip to content

Commit

Permalink
feat: added new field numbe in bank
Browse files Browse the repository at this point in the history
  • Loading branch information
calenzo committed Nov 21, 2022
1 parent 268e866 commit 0f8d5c8
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 3 deletions.
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -124,4 +124,8 @@ dmypy.json
.pyre/
.idea
.DS_Store
src/.idea
src/.idea

#alembic
alembic.ini
alembic
Empty file removed balance_domain/__init__.py
Empty file.
Empty file.
2 changes: 0 additions & 2 deletions balance_domain/database/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy.orm import sessionmaker

from balance_domain.models import user_models

load_dotenv()

USERNAME = os.environ["DB_USERNAME"]
Expand Down
Empty file removed balance_domain/models/__init__.py
Empty file.
2 changes: 2 additions & 0 deletions balance_domain/models/user_models.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from sqlalchemy import Boolean, Column, ForeignKey, Integer, String
from sqlalchemy.orm import relationship

from balance_domain.database.settings import Base


Expand All @@ -23,6 +24,7 @@ class Bank(Base):
__tablename__ = "TB_BANK"

id = Column(Integer, primary_key=True, index=True)
number = Column(String(5))
token = Column(String(800))
is_active = Column(Boolean, default=True)
user_id = Column(Integer, ForeignKey("TB_USER.id"))
Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
SQLAlchemy==1.4.20
python-dotenv==0.21.0
PyMySQL==1.0.2
alembic==1.8.1

0 comments on commit 0f8d5c8

Please sign in to comment.