class QualificationNameType(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'qualification_name_type'

    ID = db.Column(db.BigInteger, primary_key=True)
    name = db.Column(db.String(500))
    QUALIFICATION_TYPE_ID = db.Column(db.ForeignKey('qualification_type.ID'), index=True)

    qualification_type = db.relationship('QualificationType', primaryjoin='QualificationNameType.QUALIFICATION_TYPE_ID == QualificationType.ID', backref='qualification_name_types')
class HotelList(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'hotel_list'

    id = db.Column(db.String(255), primary_key=True)
    hotel_name = db.Column(db.String(255))
    star_rating = db.Column(db.String(255))
    cityId = db.Column(db.ForeignKey('cities.id'), nullable=False, index=True)

    city = db.relationship('City', primaryjoin='HotelList.cityId == City.id', backref='hotel_lists')
class ManagerInfo(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'manager_info'

    ID = db.Column(db.BigInteger, primary_key=True)
    name = db.Column(db.String(500))
    departMent_Id = db.Column(db.ForeignKey('departmant.ID'), nullable=False, index=True)
    emp_id = db.Column(db.String(50), unique=True)

    departmant = db.relationship('Departmant', primaryjoin='ManagerInfo.departMent_Id == Departmant.ID', backref='manager_infos')
class Demandasset(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'demandasset'

    id_No = db.Column(db.BigInteger, primary_key=True)
    request_Id = db.Column(db.String(255))
    request_Type = db.Column(db.String(255))
    emp_id = db.Column(db.String(255))
    request_date = db.Column(db.Date)
    description = db.Column(db.String(255))
    quantity = db.Column(db.Integer)
    comments = db.Column(db.String(255))
    demandCategory = db.Column(db.ForeignKey('assetcategory.id'), index=True)
    status = db.Column(db.ForeignKey('demandstatus.id'), index=True)
    demandSubcategory = db.Column(db.ForeignKey('assetsubcategory.id'), index=True)

    assetcategory = db.relationship('Assetcategory', primaryjoin='Demandasset.demandCategory == Assetcategory.id', backref='demandassets')
    assetsubcategory = db.relationship('Assetsubcategory', primaryjoin='Demandasset.demandSubcategory == Assetsubcategory.id', backref='demandassets')
    demandstatu = db.relationship('Demandstatu', primaryjoin='Demandasset.status == Demandstatu.id', backref='demandassets')
class Empassetmapping(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'empassetmapping'

    id = db.Column(db.BigInteger, primary_key=True)
    empId = db.Column(db.String(255))
    bayNo = db.Column(db.String(255))
    windowsVersion = db.Column(db.String(255))
    osProKey = db.Column(db.String(255))
    msOfficeVersion = db.Column(db.String(255))
    officeProKey = db.Column(db.String(255))
    assignedOn = db.Column(db.Date)
    returnedOn = db.Column(db.Date)
    notes = db.Column(db.String(255))
    assetId = db.Column(db.ForeignKey('asset.assetId'), index=True)
    requestId = db.Column(db.ForeignKey('demandasset.id_No'), index=True)

    asset = db.relationship('Asset', primaryjoin='Empassetmapping.assetId == Asset.assetId', backref='empassetmappings')
    demandasset = db.relationship('Demandasset', primaryjoin='Empassetmapping.requestId == Demandasset.id_No', backref='empassetmappings')
Пример #6
0
class MsgProject(db.Model):
    __bind_key__ = 'bcsproj'
    id = db.Column(db.Integer, unique=True, nullable=False, primary_key=True)
    programId = db.Column(db.Integer, db.ForeignKey("msg_program.id"))
    accountId = db.Column(
        db.Integer,
        db.ForeignKey("msg_account.id"))  #Duplicated here for convenience
    pmEmail = db.Column(db.String(200),
                        nullable=False)  # email of the project manager
    onsiteCounterpart = db.Column(
        db.String(200))  # email of the oniste PM-counterpart
    projName = db.Column(db.String(200))  # Project Name that is used, e.g. NN
    projBCSName = db.Column(db.String(
        200))  # Project Name as obtained from BCS, needed for linking
    projType = db.Column(db.String(
        100))  # Project POC, Maintenance, Development, implementation, DevOps
    bcsProjectID = db.Column(
        db.String(20))  # This is the PROJECT_ID from the BCS-FILE
    dateStart = db.Column(db.DateTime)  #Defaults to 2000-01-01
    dateEnd = db.Column(db.DateTime)  #Defaults to 2000-01-01
    travelCountry = db.Column(db.String(
        200))  # default travel country, For travel information purpose,
    contractStatus = db.Column(db.String(
        30))  # [Opportunity, Proposed, Signed, Terminated, Ended, OnHold]
    deliveryStatus = db.Column(db.String(
        30))  # [AwaitingConfirmation,AwaitingStaffing, InProgress, Closed ]
    bcsProjectStatus = db.Column(db.String(20))  # From BCS-Data
    billability = db.Column(db.String(20))  # From BCS-Data
    projectCostCentre = db.Column(db.String(20))  # From BCS-Data
    billingModel = db.Column(db.String(
        20))  # Project Level[MonthlyFTE, DailyEffort, AlternateModel2]
    accountObj = db.relationship(
        'MsgAccount',
        primaryjoin='MsgProject.accountId == MsgAccount.id',
        backref='accounts')
    programObj = db.relationship(
        'MsgProgram',
        primaryjoin='MsgProject.programId == MsgProgram.id',
        backref='programs')
class SkillDetail(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'skill_details'

    ID = db.Column(db.BigInteger, primary_key=True)
    employeeId = db.Column(db.ForeignKey('employee.SID'), nullable=False, index=True)
    SKILL_CATEGORY_ID = db.Column(db.ForeignKey('skill_category.ID'), index=True)
    SKILL_TYPE_ID = db.Column(db.ForeignKey('skill_type.ID'), index=True)
    SKILL_ID = db.Column(db.ForeignKey('skills.ID'), index=True)
    ROLE_ID = db.Column(db.ForeignKey('role.ID'), index=True)
    VERSION = db.Column(db.String(10))
    PROFICIENCY = db.Column(db.String(100))
    LASTUSED = db.Column(db.String(10))
    RELEVENT_EXP_IN_MONTHS = db.Column(db.String(80))
    RELEVENT_EXP_IN_YEARS = db.Column(db.String(80))
    #IS_ENABLE = db.Column(BIT(1))

    role = db.relationship('Role', primaryjoin='SkillDetail.ROLE_ID == Role.ID', backref='skill_details')
    skill_category = db.relationship('SkillCategory', primaryjoin='SkillDetail.SKILL_CATEGORY_ID == SkillCategory.ID', backref='skill_details')
    skill = db.relationship('Skill', primaryjoin='SkillDetail.SKILL_ID == Skill.ID', backref='skill_details')
    skill_type = db.relationship('SkillType', primaryjoin='SkillDetail.SKILL_TYPE_ID == SkillType.ID', backref='skill_details')
    employee = db.relationship('Employee', primaryjoin='SkillDetail.employeeId == Employee.SID', backref='skill_details')
class DocumentDetail(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'document_details'

    ID = db.Column(db.BigInteger, primary_key=True)
    UAN_FILE_NAME = db.Column(db.String(500))
    UAN_URL = db.Column(db.String(500))
    UAN_NO_DOC = db.Column(LONGBLOB)
    UAN_NO = db.Column(db.String(80))
    PF_FILE_NAME = db.Column(db.String(500))
    PF_URL = db.Column(db.String(500))
    PF_NO_DOC = db.Column(LONGBLOB)
    PF_NO = db.Column(db.String(80))
    ADHAAR_FILE_NAME = db.Column(db.String(500))
    AADHAAR_URL = db.Column(db.String(500))
    AADHAAR_NO_DOC = db.Column(LONGBLOB)
    AADHAR_NO = db.Column(db.String(80))
    DRIVING_LICENCE_FILE_NAME = db.Column(db.String(500))
    DRIVING_LICENCE_URL = db.Column(db.String(500))
    DRIVING_LICENCE_NO_DOC = db.Column(LONGBLOB)
    DRIVING_NO = db.Column(db.String(80))
    PAN_NO_FILE_NAME = db.Column(db.String(500))
    PAN_NO_URL = db.Column(db.String(500))
    PAN_NO_DOC = db.Column(LONGBLOB)
    PAN_NO = db.Column(db.String(80))
    EDUCATION_DETAILS_FILE_NAME = db.Column(db.String(500))
    EDUCATION_DETAILS_URL = db.Column(db.String(500))
    EDUCATION_DETAILS_DOC = db.Column(LONGBLOB)
    EDUCATION_NO = db.Column(db.String(80))
    CERTIFICATE_FILE_NAME = db.Column(db.String(500))
    CERTIFICATE_URL = db.Column(db.String(500))
    CERTIFICATE_DOC = db.Column(LONGBLOB)
    CERTIFICATE_NO = db.Column(db.String(80))
    VOTER_ID_FILE_NAME = db.Column(db.String(500))
    VOTER_ID_URL = db.Column(db.String(500))
    VOTER_ID_DOC = db.Column(LONGBLOB)
    VOTER_ID_NO = db.Column(db.String(80))
    PASSPORT_FILE_NAME = db.Column(db.String(500))
    PASSPORT_URL = db.Column(db.String(500))
    PASSPORT_DOC = db.Column(LONGBLOB)
    PASSPORT_NO = db.Column(db.String(80))

#New Fields Added
    PASSPORT_EXPIRY_DATE = db.Column(db.String(80))
    PASSPORT_ISSUE_PLACE = db.Column(db.String(250))
    PASSPORT_ISSUE_DATE = db.Column(db.String(80))
    NAME_AS_PER_THE_PASSPORT = db.Column(db.String(500))

    employeeId = db.Column(db.ForeignKey('employee.SID'), index=True)

    employee = db.relationship('Employee', primaryjoin='DocumentDetail.employeeId == Employee.SID', backref=backref('document_details', uselist=False))
class Asset(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'asset'

    assetId = db.Column(db.String(255), primary_key=True)
    mode_ofReceive = db.Column(db.String(255))
    Make = db.Column(db.String(255))
    model = db.Column(db.String(255))
    serialNo = db.Column(db.String(255))
    description = db.Column(db.String(255))
    receivedON = db.Column(db.Date)
    invoiceDate = db.Column(db.Date)
    warrantyExpDate = db.Column(db.Date)
    amcVendor = db.Column(db.String(255))
    amcFromdate = db.Column(db.Date)
    amcTodate = db.Column(db.Date)
    hasInsurance = db.Column(db.String(255))
    insufromdate = db.Column(db.Date)
    insutodate = db.Column(db.Date)
    assetLife = db.Column(db.Date)
    poFileName = db.Column(db.String(255))
    poFileData = db.Column(LONGBLOB)
    invoiceFileName = db.Column(db.String(255))
    invoiceData = db.Column(LONGBLOB)
    otherdocData = db.Column(LONGBLOB)
    otherDocName = db.Column(db.String(255))
    poId = db.Column(db.BigInteger)
    itemId = db.Column(db.ForeignKey('quotation.id'), index=True)
    status = db.Column(db.ForeignKey('assetstatus.id'), index=True)
    category = db.Column(db.ForeignKey('assetcategory.id'), index=True)
    subCategory = db.Column(db.ForeignKey('assetsubcategory.id'), index=True)
    cond = db.Column(db.ForeignKey('assetcondition.id'), index=True)

    assetcategory = db.relationship('Assetcategory', primaryjoin='Asset.category == Assetcategory.id', backref='assets')
    assetcondition = db.relationship('Assetcondition', primaryjoin='Asset.cond == Assetcondition.id', backref='assets')
    quotation = db.relationship('Quotation', primaryjoin='Asset.itemId == Quotation.id', backref='assets')
    assetstatu = db.relationship('Assetstatu', primaryjoin='Asset.status == Assetstatu.id', backref='assets')
    assetsubcategory = db.relationship('Assetsubcategory', primaryjoin='Asset.subCategory == Assetsubcategory.id', backref='assets')
Пример #10
0
class MasterGoal(db.Model):
    __bind_key__ = 'goalsheet'

    id = db.Column(db.Integer, unique=True, nullable=False, primary_key=True)
    title = db.Column(db.String(240), nullable=False)
    description = db.Column(db.String(1000), nullable=False)
    goalSectionId = db.Column(db.Integer,
                              db.ForeignKey("master_goal_section.id"))
    goalSectionRef = db.relationship(
        'MasterGoalSection',
        primaryjoin='MasterGoal.goalSectionId == MasterGoalSection.id',
        backref='mastergoals')
    weight1 = db.Column(db.FLOAT)  #Line Employee
    weight2 = db.Column(db.FLOAT)  #DC Lead
class Addres(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'address'

    ID = db.Column(db.BigInteger, primary_key=True)
    LINE1 = db.Column(db.String(100))
    LINE2 = db.Column(db.String(100))
    LINE3 = db.Column(db.String(100))
    COUNTRY_ID = db.Column(db.ForeignKey('country.ID'), index=True)
    STATE_ID = db.Column(db.ForeignKey('state.ID'), index=True)
    CITY = db.Column(db.String(100))
    PINCODE = db.Column(db.BigInteger)
    IS_ENABLE = db.Column(BIT(1))
    ADDRESS_TYPE = db.Column(db.ForeignKey('address_type.ID'), index=True)
    EMPLOYEE_ID = db.Column(db.ForeignKey('employee.SID'), index=True)
    EFFECTIVE_DATE = db.Column(db.String(50))
    TILL_DATE = db.Column(db.String(50))

    address_type = db.relationship('AddressType', primaryjoin='Addres.ADDRESS_TYPE == AddressType.ID', backref='address')
    country = db.relationship('Country', primaryjoin='Addres.COUNTRY_ID == Country.ID', backref='address')
    employee = db.relationship('Employee', primaryjoin='Addres.EMPLOYEE_ID == Employee.SID', backref=backref('address', uselist=False))
    
    state = db.relationship('State', primaryjoin='Addres.STATE_ID == State.ID', backref='address')
class EmployeeProjectDetail(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'employee_project_details'

    ID = db.Column(db.BigInteger, primary_key=True)
    PROJECT_NAME = db.Column(db.String(500))
    PROJECT_DESCRIPTION = db.Column(db.String(500))
    KEY_CONTRIBUTION = db.Column(db.String(500))
    START_DATE = db.Column(db.String(50))
    END_DATE = db.Column(db.String(50))
    ROLE_ID = db.Column(db.ForeignKey('role.ID'), index=True)
    employment_id = db.Column(db.ForeignKey('employment_history.ID'), index=True)
    idx = db.Column(db.Integer)
    CLIENT_NAME = db.Column(db.String(100))
    EMPLOYEE_ID = db.Column(db.ForeignKey('employee.SID'), index=True)
    EMPLOYMENT_HISTORY_ID = db.Column(db.ForeignKey('employment_history.ID'), index=True)
    IS_ENABLE = db.Column(BIT(1))
    IS_SUCCESS = db.Column(BIT(1))

    employee = db.relationship('Employee', primaryjoin='EmployeeProjectDetail.EMPLOYEE_ID == Employee.SID', backref='employee_project_details')
    employment_history = db.relationship('EmploymentHistory', primaryjoin='EmployeeProjectDetail.EMPLOYMENT_HISTORY_ID == EmploymentHistory.ID', backref='employmenthistory_employee_project_details')
    role = db.relationship('Role', primaryjoin='EmployeeProjectDetail.ROLE_ID == Role.ID', backref='employee_project_details')
    employment = db.relationship('EmploymentHistory', primaryjoin='EmployeeProjectDetail.employment_id == EmploymentHistory.ID', backref='employmenthistory_employee_project_details_0')
class EducationDetail(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'education_details'

    ID = db.Column(db.BigInteger, primary_key=True)
    QUALIFICATION_ID = db.Column(db.ForeignKey('qualification_type.ID'), nullable=False, index=True)
    DEGREE_ID = db.Column(db.ForeignKey('degree_type.ID'), index=True)
    COLLEGE_NAME = db.Column(db.String(500))
    JOINING_DATE = db.Column(db.String(255))
    END_DATE = db.Column(db.String(255))
    PERCENTAGE = db.Column(db.String(50))
    IS_ENABLE = db.Column(BIT(1))
    GRADE = db.Column(db.String(50))
    employeeId = db.Column(db.ForeignKey('employee.SID'), index=True)
    SPECILIZATION = db.Column(db.String(500))
    UNIVERSITY_NAME = db.Column(db.String(500))
    UNIVERSITY_ID = db.Column(db.ForeignKey('university_type.ID'), index=True)
    DegreeType = db.Column(db.String(500))

    degree_type = db.relationship('DegreeType', primaryjoin='EducationDetail.DEGREE_ID == DegreeType.ID', backref='education_details')
    qualification_type = db.relationship('QualificationType', primaryjoin='EducationDetail.QUALIFICATION_ID == QualificationType.ID', backref='education_details')
    university_type = db.relationship('UniversityType', primaryjoin='EducationDetail.UNIVERSITY_ID == UniversityType.ID', backref='education_details')
    employee = db.relationship('Employee', primaryjoin='EducationDetail.employeeId == Employee.SID', backref='education_details')
class CertificationDetail(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'certification_details'

    ID = db.Column(db.BigInteger, primary_key=True)
    CERTIFICATION_DATE = db.Column(db.String(500))
    CERTFICATION_VERSION = db.Column(db.String(500))
    PERCENTAGE = db.Column(db.String(500))
    TRAINED_COURSE_NAME = db.Column(db.String(500))
    INSTITUTION_NAME = db.Column(db.String(500))
    INSTITUTION_LOCATION = db.Column(db.String(500))
    COURSE_DURATION = db.Column(db.String(500))
    CERTIFICATION_NO = db.Column(db.String(500))
    CERTIFICATION_NAME = db.Column(db.String(500))
    CERT_NAME_TYPE = db.Column(db.ForeignKey('certification_name_type.ID'), index=True)
    CERT_TYPE = db.Column(db.ForeignKey('certification_type.ID'), index=True)
    employeeId = db.Column(db.ForeignKey('employee.SID'), index=True)
    IS_ENABLE = db.Column(BIT(1))
    IS_SUCCESS = db.Column(BIT(1))

    certification_name_type = db.relationship('CertificationNameType', primaryjoin='CertificationDetail.CERT_NAME_TYPE == CertificationNameType.ID', backref='certification_details')
    certification_type = db.relationship('CertificationType', primaryjoin='CertificationDetail.CERT_TYPE == CertificationType.ID', backref='certification_details')
    employee = db.relationship('Employee', primaryjoin='CertificationDetail.employeeId == Employee.SID', backref='certification_details')
Пример #15
0
class MsgProgram(db.Model):
    __bind_key__ = 'bcsproj'
    id = db.Column(db.Integer, unique=True, nullable=False, primary_key=True)
    accountId = db.Column(db.Integer, db.ForeignKey("msg_account.id"))
    managerEmail = db.Column(db.String(200),
                             nullable=False)  # email of the project manager
    programName = db.Column(
        db.String(200))  # Project Name that is used, e.g. NN
    dateStart = db.Column(db.DateTime)  #Defaults to 2000-01-01
    dateEnd = db.Column(db.DateTime)  #Defaults to 2000-01-01
    description = db.Column(db.String(1000))  # General Notes
    accountObj = db.relationship(
        'MsgAccount',
        primaryjoin='MsgProgram.accountId == MsgAccount.id',
        backref='progaccounts')
class EmployeeFamilyDetail(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'employee_family_details'

    EMP_FAMILY_ID = db.Column(db.BigInteger, primary_key=True)
    FIRST_NAME = db.Column(db.String(255))
    MIDDLE_NAME = db.Column(db.String(255))
    LAST_NAME = db.Column(db.String(255))
    RELATIONSHIP_ID = db.Column(db.ForeignKey('relationship.ID'), index=True)
    GENDER_ID = db.Column(db.ForeignKey('gender.ID'), index=True)
    DATE_OF_BIRTH = db.Column(db.String(255))
    EMAIL_ID = db.Column(db.String(255))
    MOBILE_NO = db.Column(db.String(255))
    OCCUPATION = db.Column(db.String(255))
    PASSPORTID = db.Column(db.String(255))
    IS_ENABLE = db.Column(BIT(1))
    EMP_ID = db.Column(db.ForeignKey('employee.SID'), nullable=False, index=True)
    ADHAR_DOCUMENT = db.Column(LONGBLOB)
    ADHAR_FILENAME = db.Column(db.String(255))
    AADHAR_NO = db.Column(db.String(80))

    employee = db.relationship('Employee', primaryjoin='EmployeeFamilyDetail.EMP_ID == Employee.SID', backref='employee_family_details')
    gender = db.relationship('Gender', primaryjoin='EmployeeFamilyDetail.GENDER_ID == Gender.ID', backref='employee_family_details')
    relationship = db.relationship('Relationship', primaryjoin='EmployeeFamilyDetail.RELATIONSHIP_ID == Relationship.ID', backref='employee_family_details')
class VisaDocument(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'visa_documents'

    visa_request_document_id = db.Column(db.Integer, primary_key=True)
    date_of_birth = db.Column(db.String(255))
    document_name = db.Column(db.String(255), nullable=False)
    file_name = db.Column(db.String(255), nullable=False)
    first_name = db.Column(db.String(255), nullable=False)
    last_name = db.Column(db.String(255), nullable=False)
    middle_name = db.Column(db.String(255), nullable=False)
    relationship = db.Column(db.String(255), nullable=False)
    visa_document = db.Column(LONGBLOB, nullable=False)
    visa_request_id = db.Column(db.ForeignKey('visa_request.visa_request_id'), nullable=False, index=True)

    visa_request = db.relationship('VisaRequest', primaryjoin='VisaDocument.visa_request_id == VisaRequest.visa_request_id', backref='visa_documents')
class Purchaseorder(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'purchaseorder'

    id = db.Column(db.BigInteger, primary_key=True)
    poNumber = db.Column(db.String(255))
    itemNo = db.Column(db.BigInteger)
    poDate = db.Column(db.Date)
    createdDate = db.Column(db.Date)
    createdBy = db.Column(db.String(255))
    lastUpdatedDate = db.Column(db.Date)
    updatedBy = db.Column(db.String(255))
    status = db.Column(db.ForeignKey('postatus.id'), index=True)
    rejectionReason = db.Column(db.String(255))

    postatu = db.relationship('Postatu', primaryjoin='Purchaseorder.status == Postatu.id', backref='purchaseorders')
Пример #19
0
class GoalSheet(db.Model):
    __bind_key__ = 'goalsheet'

    id = db.Column(db.Integer, unique=True, nullable=False, primary_key=True)
    empId = db.Column(db.Integer)  # Employee this is assigned to
    assessmentYear = db.Column(
        db.String(10), nullable=False
    )  # For Display, can be derived from start/end dates, but make it easy
    assessingManager = db.Column(db.Integer, nullable=False)
    assignedBy = db.Column(db.Integer,
                           nullable=False)  # For Tracing who assigned
    defaultStartDate = db.Column(
        db.String(10), nullable=False
    )  # Used for setting Defaults for ALL Goals/Goal-Sections, tasks, etc.
    defaultEndDate = db.Column(
        db.String(10), nullable=False
    )  # Used for setting Defaults for ALL Goals/Goal-Sections, tasks, etc.
    templateId = db.Column(
        db.Integer,
        db.ForeignKey("assignment_template.id"))  # Which template was assigned
    status = db.Column(
        db.String(40),
        nullable=False)  # Create a Lookup-Table here? is it really needed?
    managerComments = db.Column(db.String(1000))

    templateRef = db.relationship(
        'AssignmentTemplate',
        primaryjoin='GoalSheet.templateId == AssignmentTemplate.id',
        backref='assignmenttemplate')
    l1Rating = db.Column(db.String(10),
                         default="Not Rated")  # 1st Level Manager
    l2Rating = db.Column(db.String(10), default="Not Rated")  # DC-Lead
    l3Rating = db.Column(db.String(10), default="Not Rated")  # mgmt/HR
    calculatedRating = db.Column(
        db.String(10),
        default="Not Rated")  # From recommendation engine, at some point

    finalRating = db.Column(
        db.String(10), default="Not Rated"
    )  # What is SHOWN to the user, same as l3 after publish
    finalComments = db.Column(db.String(1000))
    #    weight = db.Column(db.DECIMAL)
    score = db.Column(db.FLOAT, default=0)
    maxscore = db.Column(
        db.FLOAT, default=0
    )  #To be computed and updated at the time of goal-sheet assignment
class Quotation(db.Model):
    __bind_key__ = 'hrms'
    __tablename__ = 'quotation'

    id = db.Column(db.BigInteger, primary_key=True)
    quoteId = db.Column(db.BigInteger)
    vendorName = db.Column(db.String(255))
    makeModel = db.Column(db.String(255))
    description = db.Column(db.String(255))
    unitprice = db.Column(db.Float(asdecimal=True))
    quantity = db.Column(db.Integer)
    totalAmt = db.Column(db.Float(asdecimal=True))
    tax = db.Column(db.String(255))
    nettAmout = db.Column(db.Float(asdecimal=True))
    assignedTo = db.Column(db.Integer)
    status = db.Column(db.ForeignKey('quotestatus.id'), index=True)
    comments = db.Column(db.String(255))

    quotestatu = db.relationship('Quotestatu', primaryjoin='Quotation.status == Quotestatu.id', backref='quotations')