Rough idea of what the Approvals model will look like.
This commit is contained in:
parent
a0c884499e
commit
992a85e9a5
|
@ -7,6 +7,12 @@ from crc import db, app
|
|||
from crc.api.common import ApiError
|
||||
|
||||
|
||||
class Approvals(db.Model):
|
||||
approval_uid = db.Column(db.String, unique=True)
|
||||
workflow_id = db.Column(db.Integer, primary_key=True)
|
||||
workflow_version = db.Column(db.String)
|
||||
is_approved = db.Column(db.Boolean)
|
||||
|
||||
class UserModel(db.Model):
|
||||
__tablename__ = 'user'
|
||||
id = db.Column(db.Integer, primary_key=True)
|
||||
|
@ -19,6 +25,8 @@ class UserModel(db.Model):
|
|||
last_name = db.Column(db.String, nullable=True)
|
||||
title = db.Column(db.String, nullable=True)
|
||||
|
||||
# Add Department and School
|
||||
|
||||
|
||||
def encode_auth_token(self):
|
||||
"""
|
||||
|
|
|
@ -79,5 +79,6 @@ class WorkflowModel(db.Model):
|
|||
spec_version = db.Column(db.String)
|
||||
total_tasks = db.Column(db.Integer, default=0)
|
||||
completed_tasks = db.Column(db.Integer, default=0)
|
||||
# task_history = db.Column(db.ARRAY(db.String), default=[]) # The history stack of user completed tasks.
|
||||
last_updated = db.Column(db.DateTime)
|
||||
# todo: Add a version that represents the files associated with this workflow
|
||||
# version = "32"
|
Loading…
Reference in New Issue