Tech Tools section with a code generator, toner report that names the part, toner forecasting, warranty proof of cover, application uploads
This commit is contained in:
@@ -48,6 +48,14 @@ class Warranty(db.Model):
|
||||
# When a provider lookup last refreshed this record.
|
||||
lastcheckeddate = db.Column(db.DateTime)
|
||||
notes = db.Column(db.Text)
|
||||
|
||||
# Proof of cover: the purchase invoice, the extended-warranty certificate,
|
||||
# whatever the vendor sent. A provider lookup answers "is it covered"; this
|
||||
# answers "prove it" months later, when the email it arrived in is gone.
|
||||
# Stores the served URL, not the original filename - see the upload route.
|
||||
proofurl = db.Column(db.String(500))
|
||||
prooffilename = db.Column(db.String(255))
|
||||
|
||||
isactive = db.Column(db.Boolean, nullable=False, server_default='1')
|
||||
|
||||
links = db.relationship('WarrantyAsset', back_populates='warranty',
|
||||
@@ -68,6 +76,8 @@ class Warranty(db.Model):
|
||||
'enddate': self.enddate.isoformat() if self.enddate else None,
|
||||
'lastcheckeddate': self.lastcheckeddate.isoformat() + 'Z' if self.lastcheckeddate else None,
|
||||
'notes': self.notes,
|
||||
'proofurl': self.proofurl,
|
||||
'prooffilename': self.prooffilename,
|
||||
'isactive': bool(self.isactive),
|
||||
'status': status,
|
||||
'statuscolor': STATUS_COLORS.get(status, STATUS_COLORS['unknown']),
|
||||
|
||||
Reference in New Issue
Block a user