| from sqlalchemy import Column, Integer, String, JSON | |
| from sqlalchemy.dialects.postgresql import TIMESTAMP | |
| from . import Base | |
| from typing import Any | |
| from app.utils.utility import to_dict | |
| class UserDocument(Base): | |
| __tablename__ = "UserDocuments" | |
| userDocumentId = Column(Integer, primary_key=True) | |
| userId = Column(Integer) | |
| documentTypeId = Column(Integer) | |
| documentSubTypeId = Column(Integer) | |
| documentStatusId = Column(Integer) | |
| URL = Column(String) | |
| date = Column(TIMESTAMP) | |
| applicationId = Column(Integer) | |
| userProfileId = Column(Integer) | |
| remarks = Column(String) | |
| documentName = Column(String) | |
| documentDetails = Column(JSON) | |
| documentSize = Column(Integer) | |
| def dict(self) -> dict[str, Any]: | |
| return to_dict(self) | |