Dump changes
This commit is contained in:
parent
b49c6ced26
commit
a4b572dcc7
40 changed files with 186 additions and 37 deletions
14
app/role/model.py
Normal file
14
app/role/model.py
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
from datetime import datetime
|
||||
|
||||
from sqlalchemy import Column, Integer, String, DateTime, Text
|
||||
|
||||
from app.db import EntityBase
|
||||
|
||||
|
||||
class Role(EntityBase):
|
||||
__tablename__ = "roles"
|
||||
|
||||
id = Column(Integer, primary_key=True)
|
||||
name = Column(String(64), unique=True, nullable=False)
|
||||
description = Column(Text)
|
||||
creation_date = Column(DateTime, nullable=False, default=datetime.utcnow())
|
||||
Loading…
Add table
Add a link
Reference in a new issue