import { CompetencytypeModel, MyCompetencytypeModel } from "./competencytype.model"

export interface CompetencytopicModel {
    competencyTopicId: string
    competencyType: CompetencytypeModel
    companyId: string
    edesc: string
    tdesc: string
    competencyDetail: string
    competencyFiles: string
    lineNo: number
    expectationLevel: string
}


export class MyCompetencytopicModel implements CompetencytopicModel {
    competencyTopicId: string
    competencyType: CompetencytypeModel
    companyId: string
    edesc: string
    tdesc: string
    competencyDetail: string
    competencyFiles: string
    lineNo: number
    expectationLevel: string
    constructor(data: Partial<CompetencytopicModel>) {
        this.competencyTopicId = data.competencyTopicId || ""
        this.competencyType = new MyCompetencytypeModel(data.competencyType || {})
        this.companyId = data.companyId || ""
        this.edesc = data.edesc || ""
        this.tdesc = data.tdesc || ""
        this.competencyDetail = data.competencyDetail || ""
        this.competencyFiles = data.competencyFiles || ""
        this.lineNo = data.lineNo ?? 0
        this.expectationLevel = data.expectationLevel || ""
    }
}

