14 lines
450 B
Python
14 lines
450 B
Python
from sqlalchemy import Column, Integer, String, DateTime
|
|
from sqlalchemy.sql import func
|
|
|
|
from app.database import Base
|
|
|
|
|
|
class AdminUser(Base):
|
|
"""管理员用户表模型"""
|
|
__tablename__ = "admin_users"
|
|
|
|
id = Column(Integer, primary_key=True, autoincrement=True)
|
|
username = Column(String(50), unique=True, nullable=False)
|
|
password_hash = Column(String(255), nullable=False)
|
|
created_at = Column(DateTime, default=func.now()) |