import { CompetencyCourseModel, MyCompetencyCourseModel } from "./competency-course.model"
import { CompetencyIndicatorsCourses0Model, MyCompetencyIndicatorsCourses0Model } from "./competency-indicators-courses0.model"
import { CompetencyIndicatorsCourses2ListModel, MyCompetencyIndicatorsCourses2ListModel } from "./competency-indicators-courses2-list.model"

export interface CompetencyIndicatorsCourses1MiniModel {
    competencyIndicatorsCourses0: CompetencyIndicatorsCourses0Model
    lineNo: number
    companyId: string
    competencyCourseId: string
    competencyCourse: CompetencyCourseModel[]
    behavioralIndicatorsList: CompetencyIndicatorsCourses2ListModel[]
}
export class MyCompetencyIndicatorsCourses1MiniModel implements CompetencyIndicatorsCourses1MiniModel {
    competencyIndicatorsCourses0: CompetencyIndicatorsCourses0Model
    lineNo: number
    companyId: string
    competencyCourseId: string
    competencyCourse: CompetencyCourseModel[]
    behavioralIndicatorsList: CompetencyIndicatorsCourses2ListModel[]
    constructor(data?: Partial<CompetencyIndicatorsCourses1MiniModel>) {
        this.competencyIndicatorsCourses0 = new MyCompetencyIndicatorsCourses0Model(data?.competencyIndicatorsCourses0 || {})
        this.lineNo = data?.lineNo ?? 0
        this.companyId = data?.companyId || ""
        this.competencyCourseId = data?.competencyCourseId || ""
        this.competencyCourse = data?.competencyCourse?.map(x => new MyCompetencyCourseModel(x)) || []
        this.behavioralIndicatorsList = data?.behavioralIndicatorsList?.map(x => new MyCompetencyIndicatorsCourses2ListModel(x)) || []
    }
}

