Commit fa0e6d56 by Nattana Chaiyamat

การประเมินผล

ประเมินโดยหัวหน้า
parent 8de732e2
......@@ -157,6 +157,7 @@ import { PmsEvaluationCycleService } from 'src/app/shared/services/pms-evaluatio
import { PmsEvaluationAssessmentService } from 'src/app/shared/services/pms-evaluation-assessment.service';
import { TimeAttendanceComponent } from '../performance-management-evaluation/time-attendance/time-attendance.component';
import { PmsWorkingTimeService } from 'src/app/shared/services/pms-working-time.service';
import { EvaluationIdpService } from 'src/app/shared/services/evaluation-Idp.service';
export const MY_DATE_FORMATS = {
parse: {
......@@ -344,6 +345,7 @@ export class CustomDateAdapter extends NativeDateAdapter {
PmsEvaluationCycleService,
PmsEvaluationAssessmentService,
PmsWorkingTimeService,
EvaluationIdpService,
{
provide: HTTP_INTERCEPTORS,
useClass: HttpRequestInterceptor,
......
<app-page-header [pathTitle]="pathTitle"></app-page-header>
<div class="bg-card-white">
</div>
<div class="block-main-content" *ngIf="appraisalCompentency.data">
<div class="block-main-content">
<div class="pb-2rem px-2rem pt-1.5rem w-full min-height-50px justify-between items-center">
<div class="flex">
<button type="button" class="ti-btn ti-btn-outline ti-btn-outline-light h-20px m-0 shadow-md text-blue-500"
......@@ -14,384 +14,386 @@
</div>
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="font-size-18px font-weight-700 text-primary">
แบบประเมินสมรรถนะพนักงาน {{currentDate.getFullYear()}}
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="p-2 grid grid-cols-6 gap-3">
<div class="grid-cols-1">
<div class="text-gray-400">เครื่องมือประเมิน</div>
<div class="text-gray-400">O = แบบสังเกต</div>
<div class="text-gray-400">P = แบบการปฏิบัติงาน</div>
<div class="text-gray-400">D = การบันทึก/เอกสาร</div>
<div class="text-gray-400">I = การสัมภาษณ์</div>
<div class="text-gray-400">T = แบบทดสอบ</div>
</div>
<div class="grid-cols-1">
<div class="text-gray-400">คำชี้แจง</div>
<div class="text-gray-400">- ใช้วิธีประเมินโดย ผู้บังคับบัญชา = 100 %</div>
<ng-container *ngIf="appraisalCompentency.data">
<div class="pb-2rem px-2rem">
<div class="font-size-18px font-weight-700 text-primary">
แบบประเมินสมรรถนะพนักงาน {{currentDate.getFullYear()}}
</div>
<div class="col-span-3 grid-cols-1">
<div class="text-gray-400">ระดับความสามารถ (Target Degree)</div>
<div class="text-gray-400">ระดับ 1 = ไม่มีความรู้พื้นฐานเลย ขาดทักษะในงาน</div>
<div class="text-gray-400">ระดับ 2 = มีความรู้ในงานบ้างแต่ยังไม่สามารถ ประยุกต์ใช้ในงานได้</div>
<div class="text-gray-400">ระดับ 3 = นำความรู้มาประยุกต์ใช้ในงานได้ ปฏิบัติงานเองได้ด้วยตัวเอง
แก้ไขปัญหาหน้างานได้</div>
<div class="text-gray-400">ระดับ 4 = สอนผู้อื่นได้ มีความคล่องตัว เชื่อมโยง ความรู้ในงานได้</div>
<div class="text-gray-400">ระดับ 5 = มีความชำนาญ เชี่ยวชาญ เป็นที่ยอมรับ ในองค์กร</div>
</div>
<div class="pb-2rem px-2rem">
<div class="p-2 grid grid-cols-6 gap-3">
<div class="grid-cols-1">
<div class="text-gray-400">เครื่องมือประเมิน</div>
<div class="text-gray-400">O = แบบสังเกต</div>
<div class="text-gray-400">P = แบบการปฏิบัติงาน</div>
<div class="text-gray-400">D = การบันทึก/เอกสาร</div>
<div class="text-gray-400">I = การสัมภาษณ์</div>
<div class="text-gray-400">T = แบบทดสอบ</div>
</div>
<div class="grid-cols-1">
<div class="text-gray-400">คำชี้แจง</div>
<div class="text-gray-400">- ใช้วิธีประเมินโดย ผู้บังคับบัญชา = 100 %</div>
</div>
<div class="col-span-3 grid-cols-1">
<div class="text-gray-400">ระดับความสามารถ (Target Degree)</div>
<div class="text-gray-400">ระดับ 1 = ไม่มีความรู้พื้นฐานเลย ขาดทักษะในงาน</div>
<div class="text-gray-400">ระดับ 2 = มีความรู้ในงานบ้างแต่ยังไม่สามารถ ประยุกต์ใช้ในงานได้</div>
<div class="text-gray-400">ระดับ 3 = นำความรู้มาประยุกต์ใช้ในงานได้ ปฏิบัติงานเองได้ด้วยตัวเอง
แก้ไขปัญหาหน้างานได้</div>
<div class="text-gray-400">ระดับ 4 = สอนผู้อื่นได้ มีความคล่องตัว เชื่อมโยง ความรู้ในงานได้</div>
<div class="text-gray-400">ระดับ 5 = มีความชำนาญ เชี่ยวชาญ เป็นที่ยอมรับ ในองค์กร</div>
</div>
</div>
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="overflow-auto rounded-top-0.65rem">
<table class="ti-custom-table ti-custom-table-head ti-custom-table-hover2">
<thead class="height-50px">
<tr class="font-size-12px">
<ng-container
*ngFor="let item of ['ลำดับที่','รหัสสมรรถนะ','ชื่อสมรรถนะ','Behavior Indicator (BI)','เครื่องมือประเมิน\n(ตัวย่อ)\n(O,P,D,I,T)']">
<th scope="col" rowspan="2"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">{{ item }}</span>
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
</ng-container>
<th scope="col" colspan="5"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
ระดับความสามารถ (Target Degree)
</th>
</tr>
<tr class="font-size-12px">
<ng-container *ngFor="let item of [5,4,3,2,1]">
<th scope="col"
<div class="pb-2rem px-2rem">
<div class="overflow-auto rounded-top-0.65rem">
<table class="ti-custom-table ti-custom-table-head ti-custom-table-hover2">
<thead class="height-50px">
<tr class="font-size-12px">
<ng-container
*ngFor="let item of ['ลำดับที่','รหัสสมรรถนะ','ชื่อสมรรถนะ','Behavior Indicator (BI)','เครื่องมือประเมิน\n(ตัวย่อ)\n(O,P,D,I,T)']">
<th scope="col" rowspan="2"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">{{ item }}</span>
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
</ng-container>
<th scope="col" colspan="5"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
{{item}}
ระดับความสามารถ (Target Degree)
</th>
</ng-container>
</tr>
</thead>
<tbody *ngIf="appraisalCompentency.loading">
<tr>
<td class="text-center" colspan="100%">
<div *ngFor="let item of [1,2,3]" class="ti-spinner w-8 h-8 text-secondary mx-1"
role="status" aria-label="loading">
<span class="sr-only">Loading...</span>
</div>
</td>
</tr>
</tbody>
<tbody *ngIf="!appraisalCompentency.loading&&!appraisalCompentencyFilter().length">
<tr>
<td class="text-center" colspan="100%">
ไม่พบข้อมูล
</td>
</tr>
</tbody>
<tbody *ngIf="!appraisalCompentency.loading&&appraisalCompentencyFilter().length">
<ng-container *ngFor="let item2 of appraisalCompentencyFilter();let i = index">
<tr *ngFor="let bi of item2.groupAssessment1.competencyIndicatorsCourses1Mini.behavioralIndicatorsList;let i2 = index;let f = first"
(mouseenter)="hoveredCode = item2.groupAssessment1.competencyIndicatorsCourses1Mini.competencyCourseId"
(mouseleave)="hoveredCode = null"
[ngClass]="{ 'table-hover2': item2.groupAssessment1.competencyIndicatorsCourses1Mini.competencyCourseId === hoveredCode ,'border-none':!f }">
<td class="align-start text-center">
<ng-container *ngIf="f">
{{i+1}}
</ng-container>
</td>
<td class="align-start text-center">
<ng-container *ngIf="f">
{{item2.groupAssessment1.competencyIndicatorsCourses1Mini.competencyIndicatorsCourses0.competencyTopic.competencyTopicId}}
</ng-container>
</td>
<td class="align-start !white-space-normal">
<ng-container *ngIf="f">
{{item2.groupAssessment1.competencyIndicatorsCourses1Mini.competencyIndicatorsCourses0.tdesc}}
</ng-container>
</td>
<td class="align-start !white-space-normal">
{{bi.behavioralIndicators}}
</td>
<td class="align-center text-center">
{{bi.assessmentId}}
</tr>
<tr class="font-size-12px">
<ng-container *ngFor="let item of [5,4,3,2,1]">
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
{{item}}
</th>
</ng-container>
</tr>
</thead>
<tbody *ngIf="appraisalCompentency.loading">
<tr>
<td class="text-center" colspan="100%">
<div *ngFor="let item of [1,2,3]" class="ti-spinner w-8 h-8 text-secondary mx-1"
role="status" aria-label="loading">
<span class="sr-only">Loading...</span>
</div>
</td>
<td class="align-center text-center" *ngFor="let value of [5,4,3,2,1]; let i3=index">
<input type="radio" [name]="'radio'+i+''+i2" class="ti-form-radio"
[id]="'radio'+i+''+i2+''+i3" [class.cursor-pointer]="canEdit"
[class.cursor-not-allowed]="!canEdit" [value]="value" [disabled]="!canEdit"
[(ngModel)]="bi.competencyBehavioral.scoreTopicExpectation"
(ngModelChange)="calnumberCheck()">
</tr>
</tbody>
<tbody *ngIf="!appraisalCompentency.loading&&!appraisalCompentencyFilter().length">
<tr>
<td class="text-center" colspan="100%">
ไม่พบข้อมูล
</td>
</tr>
</ng-container>
</tbody>
</table>
</tbody>
<tbody *ngIf="!appraisalCompentency.loading&&appraisalCompentencyFilter().length">
<ng-container *ngFor="let item2 of appraisalCompentencyFilter();let i = index">
<tr *ngFor="let bi of item2.groupAssessment1.competencyIndicatorsCourses1Mini.behavioralIndicatorsList;let i2 = index;let f = first"
(mouseenter)="hoveredCode = item2.groupAssessment1.competencyIndicatorsCourses1Mini.competencyCourseId"
(mouseleave)="hoveredCode = null"
[ngClass]="{ 'table-hover2': item2.groupAssessment1.competencyIndicatorsCourses1Mini.competencyCourseId === hoveredCode ,'border-none':!f }">
<td class="align-start text-center">
<ng-container *ngIf="f">
{{i+1}}
</ng-container>
</td>
<td class="align-start text-center">
<ng-container *ngIf="f">
{{item2.groupAssessment1.competencyIndicatorsCourses1Mini.competencyIndicatorsCourses0.competencyTopic.competencyTopicId}}
</ng-container>
</td>
<td class="align-start !white-space-normal">
<ng-container *ngIf="f">
{{item2.groupAssessment1.competencyIndicatorsCourses1Mini.competencyIndicatorsCourses0.tdesc}}
</ng-container>
</td>
<td class="align-start !white-space-normal">
{{bi.behavioralIndicators}}
</td>
<td class="align-center text-center">
{{bi.assessmentId}}
</td>
<td class="align-center text-center" *ngFor="let value of [5,4,3,2,1]; let i3=index">
<input type="radio" [name]="'radio'+i+''+i2" class="ti-form-radio"
[id]="'radio'+i+''+i2+''+i3" [class.cursor-pointer]="canEdit"
[class.cursor-not-allowed]="!canEdit" [value]="value" [disabled]="!canEdit"
[(ngModel)]="bi.competencyBehavioral.scoreTopicExpectation"
(ngModelChange)="calnumberCheck()">
</td>
</tr>
</ng-container>
</tbody>
</table>
</div>
</div>
</div>
<div class="pb-1rem px-2rem">
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">ระดับความสามารถ (Target Degree)</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-1 text-center" *ngFor="let item of [5,4,3,2,1]">{{item}}</div>
<div class="pb-1rem px-2rem">
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">ระดับความสามารถ (Target Degree)</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-1 text-center" *ngFor="let item of [5,4,3,2,1]">{{item}}</div>
</div>
</div>
</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">รวมจำนวนเครื่องหมายแต่ละช่อง (1)</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck5}}</div>
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck4}}</div>
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck3}}</div>
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck2}}</div>
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck1}}</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">รวมจำนวนเครื่องหมายแต่ละช่อง (1)</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck5}}</div>
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck4}}</div>
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck3}}</div>
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck2}}</div>
<div class="col-span-1 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].numberCheck1}}</div>
</div>
</div>
</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">ตัวคูณคะแนนในแต่ละช่อง (2)</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-1 text-center">{{setting.data.settingScore5}}</div>
<div class="col-span-1 text-center">{{setting.data.settingScore4}}</div>
<div class="col-span-1 text-center">{{setting.data.settingScore3}}</div>
<div class="col-span-1 text-center">{{setting.data.settingScore2}}</div>
<div class="col-span-1 text-center">{{setting.data.settingScore1}}</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">ตัวคูณคะแนนในแต่ละช่อง (2)</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-1 text-center">{{setting.data.settingScore5}}</div>
<div class="col-span-1 text-center">{{setting.data.settingScore4}}</div>
<div class="col-span-1 text-center">{{setting.data.settingScore3}}</div>
<div class="col-span-1 text-center">{{setting.data.settingScore2}}</div>
<div class="col-span-1 text-center">{{setting.data.settingScore1}}</div>
</div>
</div>
</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">ถ่วงน้ำหนักผลรวม 1X2</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-1 text-center" *ngFor="let item of [5,4,3,2,1]">{{calWeightScore(item)}}</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">ถ่วงน้ำหนักผลรวม 1X2</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-1 text-center" *ngFor="let item of [5,4,3,2,1]">{{calWeightScore(item)}}</div>
</div>
</div>
</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">คะแนนรวมหลังถ่วงน้ำ</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-5 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].weightedTotal}}</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">คะแนนรวมหลังถ่วงน้ำ</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-5 text-center">
{{appraisalCompentency.data.masfromEvaluationAssessment1lList[0].weightedTotal}}</div>
</div>
</div>
</div>
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">คะแนนเฉลี่ยคิดเป็น</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-5 text-center">
{{showNumber(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].averageScore)}}
<div class="py-2 grid grid-cols-11">
<div class="col-span-8">คะแนนเฉลี่ยคิดเป็น</div>
<div class="col-span-3 grid grid-cols-5">
<div class="col-span-5 text-center">
{{showNumber(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].averageScore)}}
</div>
</div>
</div>
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="overflow-auto rounded-top-0.65rem">
<table class="ti-custom-table ti-custom-table-head ti-custom-table-hover">
<thead class="height-50px">
<tr class="font-size-12px">
<ng-container
*ngFor="let item of ['เกณฑ์การให้คะแนนการประประเมิน Check Sheet E01','ผลประเมิน (A)','สรุปผล Gap'];let f = first ;let l = last">
<th scope="col" [attr.rowspan]="f?'1':'2'" [attr.colspan]="f?'2':'1'"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">{{ item }}</span>
<div *ngIf="!f&&!l" class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
<div class="pb-2rem px-2rem">
<div class="overflow-auto rounded-top-0.65rem">
<table class="ti-custom-table ti-custom-table-head ti-custom-table-hover">
<thead class="height-50px">
<tr class="font-size-12px">
<ng-container
*ngFor="let item of ['เกณฑ์การให้คะแนนการประประเมิน Check Sheet E01','ผลประเมิน (A)','สรุปผล Gap'];let f = first ;let l = last">
<th scope="col" [attr.rowspan]="f?'1':'2'" [attr.colspan]="f?'2':'1'"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">{{ item }}</span>
<div *ngIf="!f&&!l" class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th *ngIf="f" scope="col" rowspan="2"
class="relative bg-soft-secondary text-primary !text-center !p-0">
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
</ng-container>
</tr>
<tr class="font-size-12px">
<ng-container *ngFor="let item of ['เกณฑ์การให้คะแนน','เงื่อนไข']">
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
{{item}}
</th>
</ng-container>
</tr>
</thead>
<tbody *ngIf="checkSheet.length">
<tr *ngFor="let item of checkSheet;let i = index">
<td class="align-start" rowspan="2">
<div *ngFor="let item2 of item.score">
<span>{{item2}} </span><br>
</div>
</th>
<th *ngIf="f" scope="col" rowspan="2"
class="relative bg-soft-secondary text-primary !text-center !p-0">
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</td>
<td class="align-start" rowspan="2">
<div *ngFor="let item2 of item.condition">
<span>{{item2}} </span><br>
</div>
</th>
</ng-container>
</tr>
<tr class="font-size-12px">
<ng-container *ngFor="let item of ['เกณฑ์การให้คะแนน','เงื่อนไข']">
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
{{item}}
</th>
</ng-container>
</tr>
</thead>
<tbody *ngIf="checkSheet.length">
<tr *ngFor="let item of checkSheet;let i = index">
<td class="align-start" rowspan="2">
<div *ngFor="let item2 of item.score">
<span>{{item2}} </span><br>
</div>
</td>
<td class="align-start" rowspan="2">
<div *ngFor="let item2 of item.condition">
<span>{{item2}} </span><br>
</div>
</td>
<td class="!p-0"></td>
<td class="align-start text-center">
{{calAverage(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].averageScore)}}
</td>
<td class="align-start text-center">
{{calGap(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].averageScore)}}
</td>
</tr>
<tr>
<td class="align-start !white-space-normal" colspan="4">
หมายเหตุ<br>
ผลการประเมินอาจมีการเปลี่ยนแปลงเงื่อนไขข้อ 1-3 เนื่องจากมีคะแนนต่ำกว่าเกณฑ์ในบางข้อ
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="py-1rem px-2rem">
<div class="py-2 grid grid-cols-7 gap-3">
<div class="col-span-1">ผู้ถูกประเมิน</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsassessy.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none "
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsassessyStatus=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='0'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='0'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsassessyComment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsassessyDate)}}
</span>
</td>
<td class="!p-0"></td>
<td class="align-start text-center">
{{calAverage(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].averageScore)}}
</td>
<td class="align-start text-center">
{{calGap(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].averageScore)}}
</td>
</tr>
<tr>
<td class="align-start !white-space-normal" colspan="4">
หมายเหตุ<br>
ผลการประเมินอาจมีการเปลี่ยนแปลงเงื่อนไขข้อ 1-3 เนื่องจากมีคะแนนต่ำกว่าเกณฑ์ในบางข้อ
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove1.employeeId">
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove2.employeeId?'ผู้ประเมิน1':'ผู้อนุมัติ'}}
<div class="py-1rem px-2rem">
<div class="py-2 grid grid-cols-7 gap-3">
<div class="col-span-1">ผู้ถูกประเมิน</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsassessy.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none "
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsassessyStatus=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='0'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='0'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsassessyComment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsassessyDate)}}
</span>
</div>
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove1.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove1.employeeId">
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove2.employeeId?'ผู้ประเมิน1':'ผู้อนุมัติ'}}
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove1.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove1Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='1'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='1'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove1Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove1Date)}}
</span>
</div>
</div>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove2.employeeId">
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove3.employeeId?'ผู้ประเมิน2':'ผู้อนุมัติ'}}
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove1Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='1'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='1'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove1Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove1Date)}}
</span>
</div>
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove2.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove2.employeeId">
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove3.employeeId?'ผู้ประเมิน2':'ผู้อนุมัติ'}}
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove2.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove2Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='2'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='2'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove2Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove2Date)}}
</span>
</div>
</div>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove3.employeeId">
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove4.employeeId?'ผู้ประเมิน3':'ผู้อนุมัติ'}}
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove2Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='2'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='2'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove2Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove2Date)}}
</span>
</div>
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove3.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove3.employeeId">
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove4.employeeId?'ผู้ประเมิน3':'ผู้อนุมัติ'}}
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove3.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove3Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='3'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='3'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove3Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove3Date)}}
</span>
</div>
</div>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove4.employeeId">
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove5.employeeId?'ผู้ประเมิน4':'ผู้อนุมัติ'}}
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove3Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='3'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='3'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove3Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove3Date)}}
</span>
</div>
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove4.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove4.employeeId">
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove5.employeeId?'ผู้ประเมิน4':'ผู้อนุมัติ'}}
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove4.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove4Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='4'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='4'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove4Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove4Date)}}
</span>
</div>
</div>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove5.employeeId">
<div class="col-span-1">
ผู้อนุมัติ
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove4Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='4'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='4'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove4Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove4Date)}}
</span>
</div>
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove5.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="appraisalCompentency.data.apsapprove5.employeeId">
<div class="col-span-1">
ผู้อนุมัติ
</div>
<div class="col-span-1">
{{appraisalCompentency.data.apsapprove5.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove5Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='5'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='5'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove5Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove5Date)}}
</span>
[checked]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove5Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='5'||!canEdit"
[readonly]="!appraisalCompentency.data||appraisalCompentency.data.currentStep!='5'||!canEdit"
[(ngModel)]="appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove5Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(appraisalCompentency.data.masfromEvaluationAssessment1lList[0].apsapprove5Date)}}
</span>
</div>
</div>
</div>
</div>
<div class="flex justify-center mb-1rem pb-2rem" *ngIf="canEdit">
<button type="submit" class="ti-btn ti-btn-success mx-2rem" (click)="save('draft')">
บันทึกร่าง
</button>
<button type="submit" class="ti-btn ti-btn-success mx-2rem" (click)="save()">
บันทึกข้อมูล
</button>
</div>
<div class="flex justify-center mb-1rem pb-2rem" *ngIf="canEdit">
<button type="submit" class="ti-btn ti-btn-success mx-2rem" (click)="save('draft')">
บันทึกร่าง
</button>
<button type="submit" class="ti-btn ti-btn-success mx-2rem" (click)="save()">
บันทึกข้อมูล
</button>
</div>
</ng-container>
</div>
\ No newline at end of file
......@@ -10,7 +10,7 @@
<div class="pb-2rem px-2rem pt-1.5rem w-full min-height-50px justify-between items-center">
<div class="flex">
<button type="button" class="ti-btn ti-btn-outline ti-btn-outline-light h-20px m-0 shadow-md text-blue-500"
(click)="returnPage()">
(click)="returnPath()">
<i class="ti ti-chevron-left"></i>
ย้อนกลับ
</button>
......@@ -19,259 +19,410 @@
</div>
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="font-size-18px font-weight-700 text-primary">
แผนพัฒนาบุคคลากรรายบุคคล
<ng-container *ngIf="formIdp.data">
<div class="pb-2rem px-2rem">
<div class="font-size-18px font-weight-700 text-primary">
แผนพัฒนาบุคคลากรรายบุคคล
</div>
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="font-size-18px font-weight-700 text-gray-500">
ส่วนที่ 1: ข้อมูลทั่วไป
<div class="pb-2rem px-2rem">
<div class="font-size-18px font-weight-700 text-gray-500">
ส่วนที่ 1: ข้อมูลทั่วไป
</div>
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="grid grid-cols-6 ">
<div class="col-span-3 grid grid-cols-6">
<div class="col-span-6 border p-2 pb-4">
<span>ผู้ใต้บังคับบัญชา</span>
<div class="pb-2rem px-2rem">
<div class="grid grid-cols-6">
<div class="col-span-6 grid grid-cols-6">
<div class="col-span-3 border p-2 pb-4">
<span>ผู้ใต้บังคับบัญชา</span>
</div>
<div class="col-span-3 border p-2 pb-4">
<span>ผู้บังคับบัญชา</span>
</div>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ชื่อ-สกุล</span>
<div class="col-span-6 grid grid-cols-6">
<div class="col-span-3 grid grid-cols-4">
<div class="col-span-1 p-2 border pb-4">
<span>ชื่อ-สกุล</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>{{formIdp.data.apsassessy.thFullName || ""}}</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ตำแหน่ง</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>{{formIdp.data.apsassessy.position.tdesc || ""}}</span>
</div>
</div>
<div class="col-span-3 grid grid-cols-4">
<div class="col-span-1 p-2 border pb-4">
<span>ชื่อ-สกุล</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>{{formIdp.data.boss.thFullName || ""}}</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ตำแหน่ง</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>{{formIdp.data.boss.position.tdesc || ""}}</span>
</div>
</div>
</div>
<div class="col-span-2 p-2 border pb-4">
<span>น.ส.พิมพร อูรณาการ</span>
<div class="col-span-6 grid grid-cols-6">
<div class="col-span-3 grid grid-cols-4">
<div class="col-span-1 p-2 border pb-4">
<span>งาน</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>{{formIdp.data.apsassessy.job.tdesc || ""}}</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ฝ่าย</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>{{formIdp.data.apsassessy.bu1.tdesc || ""}}</span>
</div>
</div>
<div class="col-span-3 grid grid-cols-4">
<div class="col-span-1 p-2 border pb-4">
<span>งาน</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>{{formIdp.data.boss.job.tdesc || ""}}</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ฝ่าย</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>{{formIdp.data.boss.bu1.tdesc || ""}}</span>
</div>
</div>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ตำแหน่ง</span>
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="font-size-18px font-weight-700 text-gray-500">
ส่วนที่ 2: แนวทางการพัฒนา
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="overflow-auto rounded-top-0.65rem">
<table class="ti-custom-table ti-custom-table-head ti-custom-table-hover2">
<thead class="height-50px">
<tr class="font-size-12px">
<th scope="col" rowspan="3"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">{{'สมรรถนะที่พัฒนา\n(Competency)'}}</span>
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th scope="col" rowspan="3"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">
{{'ประเด็นตัวชี้พฤติกรรมที่ต้องพัฒนา\n(Behavior Indicators : BIs)'}}
</span>
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th scope="col" colspan="3"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">เครื่องมือพัฒนา</span>
</th>
<th scope="col" rowspan="3"
class="relative bg-soft-secondary text-primary !text-center !p-0">
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th scope="col" colspan="2" rowspan="2"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">หลักสูตรพัฒนาตาม CDR</span>
</th>
<th scope="col" rowspan="3"
class="relative bg-soft-secondary text-primary !text-center !p-0">
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th scope="col" rowspan="3"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">ระยะเวลาที่พัฒนา</span>
</th>
</tr>
<tr class="font-size-12px">
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
70
</th>
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
20
</th>
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
10
</th>
</tr>
<tr class="font-size-12px">
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
OJT/Job Assignment
</th>
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
Coach/Mentor
</th>
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
Training
</th>
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
รหัส
</th>
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
ชื่อหลักสูตร
</th>
</tr>
</thead>
<tbody *ngIf="!formIdp.data.competencyIndicatorsCourses1.length">
<tr class="hover:table-hover2-hover">
<td class="text-center" colspan="100%">
ไม่พบข้อมูล
</td>
</tr>
</tbody>
<tbody *ngIf="formIdp.data.competencyIndicatorsCourses1.length">
<ng-container *ngFor=" let data of formIdp.data.competencyIndicatorsCourses1;let i = index">
<tr (mouseenter)="hoveredCode = data.indicatorsCourses0.competencyTopic.competencyTopicId"
(mouseleave)="hoveredCode = null"
[ngClass]="{ 'table-hover2': data.indicatorsCourses0.competencyTopic.competencyTopicId === hoveredCode }">
<td class="align-start">
{{i+1}}. {{data.indicatorsCourses0.competencyTopic.competencyTopicId}}
</td>
<td class="align-start !white-space-normal"
[class.bg-table-gray]="!data.behavioralIndicators||!data.behavioralIndicators.length">
<div class="mb-3" *ngFor="let bis of data.behavioralIndicators;let i2 = index">
{{i2+1}}. {{bis.behavioralIndicators }}
</div>
</td>
<td class="align-start text-center"
[class.bg-table-gray]="!data.idpDevelopmentPlan||!data.idpDevelopmentPlan.ojtJobAssignment">
<ng-container
*ngIf="data.idpDevelopmentPlan&&data.idpDevelopmentPlan.ojtJobAssignment">
<i class="ti ti-check fs-xxl !fw-b"></i>
</ng-container>
</td>
<td class="align-start text-center"
[class.bg-table-gray]="!data.idpDevelopmentPlan||!data.idpDevelopmentPlan.coachMentor">
<ng-container *ngIf="data.idpDevelopmentPlan&&data.idpDevelopmentPlan.coachMentor">
<i class="ti ti-check fs-xxl !fw-b"></i>
</ng-container>
</td>
<td class="align-start text-center"
[class.bg-table-gray]="!data.idpDevelopmentPlan||!data.idpDevelopmentPlan.training">
<ng-container *ngIf="data.idpDevelopmentPlan&&data.idpDevelopmentPlan.training">
<i class="ti ti-check fs-xxl !fw-b"></i>
</ng-container>
</td>
<td class="!p-0"></td>
<td class="align-start text-center" [class.bg-table-gray]="!data.competencyCourse">
<div class="mb-3" *ngFor="let competencyCourse of data.competencyCourse">
<i class="ti ti-book fs-xxl !fw-b"></i><br>
{{competencyCourse.competencyCourseId }}
</div>
</td>
<td class="align-start text-center !white-space-normal"
[class.bg-table-gray]="!data.competencyCourse">
<div class="mb-3" *ngFor="let competencyCourse of data.competencyCourse">
{{competencyCourse.tdesc }}
</div>
</td>
<td class="!p-0"></td>
<td class="align-start text-center !white-space-normal"
[class.bg-table-gray]="!formIdp.data.masfromEvaluationRound.apsPeriodStart &&!formIdp.data.masfromEvaluationRound.apsPeriodEnd">
<ng-container
*ngIf="formIdp.data.masfromEvaluationRound.apsPeriodStart &&formIdp.data.masfromEvaluationRound.apsPeriodEnd">
จาก&nbsp;
</ng-container>
{{convertDateFormat(formIdp.data.masfromEvaluationRound.apsPeriodStart)}}
<ng-container
*ngIf="formIdp.data.masfromEvaluationRound.apsPeriodStart &&formIdp.data.masfromEvaluationRound.apsPeriodEnd">
&nbsp;ถึง&nbsp;
</ng-container>
{{convertDateFormat(formIdp.data.masfromEvaluationRound.apsPeriodEnd)}}
</td>
</tr>
</ng-container>
</tbody>
</table>
</div>
</div>
<div class="py-1rem px-2rem">
<div class="py-2 grid grid-cols-6 gap-3">
<div class="col-span-6">หมายเหตุ : กรณี HR จัดอบรมให้ต้องเป็นไปตามเกณ์ที่ส่วนกลางกำหนดขึ้น</div>
<div class="col-span-6 grid grid-cols-6 gap-2">
<div class="grid col-span-1 grid-cols-6 gap-2">
<div class="col-span-1">
<input type="checkbox" class="ti-form-checkbox" id="idpStatus-0"
[class.pointer-events-none]="formIdp.data.masfromEvaluationIdp.idpStatus=='0'||!canEdit"
name="idpStatus" (change)="formIdp.data.masfromEvaluationIdp.idpStatus='0'"
[checked]="formIdp.data.masfromEvaluationIdp.idpStatus=='0'">
</div>
<div class="col-span-5">
<label for="idpStatus-0" class="text-sm text-gray-500"
[class.pointer-events-none]="formIdp.data.masfromEvaluationIdp.idpStatus=='0'||!canEdit">
IDP มาตราฐาน
</label>
</div>
</div>
<div class="grid col-span-1 grid-cols-6 gap-2">
<div class="col-span-1">
<input type="checkbox" class="ti-form-checkbox" id="idpStatus-1"
[class.pointer-events-none]="formIdp.data.masfromEvaluationIdp.idpStatus=='1'||!canEdit"
name="idpStatus" (change)="formIdp.data.masfromEvaluationIdp.idpStatus='1'"
[checked]="formIdp.data.masfromEvaluationIdp.idpStatus=='1'">
</div>
<div class="col-span-5">
<label for="idpStatus-1" class="text-sm text-gray-500"
[class.pointer-events-none]="formIdp.data.masfromEvaluationIdp.idpStatus=='1'||!canEdit">
IDP ปรับแก้ไข
</label>
</div>
</div>
</div>
<div class="col-span-2 p-2 border pb-4">
<span>Human Resource Development Officer S3</span>
</div>
</div>
<div class="py-1rem px-2rem">
<div class="py-2 grid grid-cols-7 gap-3">
<div class="col-span-1">
{{formIdp.data.apsapprove2.employeeId?'ผู้ประเมิน1':'ผู้อนุมัติ'}}
</div>
<div class="col-span-1">
{{formIdp.data.apsapprove1.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="formIdp.data.masfromEvaluationIdp.apsapprove1Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>งาน</span>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!formIdp.data||formIdp.data.currentStep!='1'||!canEdit"
[readonly]="!formIdp.data||formIdp.data.currentStep!='1'||!canEdit"
[(ngModel)]="formIdp.data.masfromEvaluationIdp.apsapprove1Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(formIdp.data.masfromEvaluationIdp.apsapprove1Date)}}
</span>
</div>
<div class="col-span-2 p-2 border pb-4">
<span></span>
</div>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="formIdp.data.apsapprove2.employeeId">
<div class="col-span-1">
{{formIdp.data.apsapprove3.employeeId?'ผู้ประเมิน2':'ผู้อนุมัติ'}}
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ฝ่าย</span>
<div class="col-span-1">
{{formIdp.data.apsapprove2.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="formIdp.data.masfromEvaluationIdp.apsapprove2Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2 p-2 border pb-4">
<span></span>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!formIdp.data||formIdp.data.currentStep!='2'||!canEdit"
[readonly]="!formIdp.data||formIdp.data.currentStep!='2'||!canEdit"
[(ngModel)]="formIdp.data.masfromEvaluationIdp.apsapprove2Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(formIdp.data.masfromEvaluationIdp.apsapprove2Date)}}
</span>
</div>
</div>
<div class="col-span-3 grid grid-cols-6">
<div class="col-span-6 border p-2 pb-4">
<span>ผู้ใต้บังคับบัญชา</span>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="formIdp.data.apsapprove3.employeeId">
<div class="col-span-1">
{{formIdp.data.apsapprove4.employeeId?'ผู้ประเมิน3':'ผู้อนุมัติ'}}
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ชื่อ-สกุล</span>
<div class="col-span-1">
{{formIdp.data.apsapprove3.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="formIdp.data.masfromEvaluationIdp.apsapprove3Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2 p-2 border pb-4">
<span>น.ส. นดี แป้นศรี</span>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!formIdp.data||formIdp.data.currentStep!='3'||!canEdit"
[readonly]="!formIdp.data||formIdp.data.currentStep!='3'||!canEdit"
[(ngModel)]="formIdp.data.masfromEvaluationIdp.apsapprove3Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(formIdp.data.masfromEvaluationIdp.apsapprove3Date)}}
</span>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ตำแหน่ง</span>
</div>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="formIdp.data.apsapprove4.employeeId">
<div class="col-span-1">
{{formIdp.data.apsapprove5.employeeId?'ผู้ประเมิน4':'ผู้อนุมัติ'}}
</div>
<div class="col-span-2 p-2 border pb-4">
<span>HRM Senior Section Manager</span>
<div class="col-span-1">
{{formIdp.data.apsapprove4.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="formIdp.data.masfromEvaluationIdp.apsapprove4Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-1 p-2 border pb-4">
<span>งาน</span>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!formIdp.data||formIdp.data.currentStep!='4'||!canEdit"
[readonly]="!formIdp.data||formIdp.data.currentStep!='4'||!canEdit"
[(ngModel)]="formIdp.data.masfromEvaluationIdp.apsapprove4Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(formIdp.data.masfromEvaluationIdp.apsapprove4Date)}}
</span>
</div>
<div class="col-span-2 p-2 border pb-4">
<span></span>
</div>
<div class="py-2 grid grid-cols-7 gap-3" *ngIf="formIdp.data.apsapprove5.employeeId">
<div class="col-span-1">
ผู้อนุมัติ
</div>
<div class="col-span-1 p-2 border pb-4">
<span>ฝ่าย</span>
<div class="col-span-1">
{{formIdp.data.apsapprove5.thFullName}}</div>
<div class="col-span-1">
<input type="checkbox" id="hs-basic-usage1" class="ti-switch checked:bg-none checked:bg-green-600 checked:hover:bg-green-600 checked:focus:bg-green-600 focus:border-green-600 focus:ring-green-600 dark:checked:bg-green-600
checked:before:bg-green-200 dark:checked:before:bg-green-200 pointer-events-none"
[checked]="formIdp.data.masfromEvaluationIdp.apsapprove5Status=='2'">
<label for="hs-basic-usage1" class="sr-only">ยืนยันผล</label>
</div>
<div class="col-span-2 p-2 border pb-4">
<span></span>
<div class="col-span-2">
<textarea type="text" rows="2" class="ti-form-input mb-2" placeholder="ใส่ Comment ที่นี่"
[class.!bg-input-readonly]="!formIdp.data||formIdp.data.currentStep!='5'||!canEdit"
[readonly]="!formIdp.data||formIdp.data.currentStep!='5'||!canEdit"
[(ngModel)]="formIdp.data.masfromEvaluationIdp.apsapprove5Comment"></textarea>
<span class="pt-2">
วันที่ :
{{convertDate(formIdp.data.masfromEvaluationIdp.apsapprove5Date)}}
</span>
</div>
</div>
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="font-size-18px font-weight-700 text-gray-500">
ส่วนที่ 2: แนวทางการพัฒนา
</div>
</div>
<div class="pb-2rem px-2rem">
<div class="overflow-auto rounded-top-0.65rem">
<table class="ti-custom-table ti-custom-table-head ti-custom-table-hover2">
<thead class="height-50px">
<tr class="font-size-12px">
<th scope="col" rowspan="3"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">{{'สมรรถนะที่พัฒนา\n(Competency)'}}</span>
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th scope="col" rowspan="3"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">
{{'ประเด็นตัวชี้พฤติกรรมที่ต้องพัฒนา\n(Behavior Indicators : BIs)'}}
</span>
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th scope="col" colspan="3"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">เครื่องมือพัฒนา</span>
</th>
<th scope="col" rowspan="3" class="relative bg-soft-secondary text-primary !text-center !p-0">
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th scope="col" colspan="2" rowspan="2"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">หลักสูตรพัฒนาตาม CDR</span>
</th>
<th scope="col" rowspan="3" class="relative bg-soft-secondary text-primary !text-center !p-0">
<div class="absolute top-1/2 transform -translate-y-1/2 right-0">
<i class="ti ti-dots-vertical fs-l"></i>
</div>
</th>
<th scope="col" rowspan="3"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
<span class="font-size-12px font-weight-700 ">ระยะเวลาที่พัฒนา</span>
</th>
</tr>
<tr class="font-size-12px">
<th scope="col" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
70
</th>
<th scope="col" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
20
</th>
<th scope="col" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
10
</th>
</tr>
<tr class="font-size-12px">
<th scope="col" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
OJT/Job Assignment
</th>
<th scope="col" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
Coach/Mentor
</th>
<th scope="col" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
Training
</th>
<th scope="col" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
รหัส
</th>
<th scope="col" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center">
ชื่อหลักสูตร
</th>
</tr>
</thead>
<tbody *ngIf="!dataListFilter().length">
<tr class="hover:table-hover2-hover">
<td class="text-center" colspan="100%">
ไม่พบข้อมูล
</td>
</tr>
</tbody>
<tbody *ngIf="dataListFilter().length">
<ng-container *ngFor=" let data of dataListFilter();let i = index">
<tr *ngIf="!data.bis.length" (mouseenter)="hoveredCode = data.code"
(mouseleave)="hoveredCode = null" [ngClass]="{ 'table-hover2': data.code === hoveredCode }">
<td class="align-start">
{{i+1}}. {{data.code}}
</td>
<td class="align-start bg-table-gray"></td>
<td class="align-start bg-table-gray"></td>
<td class="align-start bg-table-gray"></td>
<td class="align-start bg-table-gray"></td>
<td class="!p-0"></td>
<td class="align-start bg-table-gray"></td>
<td class="align-start bg-table-gray"></td>
<td class="!p-0"></td>
<td class="align-start text-center !white-space-normal"
[class.bg-table-gray]="!data.startDate&&!data.endDate">
<ng-container *ngIf="data.startDate&&data.endDate">
จาก&nbsp;
</ng-container>
{{data.startDate}}
<ng-container *ngIf="data.startDate&&data.endDate">
&nbsp;ถึง&nbsp;
</ng-container>
{{data.endDate}}
</td>
</tr>
<tr *ngFor=" let item of data.bis;let i2 = index;let f = first"
(mouseenter)="hoveredCode = data.code" (mouseleave)="hoveredCode = null"
[ngClass]="{ 'table-hover2': data.code === hoveredCode ,'border-none':!f }">
<td class="align-start">
<ng-container *ngIf="f">
{{i+1}}. {{data.code}}
</ng-container>
</td>
<td class="align-start !white-space-normal" [class.bg-table-gray]="checkBg(data.bis,'oj')">
{{i2+1}}. {{item.name}}
</td>
<td class="align-start text-center" [class.bg-table-gray]="checkBg(data.bis,'oj')">
<ng-container *ngIf="item.oj">
<i class="ti ti-check fs-xxl !fw-b"></i>
</ng-container>
</td>
<td class="align-start text-center" [class.bg-table-gray]="checkBg(data.bis,'cm')">
<ng-container *ngIf="item.cm">
<i class="ti ti-check fs-xxl !fw-b"></i>
</ng-container>
</td>
<td class="align-start text-center" [class.bg-table-gray]="checkBg(data.bis,'t')">
<ng-container *ngIf="item.t">
<i class="ti ti-check fs-xxl !fw-b"></i>
</ng-container>
</td>
<td class="!p-0">
</td>
<td class="align-start text-center" [class.bg-table-gray]="checkBg(data.bis,'cdr.code')">
<ng-container *ngIf="item.cdr.code">
<i class="ti ti-book fs-xxl !fw-b"></i><br>
{{item.cdr.code}}
</ng-container>
</td>
<td class="align-start !white-space-normal"
[class.bg-table-gray]="checkBg(data.bis,'cdr.name')">
<ng-container *ngIf="item.cdr.name">
<div class="grid grid-cols-6">
<div class="col-span-1">
<input type="checkbox" class="ti-form-checkbox cursor-pointer"
[(ngModel)]="item.cdr.check">
</div>
<div class="col-span-5">
{{item.cdr.name}}
</div>
</div>
</ng-container>
</td>
<td class="!p-0">
</td>
<td class="align-start !white-space-normal"
[class.bg-table-gray]="!data.startDate&&!data.endDate">
<ng-container *ngIf="data.startDate&&data.endDate">
จาก<br>
</ng-container>
<span class="whitespace-nowrap">
{{data.startDate}}
</span>
<ng-container *ngIf="data.startDate&&data.endDate">
<br>ถึง<br>
</ng-container>
<span class="whitespace-nowrap">
{{data.endDate}}
</span>
</td>
</tr>
</ng-container>
</tbody>
</table>
<div class="flex justify-center mb-1rem pb-2rem" *ngIf="canEdit">
<button type="submit" class="ti-btn ti-btn-success mx-2rem" (click)="save('draft')">
บันทึกร่าง
</button>
<button type="submit" class="ti-btn ti-btn-success mx-2rem" (click)="save()">
บันทึกข้อมูล
</button>
</div>
</div>
</ng-container>
</ng-template>
\ No newline at end of file
import { Component, EventEmitter, Output } from '@angular/core';
export interface DataModel {
code: string,
bis: BisModel[],
startDate: string,
endDate: string
}
export interface BisModel {
name: string,
oj: boolean,
cm: boolean,
t: boolean,
cdr: CdrModel
}
export interface CdrModel {
check: boolean,
name: string,
code: string
}
import { ChangeDetectorRef, Component, EventEmitter, Input, Output } from '@angular/core';
import { IdpFormModel } from 'src/app/shared/model/idp-form.model';
import { EmployeeService } from 'src/app/shared/services/employee.service';
import { EvaluationIdpService } from 'src/app/shared/services/evaluation-Idp.service';
import Swal from 'sweetalert2';
@Component({
selector: 'app-idp-evalution',
templateUrl: './idp-evalution.component.html',
styleUrls: ['./idp-evalution.component.scss']
})
export class IdpEvalutionComponent {
@Output() sendPageEvalution: EventEmitter<string> = new EventEmitter<string>();
pathTitle = ['การประเมินผล', 'ประเมินผล']
@Input() pathTitle: string[] = []
@Input() evaluationRoundId = ""
@Input() evaluateeId = ""
@Input() evaluaterId = ""
@Output() sendReturnPath: EventEmitter<any> = new EventEmitter<any>();
currentDate = new Date()
hoveredCode: string | null = null;
dataList: DataModel[] = [{
code: "CC-01",
bis: [{
name: "สอนงานด้านความปลอดภัย และคุณภาพของบริษัทให้กับพนักงานในหน่วยงาน",
oj: true,
cm: false,
t: true,
cdr: {
check: false,
name: "จิตใต้สำนึกด้านความปลอดภัยและคุณภาพ (Safety & Quality) สำหรับระดับพนักงาน S3-S4",
code: "CC-01-4"
}
}, {
name: "ติดตามและปรับปรุงการทำงานด้านความปลอดภัยและ คุณภาพของทีมงาน",
oj: false,
cm: false,
t: false,
cdr: {
check: false,
name: "",
code: ""
}
}],
startDate: "01-01-2023",
endDate: "31-12-2023"
}, {
code: "CC-02",
bis: [{
name: "สอนงาน และพัฒนาทีมงานให้เกิดการทำงานเป็นทีมโดยยึดเป้าหมายเดียวกัน (TAT Goal) และคำนึงถึงความต้องการของลูกค้าเป็นหลัก (Next Customer)",
oj: true,
cm: false,
t: false,
cdr: {
check: false,
name: "",
code: ""
formIdp: { loading: boolean, data?: IdpFormModel } = { loading: false, data: undefined }
canEdit = false
constructor(private evaluationIdpService: EvaluationIdpService,
private employeeService: EmployeeService,
private cdr: ChangeDetectorRef
) {
}
ngOnInit(): void {
this.getFormIdp()
}
getFormIdp() {
this.formIdp.loading = true
this.evaluationIdpService.getFormIdp(this.evaluationRoundId, this.evaluateeId).subscribe({
next: response => {
this.formIdp.data = JSON.parse(JSON.stringify(response))
console.log(" 🐒 this.formIdp.data:", this.formIdp.data?.competencyIndicatorsCourses1)
switch (this.formIdp.data?.currentStep) {
case ("0"): {
this.formIdp.data.masfromEvaluationIdp.apsassessyDate = this.currentDate.toISOString().split('T')[0];
this.canEdit = this.evaluaterId == this.formIdp.data.apsassessy.employeeId
break
}
case ("1"): {
this.formIdp.data.masfromEvaluationIdp.apsapprove1Date = this.currentDate.toISOString().split('T')[0];
this.canEdit = this.evaluaterId == this.formIdp.data.apsapprove1.employeeId
break
}
case ("2"): {
this.formIdp.data.masfromEvaluationIdp.apsapprove2Date = this.currentDate.toISOString().split('T')[0];
this.canEdit = this.evaluaterId == this.formIdp.data.apsapprove2.employeeId
break
}
case ("3"): {
this.formIdp.data.masfromEvaluationIdp.apsapprove3Date = this.currentDate.toISOString().split('T')[0];
this.canEdit = this.evaluaterId == this.formIdp.data.apsapprove3.employeeId
break
}
case ("4"): {
this.formIdp.data.masfromEvaluationIdp.apsapprove4Date = this.currentDate.toISOString().split('T')[0];
this.canEdit = this.evaluaterId == this.formIdp.data.apsapprove4.employeeId
break
}
case ("5"): {
this.formIdp.data.masfromEvaluationIdp.apsapprove5Date = this.currentDate.toISOString().split('T')[0];
this.canEdit = this.evaluaterId == this.formIdp.data.apsapprove5.employeeId
break
}
default: { return }
}
this.formIdp.loading = false
this.cdr.detectChanges()
}, error: error => {
this.formIdp.loading = false
this.cdr.detectChanges()
}
}],
startDate: "01-01-2023",
endDate: "31-12-2023"
}, {
code: "CC-03",
bis: [],
startDate: "",
endDate: ""
}]
getNestedValue(obj: any, path: string) {
return path.split('.').reduce((acc, key) => acc && acc[key], obj);
})
}
checkBg(data: any[], field: string) {
return data.every(x => !this.getNestedValue(x, field));
returnPath() {
this.sendReturnPath.emit()
}
convertDate(dateInput?: string | Date): string {
let date = new Date()
if (dateInput) {
if (typeof dateInput === 'string') {
const [year, month, day] = dateInput.split('-').map(Number);
date = new Date(year, month - 1, day);
} else {
date = dateInput
}
}
return date?.toLocaleDateString('th-TH', { day: 'numeric', month: 'long', year: 'numeric' }) || ''
}
dataListFilter() {
return this.dataList
convertDateFormat(dateString: string): string {
const [year, month, day] = dateString.split("-");
return `${day}-${month}-${year}`;
}
returnPage() {
this.sendPageEvalution.emit("")
save(status?: string) {
Swal.fire({
iconHtml: `
<div class="flex items-center justify-center rounded-full !h-80px !w-80px" style="background-color: #E8F8EE;">
<svg width="39" height="39" viewBox="0 0 39 39" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect width="39" height="39" fill="#D2D2D2"/>
<g id="Component">
<g id="alert cart">
<g id="mdi:file-export">
<circle cx="22.5" cy="19.5" r="33.5" fill="#E8F8EE"/>
<path d="M9.75 3.25C8.88805 3.25 8.0614 3.59241 7.4519 4.2019C6.84241 4.8114 6.5 5.63805 6.5 6.5V32.5C6.5 33.362 6.84241 34.1886 7.4519 34.7981C8.0614 35.4076 8.88805 35.75 9.75 35.75H29.25C30.112 35.75 30.9386 35.4076 31.5481 34.7981C32.1576 34.1886 32.5 33.362 32.5 32.5V13L22.75 3.25M21.125 5.6875L30.0625 14.625H21.125M14.5113 19.8575H26V31.3463L22.555 27.9013L17.9563 32.5L13.3575 27.9013L17.9563 23.3188"
fill="#1DBE5A"/>
</g>
</g>
</g>
</svg>
</div>
`,
title: status == 'draft' ? 'บันทึกแบบร่าง' : 'บันทึกข้อมูล',
text: status == 'draft' ? 'คุณต้องการบันทึกแบบร่างของการประเมินนี้ใช่หรือไม่' : 'คุณต้องการบันทึกข้อมูลการประเมินนี้ใช่หรือไม่',
showCancelButton: true,
confirmButtonText: 'ยืนยันการบันทึก',
cancelButtonText: 'ย้อนกลับ',
customClass: {
title: '!swal2-title-mt-20px',
actions: '!swal2-actions-mt-20px',
icon: '!swal2-icon-no-border',
confirmButton: '!swal2-button-bg-green',
cancelButton: '!swal2-button-bg-gray',
},
}).then((result) => {
if (result.isConfirmed && this.formIdp) {
this.saveApi(status)
} else if (result.dismiss === Swal.DismissReason.cancel) {
Swal.fire({
title: 'ยกเลิก!',
text: 'การบันทึกถูกยกเลิก',
icon: 'error',
customClass: {
confirmButton: '!swal2-button-bg-danger',
}
})
}
})
}
saveApi(status?: string) {
let body = this.formIdp.data
switch (this.formIdp.data?.currentStep) {
case ("0"): {
body = {
...this.formIdp.data, masfromEvaluationIdp: {
...this.formIdp.data.masfromEvaluationIdp,
apsassessyStatus: status == 'draft' ? '1' : '2'
}
}
break
}
case ("1"): {
body = {
...this.formIdp.data, masfromEvaluationIdp: {
...this.formIdp.data.masfromEvaluationIdp,
apsapprove1Status: status == 'draft' ? '1' : '2'
}
}
break
}
case ("2"): {
body = {
...this.formIdp.data, masfromEvaluationIdp: {
...this.formIdp.data.masfromEvaluationIdp,
apsapprove2Status: status == 'draft' ? '1' : '2'
}
}
break
}
case ("3"): {
body = {
...this.formIdp.data, masfromEvaluationIdp: {
...this.formIdp.data.masfromEvaluationIdp,
apsapprove3Status: status == 'draft' ? '1' : '2'
}
}
break
}
case ("4"): {
body = {
...this.formIdp.data, masfromEvaluationIdp: {
...this.formIdp.data.masfromEvaluationIdp,
apsapprove4Status: status == 'draft' ? '1' : '2'
}
}
break
}
case ("5"): {
body = {
...this.formIdp.data, masfromEvaluationIdp: {
...this.formIdp.data.masfromEvaluationIdp,
apsapprove5Status: status == 'draft' ? '1' : '2'
}
}
break
}
default: { return }
}
this.evaluationIdpService.postIdp(body).subscribe({
next: response => {
if (response.success) {
Swal.fire({
title: 'บันทึกสำเร็จ!',
text: 'การประเมินของคุณถูกบันทึกแล้ว',
icon: 'success',
customClass: {
confirmButton: '!swal2-button-bg-green',
}
});
this.getFormIdp()
} else {
Swal.fire({
title: 'ยกเลิก!',
text: 'การบันทึกถูกยกเลิก',
icon: 'error',
customClass: {
confirmButton: '!swal2-button-bg-danger',
}
});
}
}, error: error => {
Swal.fire({
title: 'ยกเลิก!',
text: 'การบันทึกถูกยกเลิก',
icon: 'error',
customClass: {
confirmButton: '!swal2-button-bg-danger',
}
});
}
})
}
}
......@@ -104,7 +104,7 @@
</td>
<td style="font-size: 12px;">{{item.apsassessy.position.tdesc}}</td>
<td class="text-center">
<div class="flex">
<div class="flex justify-center">
<button type="button" class="ti-btn rounded-sm "
*ngFor="let type of item.typeList"
[class.ti-btn-soft-secondary]="type.statusType == 'employee'"
......@@ -117,10 +117,16 @@
</div>
</td>
<td class="text-center">
<!-- <button type="button" class="ti-btn rounded-sm ti-btn-soft-dark"
style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;">
IDP
</button> -->
<div class="flex justify-center">
<button type="button" class="ti-btn rounded-sm"
[class.ti-btn-soft-secondary]="item.statusIdp.statusType == 'employee'"
[class.ti-btn-soft-warning]="item.statusIdp.statusType != 'employee'&&item.statusIdp.statusType != 'Boss_finish'"
[class.ti-btn-soft-success]="item.statusIdp.statusType == 'Boss_finish'"
style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;"
(click)="selectSubordinate(item,'',subordinate.select?.evaluationRoundId);pageEvalution='idp'">
IDP
</button>
</div>
</td>
<td class="text-center">
<!-- <button type="button" class="ti-btn rounded-sm ti-btn-soft-success"
......@@ -190,14 +196,17 @@
</ng-container>
<ng-container *ngIf="pageEvalution=='idp'">
<app-idp-evalution (sendPageEvalution)="pageEvalution=$event"></app-idp-evalution>
<app-idp-evalution [pathTitle]="['การประเมินผล', 'ประเมินโดยหัวหน้า','ประเมิน']"
(sendReturnPath)="getBossList();pageEvalution='' ; pathTitle = ['การประเมินผล', 'ประเมินโดยหัวหน้า']"
[evaluationRoundId]="formEvaluation.evaluationRoundId" [evaluaterId]="formEvaluation.evaluaterId"
[evaluateeId]="formEvaluation.evaluateeId"></app-idp-evalution>
</ng-container>
<ng-container *ngIf="pageEvalution=='pms'">
<app-pms-evalution (sendPageEvalution)="pageEvalution=$event"></app-pms-evalution>
</ng-container>
<ng-container *ngIf="pageEvalution=='evaluation'">
<app-evaluation [pathTitle]="['การประเมินผล', 'ประเมินโดยหัวหน้า','ประเมิน']"
(sendReturnPath)="pageEvalution='' ; pathTitle = ['การประเมินผล', 'ประเมินโดยหัวหน้า']"
(sendReturnPath)="getBossList();pageEvalution='' ; pathTitle = ['การประเมินผล', 'ประเมินโดยหัวหน้า']"
[evaluationRoundId]="formEvaluation.evaluationRoundId" [evaluaterId]="formEvaluation.evaluaterId"
[evaluateeId]="formEvaluation.evaluateeId"
[competencyTypeId]="formEvaluation.competencyTypeId"></app-evaluation>
......
......@@ -67,7 +67,7 @@ export class SupervisorEvaluationComponent {
this.page = Array.from({ length: Math.ceil(this.subordinateFilter().length / 10) }, (_, i) => i + 1);
}
selectSubordinate(data: Masfromevaluationassessment, competencyTypeId: string, evaluationRoundId?: string) {
if (data && competencyTypeId && evaluationRoundId) {
if (data && evaluationRoundId) {
this.formEvaluation.evaluateeId = data.apsassessy.employeeId
this.formEvaluation.competencyTypeId = competencyTypeId
this.formEvaluation.evaluationRoundId = evaluationRoundId
......
......@@ -15,6 +15,10 @@ export interface Masfromevaluationassessment {
gread: string
sumScore: number
typeList: TypeList[]
statusIdp: {
shortName: string,
statusType: string
}
}
export interface MasfromStatusType {
......
export interface IdpFormModel {
personalLevel: PersonalLevel
masfromEvaluationRound: MasfromEvaluationRound
companyId: string
active: boolean
masfromStatusType: MasfromStatusType
currentStep: string
lastStep: string
apsassessy: Apsassessy
apsapprove1: Apsapprove1
apsapprove2: Apsapprove2
apsapprove3: Apsapprove3
apsapprove4: Apsapprove4
apsapprove5: Apsapprove5
masfromEvaluationIdp: MasfromEvaluationIdp
competencyIndicatorsCourses1: CompetencyIndicatorsCourses1[]
boss: Boss
}
export interface PersonalLevel {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface MasfromEvaluationRound {
evaluationRoundId: string
companyId: string
tdesc: string
edesc: string
apsyear: string
apsPeriodStart: string
apsPeriodEnd: string
}
export interface MasfromStatusType {
code: string
tdesc: string
edesc: string
}
export interface Apsassessy {
employeeId: string
bossId: string
prefix: Prefix
fname: string
lname: string
efname: string
elname: string
bu1: Bu1
bu2: Bu2
bu3: Bu3
bu4: Bu4
bu5: Bu5
position: Position
job: Job
pl: Pl
status: Status
time0: Time0
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu1 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu2 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu3 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu4 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu5 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time0 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove1 {
employeeId: string
bossId: string
prefix: Prefix2
fname: string
lname: string
efname: string
elname: string
bu1: Bu12
bu2: Bu22
bu3: Bu32
bu4: Bu42
bu5: Bu52
position: Position2
job: Job2
pl: Pl2
status: Status2
time0: Time02
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix2 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu12 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu22 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu32 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu42 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu52 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position2 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job2 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl2 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status2 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time02 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove2 {
employeeId: string
bossId: string
prefix: Prefix3
fname: string
lname: string
efname: string
elname: string
bu1: Bu13
bu2: Bu23
bu3: Bu33
bu4: Bu43
bu5: Bu53
position: Position3
job: Job3
pl: Pl3
status: Status3
time0: Time03
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix3 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu13 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu23 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu33 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu43 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu53 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position3 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job3 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl3 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status3 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time03 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove3 {
employeeId: string
bossId: string
prefix: Prefix4
fname: string
lname: string
efname: string
elname: string
bu1: Bu14
bu2: Bu24
bu3: Bu34
bu4: Bu44
bu5: Bu54
position: Position4
job: Job4
pl: Pl4
status: Status4
time0: Time04
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix4 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu14 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu24 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu34 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu44 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu54 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position4 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job4 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl4 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status4 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time04 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove4 {
employeeId: string
bossId: string
prefix: Prefix5
fname: string
lname: string
efname: string
elname: string
bu1: Bu15
bu2: Bu25
bu3: Bu35
bu4: Bu45
bu5: Bu55
position: Position5
job: Job5
pl: Pl5
status: Status5
time0: Time05
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix5 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu15 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu25 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu35 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu45 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu55 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position5 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job5 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl5 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status5 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time05 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove5 {
employeeId: string
bossId: string
prefix: Prefix6
fname: string
lname: string
efname: string
elname: string
bu1: Bu16
bu2: Bu26
bu3: Bu36
bu4: Bu46
bu5: Bu56
position: Position6
job: Job6
pl: Pl6
status: Status6
time0: Time06
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix6 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu16 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu26 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu36 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu46 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu56 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position6 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job6 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl6 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status6 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time06 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface MasfromEvaluationIdp {
masfromEvaluationAssessment: MasfromEvaluationAssessment
plId: string
companyId: string
apsassessyStatus: string
apsapprove1Status: string
apsapprove2Status: string
apsapprove3Status: string
apsapprove4Status: string
apsapprove5Status: string
apsassessyComment: string
apsapprove1Comment: string
apsapprove2Comment: string
apsapprove3Comment: string
apsapprove4Comment: string
apsapprove5Comment: string
apsassessyDate: string
apsapprove1Date: string
apsapprove2Date: string
apsapprove3Date: string
apsapprove4Date: string
apsapprove5Date: string
idpStatus: string
}
export interface MasfromEvaluationAssessment {
personalLevel: PersonalLevel2
masfromEvaluationRound: MasfromEvaluationRound2
companyId: string
active: boolean
apsassessy: Apsassessy2
apsapprove1: Apsapprove12
apsapprove2: Apsapprove22
apsapprove3: Apsapprove32
apsapprove4: Apsapprove42
apsapprove5: Apsapprove52
masfromEvaluationAssessment1: MasfromEvaluationAssessment1[]
}
export interface PersonalLevel2 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface MasfromEvaluationRound2 {
evaluationRoundId: string
companyId: string
tdesc: string
edesc: string
apsyear: string
apsPeriodStart: string
apsPeriodEnd: string
personalLevel: PersonalLevel3[]
jlId: string
active: number
statusFrom: StatusFrom
statusCode: StatusCode
}
export interface PersonalLevel3 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface StatusFrom {
code: string
tdesc: string
edesc: string
}
export interface StatusCode {
code: string
tdesc: string
edesc: string
}
export interface Apsassessy2 {
employeeId: string
bossId: string
prefix: Prefix7
fname: string
lname: string
efname: string
elname: string
bu1: Bu17
bu2: Bu27
bu3: Bu37
bu4: Bu47
bu5: Bu57
position: Position7
job: Job7
pl: Pl7
status: Status7
time0: Time07
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix7 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu17 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu27 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu37 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu47 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu57 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position7 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job7 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl7 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status7 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time07 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove12 {
employeeId: string
bossId: string
prefix: Prefix8
fname: string
lname: string
efname: string
elname: string
bu1: Bu18
bu2: Bu28
bu3: Bu38
bu4: Bu48
bu5: Bu58
position: Position8
job: Job8
pl: Pl8
status: Status8
time0: Time08
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix8 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu18 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu28 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu38 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu48 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu58 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position8 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job8 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl8 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status8 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time08 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove22 {
employeeId: string
bossId: string
prefix: Prefix9
fname: string
lname: string
efname: string
elname: string
bu1: Bu19
bu2: Bu29
bu3: Bu39
bu4: Bu49
bu5: Bu59
position: Position9
job: Job9
pl: Pl9
status: Status9
time0: Time09
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix9 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu19 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu29 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu39 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu49 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu59 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position9 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job9 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl9 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status9 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time09 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove32 {
employeeId: string
bossId: string
prefix: Prefix10
fname: string
lname: string
efname: string
elname: string
bu1: Bu110
bu2: Bu210
bu3: Bu310
bu4: Bu410
bu5: Bu510
position: Position10
job: Job10
pl: Pl10
status: Status10
time0: Time010
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix10 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu110 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu210 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu310 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu410 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu510 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position10 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job10 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl10 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status10 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time010 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove42 {
employeeId: string
bossId: string
prefix: Prefix11
fname: string
lname: string
efname: string
elname: string
bu1: Bu111
bu2: Bu211
bu3: Bu311
bu4: Bu411
bu5: Bu511
position: Position11
job: Job11
pl: Pl11
status: Status11
time0: Time011
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix11 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu111 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu211 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu311 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu411 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu511 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position11 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job11 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl11 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status11 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time011 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface Apsapprove52 {
employeeId: string
bossId: string
prefix: Prefix12
fname: string
lname: string
efname: string
elname: string
bu1: Bu112
bu2: Bu212
bu3: Bu312
bu4: Bu412
bu5: Bu512
position: Position12
job: Job12
pl: Pl12
status: Status12
time0: Time012
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix12 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu112 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu212 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu312 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu412 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu512 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position12 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job12 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl12 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status12 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time012 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
export interface MasfromEvaluationAssessment1 {
plId: string
companyId: string
lineNo: number
competencyType: CompetencyType
masfromStatusType: MasfromStatusType2
currentStep: string
lastStep: string
apsassessyStatus: string
apsapprove1Status: string
apsapprove2Status: string
apsapprove3Status: string
apsapprove4Status: string
apsapprove5Status: string
numberCheck1: number
numberCheck2: number
numberCheck3: number
numberCheck4: number
numberCheck5: number
weightedTotal: number
averageScore: number
apsassessyComment: string
apsapprove1Comment: string
apsapprove2Comment: string
apsapprove3Comment: string
apsapprove4Comment: string
apsapprove5Comment: string
apsassessyDate: string
apsapprove1Date: string
apsapprove2Date: string
apsapprove3Date: string
apsapprove4Date: string
apsapprove5Date: string
evaluationResults: string
sumEvaluationResults: string
}
export interface CompetencyType {
competencyTypeId: string
companyId: string
edesc: string
tdesc: string
shortName: string
expectationLevel: string
weight: number
}
export interface MasfromStatusType2 {
code: string
tdesc: string
edesc: string
}
export interface CompetencyIndicatorsCourses1 {
indicatorsCourses0: IndicatorsCourses0
competencyCourseId: string
competencyCourse: CompetencyCourse[]
behavioralIndicators: BehavioralIndicator[]
idpDevelopmentPlan: IdpDevelopmentPlan
}
export interface IndicatorsCourses0 {
competencyTopic: CompetencyTopic
companyId: string
edesc: string
tdesc: string
indicatorsCourseDetailTh: string
indicatorsCourseDetailEn: string
}
export interface CompetencyTopic {
competencyTopicId: string
competencyType: CompetencyType2
companyId: string
edesc: string
tdesc: string
competencyDetail: string
competencyFiles: string
lineNo: number
expectationLevel: string
}
export interface CompetencyType2 {
competencyTypeId: string
companyId: string
edesc: string
tdesc: string
shortName: string
expectationLevel: string
weight: number
}
export interface CompetencyCourse {
competencyCourseId: string
companyId: string
edesc: string
tdesc: string
}
export interface BehavioralIndicator {
competencyIndicators1: CompetencyIndicators1
runNo: number
companyId: string
assessmentId: string
behavioralIndicators: string
competencyAssessment: CompetencyAssessment[]
}
export interface CompetencyIndicators1 {
competencyIndicatorsCourses0: CompetencyIndicatorsCourses0
lineNo: number
companyId: string
competencyCourseId: string
}
export interface CompetencyIndicatorsCourses0 {
competencyTopic: CompetencyTopic2
companyId: string
edesc: string
tdesc: string
indicatorsCourseDetailTh: string
indicatorsCourseDetailEn: string
}
export interface CompetencyTopic2 {
competencyTopicId: string
competencyType: CompetencyType3
companyId: string
edesc: string
tdesc: string
competencyDetail: string
competencyFiles: string
lineNo: number
expectationLevel: string
}
export interface CompetencyType3 {
competencyTypeId: string
companyId: string
edesc: string
tdesc: string
shortName: string
expectationLevel: string
weight: number
}
export interface CompetencyAssessment {
assessmentId: string
companyId: string
edesc: string
tdesc: string
shortName: string
}
export interface IdpDevelopmentPlan {
planId: string
companyId: string
ojtJobAssignment: boolean
coachMentor: boolean
training: boolean
}
export interface Boss {
employeeId: string
bossId: string
prefix: Prefix13
fname: string
lname: string
efname: string
elname: string
bu1: Bu113
bu2: Bu213
bu3: Bu313
bu4: Bu413
bu5: Bu513
position: Position13
job: Job13
pl: Pl13
status: Status13
time0: Time013
resignDate: string
endWorkDate: string
startDate: string
thFullName: string
engFullName: string
}
export interface Prefix13 {
prefixId: string
tdesc: string
edesc: string
}
export interface Bu113 {
bu1id: string
tdesc: string
edesc: string
companyId: string
}
export interface Bu213 {
bu2id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu313 {
bu3id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu413 {
bu4id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Bu513 {
bu5id: string
tdesc: string
edesc: string
parent: string
companyId: string
}
export interface Position13 {
positionId: string
tdesc: string
edesc: string
consolidate: string
shortName: string
companyId: string
}
export interface Job13 {
jobCodeId: string
tdesc: string
edesc: string
}
export interface Pl13 {
plId: string
tdesc: string
edesc: string
companyId: string
}
export interface Status13 {
statusCode: string
statusType: string
tdesc: string
edesc: string
}
export interface Time013 {
time0id: string
tdesc: string
edesc: string
stickTm: string
hourD: number
}
import { HttpClient } from '@angular/common/http';
import { Injectable } from '@angular/core';
import { Observable } from 'rxjs';
import { environment } from 'src/environments/environment';
import { AlertModel } from '../model/alert.model';
import { IdpFormModel } from '../model/idp-form.model';
@Injectable({
providedIn: 'root'
})
export class EvaluationIdpService {
api = "/evaluation-Idp"
urlApi = environment.baseUrl + this.api
constructor(private http: HttpClient) {
}
getFormIdp(evaluationRoundId: string, employeeId: string): Observable<IdpFormModel> {
return this.http.get<IdpFormModel>(this.urlApi + "/" + evaluationRoundId + "/" + employeeId)
}
postIdp(body: IdpFormModel): Observable<AlertModel> {
return this.http.post<AlertModel>(this.urlApi + "/", body)
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment