Create temp_simbrella_lien.py
This commit is contained in:
@@ -0,0 +1,29 @@
|
|||||||
|
from app.extensions import db
|
||||||
|
|
||||||
|
|
||||||
|
class TempSimbrellaLien(db.Model):
|
||||||
|
__tablename__ = "tmp_simbrella_lien"
|
||||||
|
|
||||||
|
lienid = db.Column(db.String(33), primary_key=True)
|
||||||
|
customerid = db.Column(db.String(500))
|
||||||
|
accountid = db.Column(db.String(11))
|
||||||
|
lien_start_date = db.Column(db.DateTime)
|
||||||
|
action = db.Column(db.String(5))
|
||||||
|
restriction_nature = db.Column(db.String(150))
|
||||||
|
claim_amount = db.Column(db.Numeric(20, 4))
|
||||||
|
|
||||||
|
|
||||||
|
def __repr__(self):
|
||||||
|
return f"<TempSimbrellaLien {self.lienid}>"
|
||||||
|
|
||||||
|
|
||||||
|
def to_dict(self):
|
||||||
|
return {
|
||||||
|
"lienid": self.lienid,
|
||||||
|
"customerid": self.customerid,
|
||||||
|
"accountid": self.accountid,
|
||||||
|
"lien_start_date": self.lien_start_date,
|
||||||
|
"action": self.action,
|
||||||
|
"restriction_nature": self.restriction_nature,
|
||||||
|
"claim_amount": float(self.claim_amount) if self.claim_amount is not None else None,
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user