File size: 768 Bytes
ef1ad9e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
from sqlalchemy import Column, Integer, String
from . import Base
from typing import Any
from app.utils.utility import to_dict


class Application(Base):
    __tablename__ = "Applications"

    applicationId = Column(Integer, primary_key=True)
    applicationStatusId = Column(Integer)
    borrowerId = Column(Integer)
    userId = Column(Integer)
    lenderId = Column(Integer)
    propertyAddress = Column(String)
    cityId = Column(Integer)
    stateId = Column(Integer)
    cityName = Column(String)
    stateName = Column(String)
    zipCode = Column(Integer)
    loanPurposeId = Column(Integer)
    applicationTypeId = Column(Integer)
    createdBy = Column(Integer)

    def dict(self) -> dict[str, Any]:
        return to_dict(self)