Commit 31dc0ed4 by Nattana Chaiyamat

ประเมินตนเอง

parent f23f1e12
...@@ -71,8 +71,8 @@ ...@@ -71,8 +71,8 @@
</a> </a>
</div> </div>
</th> </th>
<th scope="col" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
[ngStyle]="{'width': (evaluaterId!=evaluateeId||currentStep != '0') ?'325px' :'500px;'}"> <th scope="col" style="width:500px">
ระดับความสามารถ ระดับความสามารถ
<div class="hs-tooltip ti-main-tooltip [--trigger:hover]"> <div class="hs-tooltip ti-main-tooltip [--trigger:hover]">
<a class="hs-tooltip-toggle ti-main-tooltip-toggle" href="javascript:;"> <a class="hs-tooltip-toggle ti-main-tooltip-toggle" href="javascript:;">
...@@ -99,7 +99,37 @@ ...@@ -99,7 +99,37 @@
</a> </a>
</div> </div>
</th> </th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนลูกน้อง</th> </ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col" style="width:325px">
ระดับความสามารถ
<div class="hs-tooltip ti-main-tooltip [--trigger:hover]">
<a class="hs-tooltip-toggle ti-main-tooltip-toggle" href="javascript:;">
<i class="ti ti-help-circle"></i>
<div class="hs-tooltip-content ti-main-tooltip-content border-secondary" role="tooltip">
<div class="flex flex-col">
<div>ระดับความสามารถ (Target Degree)</div>
<div class="text-start">
ระดับ 1 = ไม่มีความรู้พื้นฐานเลย ขาดทักษะในงาน</div>
<div class="text-start">
ระดับ 2 = มีความรู้ในงานบ้างแต่ยังไม่สามารถ ประยุกต์ใช้ในงานได้
</div>
<div class="text-start">
ระดับ 3 = นำความรู้มาประยุกต์ใช้ในงานได้ ปฏิบัติงานเองได้ด้วยตัวเองแก้ไขปัญหาหน้างานได้
</div>
<div class="text-start">
ระดับ 4 = สอนผู้อื่นได้ มีความคล่องตัว เชื่อมโยง ความรู้ในงานได้
</div>
<div class="text-start">
ระดับ 5 = มีความชำนาญ เชี่ยวชาญ เป็นที่ยอมรับ ในองค์กร
</div>
</div>
</div>
</a>
</div>
</th>
<th scope="col">ประเมินตนเอง</th>
</ng-container>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
...@@ -114,7 +144,7 @@ ...@@ -114,7 +144,7 @@
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
<div class="flex flex-row justify-center gap-2 mb-2"> <div class="flex flex-row justify-center gap-2 mb-2">
<ng-container *ngFor="let item of [5,4,3,2,1];let f = first"> <ng-container *ngFor="let item of [5,4,3,2,1];let f = first">
<ng-container *ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<button type="button" <button type="button"
class="h-12 w-12 p-0 shadow border text-soft-secondary-no-hover bg-white" class="h-12 w-12 p-0 shadow border text-soft-secondary-no-hover bg-white"
style="border-radius:10px" style="border-radius:10px"
...@@ -128,7 +158,7 @@ ...@@ -128,7 +158,7 @@
{{item}} {{item}}
</button> </button>
</ng-container> </ng-container>
<ng-container *ngIf="!(evaluaterId!=evaluateeId||currentStep != '0')"> <ng-container *ngIf="evaluaterId!=evaluateeId&&!complete">
<button type="button" <button type="button"
class="h-12 w-12 p-0 shadow border text-soft-secondary-no-hover bg-white" class="h-12 w-12 p-0 shadow border text-soft-secondary-no-hover bg-white"
style="border-radius:10px" style="border-radius:10px"
...@@ -154,10 +184,11 @@ ...@@ -154,10 +184,11 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center text-indigo-600 font-semibold" style="vertical-align: top" <ng-container *ngIf="evaluaterId!=evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td class="py-2 text-center text-indigo-600 font-semibold" style="vertical-align: top">
{{bi.competencyBehavioral.scoreTopicExpectationEmp}} {{bi.competencyBehavioral.scoreTopicExpectationEmp}}
</td> </td>
</ng-container>
</tr> </tr>
</ng-container> </ng-container>
</tbody> </tbody>
......
...@@ -13,6 +13,7 @@ import Swal from 'sweetalert2'; ...@@ -13,6 +13,7 @@ import Swal from 'sweetalert2';
styleUrls: ['./pms-competency.component.scss'] styleUrls: ['./pms-competency.component.scss']
}) })
export class PmsCompetencyComponent { export class PmsCompetencyComponent {
@Input() complete = false
@Input() fCurrentPart = "" @Input() fCurrentPart = ""
currentPart = "" currentPart = ""
@Input() canSave = false @Input() canSave = false
......
...@@ -140,7 +140,7 @@ ...@@ -140,7 +140,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="w-full" *ngIf="currentTap=='แบบประเมินสมรรถนะ'"> <div class="w-full" *ngIf="currentTap=='แบบประเมินสมรรถนะ'&&(evaluaterId!=evaluateeId||complete)">
<div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px"> <div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px">
<div class="box-header" [class.border-none]="menuClose.get('ค่าถ่วงน้ำหนักของความสามารถในแต่ละระดับ')"> <div class="box-header" [class.border-none]="menuClose.get('ค่าถ่วงน้ำหนักของความสามารถในแต่ละระดับ')">
<div class="flex justify-between"> <div class="flex justify-between">
...@@ -198,25 +198,29 @@ ...@@ -198,25 +198,29 @@
</div> </div>
</div> </div>
</div> </div>
<div class="w-full" <div class="w-full" *ngIf="currentTap=='แบบประเมินสมรรถนะ'">
*ngIf="currentTap=='แบบประเมินสมรรถนะ' &&(evaluaterId!=evaluateeId||compentency.data ? compentency.data?.currentStep != '0': false)">
<div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px"> <div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px">
<div class="box-header" <div class="box-header"
[class.border-none]="menuClose.get('ค่าถ่วงน้ำหนักลูกน้องของความสามารถในแต่ละระดับ')"> [class.border-none]="menuClose.get('ค่าถ่วงน้ำหนักตนเองของความสามารถในแต่ละระดับ')">
<div class="flex justify-between"> <div class="flex justify-between">
<h5 class="box-title align-center">ค่าถ่วงน้ำหนักลูกน้องของความสามารถในแต่ละระดับ</h5> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<i *ngIf="menuClose.get('ค่าถ่วงน้ำหนักลูกน้องของความสามารถในแต่ละระดับ')" title="แสดง" <h5 class="box-title align-center">ค่าถ่วงน้ำหนักของความสามารถในแต่ละระดับ</h5>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<h5 class="box-title align-center">ค่าถ่วงน้ำหนักตนเองของความสามารถในแต่ละระดับ</h5>
</ng-container>
<i *ngIf="menuClose.get('ค่าถ่วงน้ำหนักตนเองของความสามารถในแต่ละระดับ')" title="แสดง"
class="bg-white cursor-pointer border ti ti-chevron-down" class="bg-white cursor-pointer border ti ti-chevron-down"
style="padding: 1px;border-radius:10px;font-size:27px;height:33px" style="padding: 1px;border-radius:10px;font-size:27px;height:33px"
(click)="menuClose.set('ค่าถ่วงน้ำหนักลูกน้องของความสามารถในแต่ละระดับ',false)"></i> (click)="menuClose.set('ค่าถ่วงน้ำหนักตนเองของความสามารถในแต่ละระดับ',false)"></i>
<i *ngIf="!menuClose.get('ค่าถ่วงน้ำหนักลูกน้องของความสามารถในแต่ละระดับ')" title="ปิด" <i *ngIf="!menuClose.get('ค่าถ่วงน้ำหนักตนเองของความสามารถในแต่ละระดับ')" title="ปิด"
class="bg-white cursor-pointer border ti ti-chevron-up" class="bg-white cursor-pointer border ti ti-chevron-up"
style="padding: 1px;border-radius:10px;font-size:27px;height:33px" style="padding: 1px;border-radius:10px;font-size:27px;height:33px"
(click)="menuClose.set('ค่าถ่วงน้ำหนักลูกน้องของความสามารถในแต่ละระดับ',true)"></i> (click)="menuClose.set('ค่าถ่วงน้ำหนักตนเองของความสามารถในแต่ละระดับ',true)"></i>
</div> </div>
</div> </div>
<div class="box-body py-2" <div class="box-body py-2"
[class.hidden]="menuClose.get('ค่าถ่วงน้ำหนักลูกน้องของความสามารถในแต่ละระดับ')"> [class.hidden]="menuClose.get('ค่าถ่วงน้ำหนักตนเองของความสามารถในแต่ละระดับ')">
<div class="w-full flex flex-col gap-2" *ngIf="compentency.data"> <div class="w-full flex flex-col gap-2" *ngIf="compentency.data">
<div class="w-full flex flex-col gap-2 mt-2"> <div class="w-full flex flex-col gap-2 mt-2">
<div class="w-full flex flex-row gap-2"> <div class="w-full flex flex-row gap-2">
...@@ -259,7 +263,8 @@ ...@@ -259,7 +263,8 @@
</div> </div>
</div> </div>
</div> </div>
<div class="w-full" *ngIf="currentTap=='ประเมินผลการปฏิบัติงาน'||currentTap=='สรุปคะแนนและข้อเสนอแนะ'"> <div class="w-full"
*ngIf="(currentTap=='ประเมินผลการปฏิบัติงาน'||currentTap=='สรุปคะแนนและข้อเสนอแนะ')&&(evaluaterId!=evaluateeId||complete)">
<div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px"> <div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px">
<div class="box-header" [class.border-none]="menuClose.get('สรุปผลประเมิน')"> <div class="box-header" [class.border-none]="menuClose.get('สรุปผลประเมิน')">
<div class="flex justify-between"> <div class="flex justify-between">
...@@ -328,23 +333,27 @@ ...@@ -328,23 +333,27 @@
</div> </div>
</div> </div>
</div> </div>
<div class="w-full" <div class="w-full" *ngIf="(currentTap=='ประเมินผลการปฏิบัติงาน'||currentTap=='สรุปคะแนนและข้อเสนอแนะ')">
*ngIf="(currentTap=='ประเมินผลการปฏิบัติงาน'||currentTap=='สรุปคะแนนและข้อเสนอแนะ')&&(evaluaterId!=evaluateeId||compentency.data ? compentency.data?.currentStep != '0': false)">
<div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px"> <div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px">
<div class="box-header" [class.border-none]="menuClose.get('สรุปผลประเมินลูกน้อง')"> <div class="box-header" [class.border-none]="menuClose.get('สรุปผลประเมินตนเอง')">
<div class="flex justify-between"> <div class="flex justify-between">
<h5 class="box-title align-center">สรุปผลประเมินลูกน้อง</h5> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<i *ngIf="menuClose.get('สรุปผลประเมินลูกน้อง')" title="แสดง" <h5 class="box-title align-center">สรุปผลประเมิน</h5>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<h5 class="box-title align-center">สรุปผลประเมินตนเอง</h5>
</ng-container>
<i *ngIf="menuClose.get('สรุปผลประเมินตนเอง')" title="แสดง"
class="bg-white cursor-pointer border ti ti-chevron-down" class="bg-white cursor-pointer border ti ti-chevron-down"
style="padding: 1px;border-radius:10px;font-size:27px" style="padding: 1px;border-radius:10px;font-size:27px"
(click)="menuClose.set('สรุปผลประเมินลูกน้อง',false)"></i> (click)="menuClose.set('สรุปผลประเมินตนเอง',false)"></i>
<i *ngIf="!menuClose.get('สรุปผลประเมินลูกน้อง')" title="ปิด" <i *ngIf="!menuClose.get('สรุปผลประเมินตนเอง')" title="ปิด"
class="bg-white cursor-pointer border ti ti-chevron-up" class="bg-white cursor-pointer border ti ti-chevron-up"
style="padding: 1px;border-radius:10px;font-size:27px" style="padding: 1px;border-radius:10px;font-size:27px"
(click)="menuClose.set('สรุปผลประเมินลูกน้อง',true)"></i> (click)="menuClose.set('สรุปผลประเมินตนเอง',true)"></i>
</div> </div>
</div> </div>
<div class="box-body py-2 flex flex-col gap-6 " [class.hidden]="menuClose.get('สรุปผลประเมินลูกน้อง')"> <div class="box-body py-2 flex flex-col gap-6 " [class.hidden]="menuClose.get('สรุปผลประเมินตนเอง')">
<div class='flex-1 flex flex-row gap-2'> <div class='flex-1 flex flex-row gap-2'>
<div class="flex-1 flex flex-col gap-2"> <div class="flex-1 flex flex-col gap-2">
<ng-container *ngFor="let item of kpiScorePartEmp; let i=index"> <ng-container *ngFor="let item of kpiScorePartEmp; let i=index">
...@@ -570,13 +579,14 @@ ...@@ -570,13 +579,14 @@
<div class="min-height: calc(100vh - 406px);" [class.hidden]="currentTap!='ข้อมูลการประเมิน'"> <div class="min-height: calc(100vh - 406px);" [class.hidden]="currentTap!='ข้อมูลการประเมิน'">
<app-pms-information [statusType]="compentency.data.statusType" [canSave]="canSave" <app-pms-information [statusType]="compentency.data.statusType" [canSave]="canSave"
[appraisalPms]="compentency.data.pms" [appraisalCompentencyList]="compentency.data.competency" [appraisalPms]="compentency.data.pms" [appraisalCompentencyList]="compentency.data.competency"
[inforGap]="inforGap" [inforWeight]="inforWeight" [inforGapEmp]="inforGapEmp" [inforWeightEmp]="inforWeightEmp" [inforGap]="inforGap" [inforWeight]="inforWeight" [inforGapEmp]="inforGapEmp"
[inforWeightEmp]="inforWeightEmp"
[kpiScore]="kpiScorePart.length > 1 ?kpiScorePart[kpiScorePart.length-2].score : ''" [kpiScore]="kpiScorePart.length > 1 ?kpiScorePart[kpiScorePart.length-2].score : ''"
[kpiScoreEmp]="kpiScorePartEmp.length > 1 ?kpiScorePartEmp[kpiScorePartEmp.length-2].score : ''" [kpiScoreEmp]="kpiScorePartEmp.length > 1 ?kpiScorePartEmp[kpiScorePartEmp.length-2].score : ''"
[kpiGrade]="kpiScorePart.length > 0 ?kpiScorePart[kpiScorePart.length-1].score : ''" [kpiGrade]="kpiScorePart.length > 0 ?kpiScorePart[kpiScorePart.length-1].score : ''"
[kpiName]="compentency.data.tdesc" (sendCurrentTap)="currentTap=$event" [kpiName]="compentency.data.tdesc" (sendCurrentTap)="currentTap=$event"
(sendCurrentPart)="currentPart=$event" [evaluaterId]="evaluaterId" [evaluateeId]="evaluateeId" (sendCurrentPart)="currentPart=$event" [evaluaterId]="evaluaterId" [evaluateeId]="evaluateeId"
[currentStep]="compentency.data.currentStep"></app-pms-information> [currentStep]="compentency.data.currentStep" [complete]="complete"></app-pms-information>
</div> </div>
<div class="min-height: calc(100vh - 406px);" [class.hidden]="currentTap!='แบบประเมินสมรรถนะ'"> <div class="min-height: calc(100vh - 406px);" [class.hidden]="currentTap!='แบบประเมินสมรรถนะ'">
<app-pms-competency [currentTap]="currentTap" [canSave]="canSave" [fCurrentPart]="currentPart" <app-pms-competency [currentTap]="currentTap" [canSave]="canSave" [fCurrentPart]="currentPart"
...@@ -590,7 +600,8 @@ ...@@ -590,7 +600,8 @@
(compentencyFormRemain)="compentencyFormRemain=$event" (compentencyFormRemain)="compentencyFormRemain=$event"
(compentencyForm)="compentency.data.competency=$event" (sendInforGap)="inforGap=$event" (compentencyForm)="compentency.data.competency=$event" (sendInforGap)="inforGap=$event"
(sendInforWeight)="inforWeight=$event" (sendInforGapEmp)="inforGapEmp=$event" (sendInforWeight)="inforWeight=$event" (sendInforGapEmp)="inforGapEmp=$event"
(sendInforWeightEmp)="inforWeightEmp=$event" (scrollToMenuId)="scrollToMenu($event)"></app-pms-competency> (sendInforWeightEmp)="inforWeightEmp=$event" (scrollToMenuId)="scrollToMenu($event)"
[complete]="complete"></app-pms-competency>
</div> </div>
<div class="min-height: calc(100vh - 406px);" <div class="min-height: calc(100vh - 406px);"
[class.hidden]="currentTap!='ประเมินผลการปฏิบัติงาน'&&currentTap!='สรุปคะแนนและข้อเสนอแนะ'"> [class.hidden]="currentTap!='ประเมินผลการปฏิบัติงาน'&&currentTap!='สรุปคะแนนและข้อเสนอแนะ'">
...@@ -600,13 +611,13 @@ ...@@ -600,13 +611,13 @@
(kpiFormRemain)="kpiFormRemain=$event" (scorePart)="kpiScorePart=$event" (kpiFormRemain)="kpiFormRemain=$event" (scorePart)="kpiScorePart=$event"
(scorePartEmp)="kpiScorePartEmp=$event" (kpiForm)="compentency.data.pms=$event" (scorePartEmp)="kpiScorePartEmp=$event" (kpiForm)="compentency.data.pms=$event"
(scrollToMenuId)="scrollToMenu($event)" [inforWeight]="inforWeight" (scrollToMenuId)="scrollToMenu($event)" [inforWeight]="inforWeight"
[compentencyFormRemain]="compentencyFormRemain"></app-pms-kpi> [compentencyFormRemain]="compentencyFormRemain" [complete]="complete"></app-pms-kpi>
</div> </div>
<div class="min-height: calc(100vh - 406px);" [class.hidden]="currentTap!='แผนพัฒนาบุคลากร'"> <div class="min-height: calc(100vh - 406px);" [class.hidden]="currentTap!='แผนพัฒนาบุคลากร'">
<app-pms-idp [currentTap]="currentTap" [canSave]="canSave" [appraisalIdp]="compentency.data.idp" <app-pms-idp [currentTap]="currentTap" [canSave]="canSave" [appraisalIdp]="compentency.data.idp"
[evaluaterId]="evaluaterId" [evaluateeId]="evaluateeId" [evaluaterId]="evaluaterId" [evaluateeId]="evaluateeId"
[canEdit]="evaluationForm=='sup'?canEdit:false" [currentStep]="compentency.data.currentStep" [canEdit]="evaluationForm=='sup'?canEdit:false" [currentStep]="compentency.data.currentStep"
[dateIso]="dateIso" (idpForm)="compentency.data.idp=$event"></app-pms-idp> [dateIso]="dateIso" (idpForm)="compentency.data.idp=$event" [complete]="complete"></app-pms-idp>
</div> </div>
<ng-container *ngIf="compentency.data&&canSave"> <ng-container *ngIf="compentency.data&&canSave">
<div class="box-footer text-end space-x-3 rtl:space-x-reverse" <div class="box-footer text-end space-x-3 rtl:space-x-reverse"
......
...@@ -72,7 +72,7 @@ export class PmsFormEmployeeComponent { ...@@ -72,7 +72,7 @@ export class PmsFormEmployeeComponent {
hasPushedState = false; hasPushedState = false;
companyId = "" companyId = ""
complete = false
@ViewChild('scrollContainer') scrollContainer!: ElementRef; @ViewChild('scrollContainer') scrollContainer!: ElementRef;
...@@ -323,6 +323,7 @@ export class PmsFormEmployeeComponent { ...@@ -323,6 +323,7 @@ export class PmsFormEmployeeComponent {
selectDataList(data: CompetencyModel) { selectDataList(data: CompetencyModel) {
this.compentency.originalData = this.deepClone(data) this.compentency.originalData = this.deepClone(data)
this.compentency.data = this.deepClone(data) this.compentency.data = this.deepClone(data)
this.complete = this.compentency.data?.statusAll == 'complete'
this.cdr.detectChanges() this.cdr.detectChanges()
if (this.compentency.data) { if (this.compentency.data) {
this.currentTap = this.firstCurrentTap || "ข้อมูลการประเมิน" this.currentTap = this.firstCurrentTap || "ข้อมูลการประเมิน"
......
...@@ -316,7 +316,7 @@ ...@@ -316,7 +316,7 @@
จาก&nbsp; จาก&nbsp;
</ng-container> </ng-container>
<ng-container <ng-container
*ngIf="data.idpDevelopmentPlan&&data.idpDevelopmentPlan?.training && appraisalIdp.masfromEvaluationIdp.idpStatus=='1'"> *ngIf="data.idpDevelopmentPlan&&data.idpDevelopmentPlan?.training && appraisalIdp.apsapprove1.employeeId == evaluaterId">
<input type="date" id="input-label" class="ti-form-input" <input type="date" id="input-label" class="ti-form-input"
[(ngModel)]="appraisalIdp.masfromEvaluationRound.apsPeriodStart"> [(ngModel)]="appraisalIdp.masfromEvaluationRound.apsPeriodStart">
<ng-container <ng-container
...@@ -327,7 +327,7 @@ ...@@ -327,7 +327,7 @@
[(ngModel)]="appraisalIdp.masfromEvaluationRound.apsPeriodEnd"> [(ngModel)]="appraisalIdp.masfromEvaluationRound.apsPeriodEnd">
</ng-container> </ng-container>
<ng-container <ng-container
*ngIf="!(data.idpDevelopmentPlan&&data.idpDevelopmentPlan?.training) || appraisalIdp.masfromEvaluationIdp.idpStatus!='1'"> *ngIf="!(data.idpDevelopmentPlan&&data.idpDevelopmentPlan?.training) || appraisalIdp.apsapprove1.employeeId != evaluaterId">
{{convertDateFormat(appraisalIdp.masfromEvaluationRound.apsPeriodStart)}} {{convertDateFormat(appraisalIdp.masfromEvaluationRound.apsPeriodStart)}}
<ng-container <ng-container
*ngIf="appraisalIdp.masfromEvaluationRound.apsPeriodStart &&appraisalIdp.masfromEvaluationRound.apsPeriodEnd"> *ngIf="appraisalIdp.masfromEvaluationRound.apsPeriodStart &&appraisalIdp.masfromEvaluationRound.apsPeriodEnd">
......
...@@ -19,6 +19,7 @@ interface table { ...@@ -19,6 +19,7 @@ interface table {
styleUrls: ['./pms-idp.component.scss'] styleUrls: ['./pms-idp.component.scss']
}) })
export class PmsIdpComponent { export class PmsIdpComponent {
@Input() complete = false
@Input() canSave = false @Input() canSave = false
@Input() pathTitle: string[] = [] @Input() pathTitle: string[] = []
@Input() evaluationRoundId = "" @Input() evaluationRoundId = ""
...@@ -57,7 +58,7 @@ export class PmsIdpComponent { ...@@ -57,7 +58,7 @@ export class PmsIdpComponent {
this.getCompetencycourseMiniList() this.getCompetencycourseMiniList()
} }
ngOnChanges(changes: SimpleChanges): void { ngOnChanges(changes: SimpleChanges): void {
if (changes['currentTap']?.currentValue||changes['appraisalIdp']?.currentValue) { if (changes['currentTap']?.currentValue || changes['appraisalIdp']?.currentValue) {
this.getFormIdp() this.getFormIdp()
} }
} }
......
...@@ -13,11 +13,17 @@ ...@@ -13,11 +13,17 @@
<th scope="col">แบบการประเมิน</th> <th scope="col">แบบการประเมิน</th>
<th scope="col text-center">วันที่เริ่มต้น</th> <th scope="col text-center">วันที่เริ่มต้น</th>
<th scope="col text-center">วันที่สิ้นสุด</th> <th scope="col text-center">วันที่สิ้นสุด</th>
<th scope="col text-center" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนเฉลี่ยลูกน้อง <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<th scope="col text-center">คะแนนเฉลี่ย</th>
<th scope="col text-center">ผล GAP</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col text-center">คะแนนเฉลี่ยตนเอง
</th> </th>
<th scope="col text-center">คะแนนเฉลี่ย</th> <th scope="col text-center">คะแนนเฉลี่ย</th>
<th scope="col text-center" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">ผล GAP ลูกน้อง</th> <th scope="col text-center">ผล GAP ตนเอง</th>
<th scope="col text-center">ผล GAP</th> <th scope="col text-center">ผล GAP</th>
</ng-container>
<th scope="col text-center">การจัดการ</th> <th scope="col text-center">การจัดการ</th>
</tr> </tr>
</thead> </thead>
...@@ -36,21 +42,30 @@ ...@@ -36,21 +42,30 @@
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{formatThaiDate(item.masfromEvaluationRound.apsPeriodEnd)}} {{formatThaiDate(item.masfromEvaluationRound.apsPeriodEnd)}}
</td> </td>
<td class="py-2 text-center" style="vertical-align: top" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td class="py-2 text-center" style="vertical-align: top">
{{inforWeightEmp.get(item.comType)!=='undefined' && inforWeightEmp.get(item.comType)
!=='null'?inforWeightEmp.get(item.comType): '0'}}
</td>
<td class="py-2 text-center" style="vertical-align: top">
{{inforGapEmp.get(item.comType)!=='null'?inforGapEmp.get(item.comType): ''}}
</td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{inforWeightEmp.get(item.comType)!=='undefined' && inforWeightEmp.get(item.comType) {{inforWeightEmp.get(item.comType)!=='undefined' && inforWeightEmp.get(item.comType)
!=='null'?inforWeightEmp.get(item.comType): '0'}} !=='null'?inforWeightEmp.get(item.comType): '0'}}
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{inforWeight.get(item.comType) !=='null'?inforWeight.get(item.comType): '0'}} {{inforWeight.get(item.comType) !=='null'?inforWeight.get(item.comType): '0'}}
</td> </td>
<td class="py-2 text-center" style="vertical-align: top" <td class="py-2 text-center" style="vertical-align: top">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'">
{{inforGapEmp.get(item.comType)!=='null'?inforGapEmp.get(item.comType): ''}} {{inforGapEmp.get(item.comType)!=='null'?inforGapEmp.get(item.comType): ''}}
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{inforGap.get(item.comType)!=='null'?inforGap.get(item.comType): ''}} {{inforGap.get(item.comType)!=='null'?inforGap.get(item.comType): ''}}
</td> </td>
</ng-container>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
<div class="flex justify-center"> <div class="flex justify-center">
<button type="button" class="ti-btn rounded-sm" [class]="statusButtonClass(statusType)" <button type="button" class="ti-btn rounded-sm" [class]="statusButtonClass(statusType)"
...@@ -79,8 +94,13 @@ ...@@ -79,8 +94,13 @@
<th scope="col">แบบการประเมิน</th> <th scope="col">แบบการประเมิน</th>
<th scope="col text-center">วันที่เริ่มต้น</th> <th scope="col text-center">วันที่เริ่มต้น</th>
<th scope="col text-center">วันที่สิ้นสุด</th> <th scope="col text-center">วันที่สิ้นสุด</th>
<th scope="col text-center">ผลการประเมินลูกน้อง</th> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<th scope="col text-center">ผลการประเมิน</th> <th scope="col text-center">ผลการประเมิน</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col text-center">ผลการประเมินตนเอง</th>
<th scope="col text-center">ผลการประเมิน</th>
</ng-container>
<th scope="col text-center">เกรด</th> <th scope="col text-center">เกรด</th>
<th scope="col text-center">การจัดการ</th> <th scope="col text-center">การจัดการ</th>
</tr> </tr>
...@@ -98,13 +118,19 @@ ...@@ -98,13 +118,19 @@
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{formatThaiDate(appraisalPms.pmsMasfromEvaluationRoundModel.apsPeriodEnd)}} {{formatThaiDate(appraisalPms.pmsMasfromEvaluationRoundModel.apsPeriodEnd)}}
</td> </td>
<td *ngIf="evaluaterId!=evaluateeId||currentStep != '0'" class="py-2 text-center" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{kpiScoreEmp}}
</td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{kpiScoreEmp}} {{kpiScoreEmp}}
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{kpiScore}} {{kpiScore}}
</td> </td>
</ng-container>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{kpiGrade}} {{kpiGrade}}
</td> </td>
......
...@@ -8,6 +8,7 @@ import { Competency, Pms } from 'src/app/shared/model/competency.model'; ...@@ -8,6 +8,7 @@ import { Competency, Pms } from 'src/app/shared/model/competency.model';
}) })
export class PmsInformationComponent { export class PmsInformationComponent {
@Input() canSave = false @Input() canSave = false
@Input() complete = false
@Input() statusType = '' @Input() statusType = ''
@Input() inforWeight: Map<string, string> = new Map<string, string>() @Input() inforWeight: Map<string, string> = new Map<string, string>()
@Input() inforGap: Map<string, string> = new Map<string, string>() @Input() inforGap: Map<string, string> = new Map<string, string>()
......
...@@ -75,8 +75,13 @@ ...@@ -75,8 +75,13 @@
<th scope="col">น้ำหนัก</th> <th scope="col">น้ำหนัก</th>
<th scope="col">เพิ่มเติม</th> <th scope="col">เพิ่มเติม</th>
<th scope="col" style="width: 300px">ค่าเป้าหมาย</th> <th scope="col" style="width: 300px">ค่าเป้าหมาย</th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนลูกน้อง</th> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col">ประเมินตนเอง</th>
<th scope="col">คะแนน</th>
</ng-container>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
...@@ -191,14 +196,20 @@ ...@@ -191,14 +196,20 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * item.scoreTopicExpectation)}} {{numberFixed2(item.weight * item.scoreTopicExpectation)}}
</td> </td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{item.scoreTopicExpectation}}
</td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * {{numberFixed2(item.weight *
(evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}} (evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}}
</td> </td>
</ng-container>
</tr> </tr>
</ng-container> </ng-container>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
...@@ -218,13 +229,20 @@ ...@@ -218,13 +229,20 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScore(appraisalPms?.part1Detail)}} {{calExpectationTotalScore(appraisalPms?.part1Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> </ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class=" py-2"></td>
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBoss(appraisalPms?.part1Detail)}} {{calExpectationTotalScoreBoss(appraisalPms?.part1Detail)}}
</td> </td>
</ng-container>
</tr> </tr>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
<td class="align-start text-start !white-space-normal py-2" colspan="4"> <td class="align-start text-start !white-space-normal py-2" colspan="4">
...@@ -243,7 +261,7 @@ ...@@ -243,7 +261,7 @@
</div> </div>
</td> </td>
<td class=" py-2"></td> <td class=" py-2"></td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'"></td> <td class=" py-2" *ngIf="evaluaterId!=evaluateeId||complete"></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -269,8 +287,13 @@ ...@@ -269,8 +287,13 @@
<th scope="col">น้ำหนัก</th> <th scope="col">น้ำหนัก</th>
<th scope="col">เพิ่มเติม</th> <th scope="col">เพิ่มเติม</th>
<th scope="col" style="width: 300px;">ค่าเป้าหมาย</th> <th scope="col" style="width: 300px;">ค่าเป้าหมาย</th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนลูกน้อง</th> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<th scope="col">คะแนน</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col">ประเมินตนเอง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</ng-container>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
...@@ -385,14 +408,20 @@ ...@@ -385,14 +408,20 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * item.scoreTopicExpectation)}} {{numberFixed2(item.weight * item.scoreTopicExpectation)}}
</td> </td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{item.scoreTopicExpectation}}
</td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * {{numberFixed2(item.weight *
(evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}} (evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}}
</td> </td>
</ng-container>
</tr> </tr>
</ng-container> </ng-container>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
...@@ -412,13 +441,19 @@ ...@@ -412,13 +441,19 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScore(appraisalPms?.part2Detail)}} {{calExpectationTotalScore(appraisalPms?.part2Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> </ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class=" py-2"></td>
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBoss(appraisalPms?.part2Detail)}} {{calExpectationTotalScoreBoss(appraisalPms?.part2Detail)}}
</td> </td>
</ng-container>
</tr> </tr>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
<td class="align-start text-start !white-space-normal py-2" colspan="4"> <td class="align-start text-start !white-space-normal py-2" colspan="4">
...@@ -437,7 +472,7 @@ ...@@ -437,7 +472,7 @@
</div> </div>
</td> </td>
<td class=" py-2"></td> <td class=" py-2"></td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'"></td> <td class=" py-2" *ngIf="evaluaterId!=evaluateeId||complete"></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -463,8 +498,13 @@ ...@@ -463,8 +498,13 @@
<th scope="col">น้ำหนัก</th> <th scope="col">น้ำหนัก</th>
<th scope="col">เพิ่มเติม</th> <th scope="col">เพิ่มเติม</th>
<th scope="col" style="width: 300px;">ค่าเป้าหมาย</th> <th scope="col" style="width: 300px;">ค่าเป้าหมาย</th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนลูกน้อง</th> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<th scope="col">คะแนน</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col">ประเมินตนเอง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</ng-container>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
...@@ -579,14 +619,20 @@ ...@@ -579,14 +619,20 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * item.scoreTopicExpectation)}} {{numberFixed2(item.weight * item.scoreTopicExpectation)}}
</td> </td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{item.scoreTopicExpectation}}
</td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * {{numberFixed2(item.weight *
(evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}} (evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}}
</td> </td>
</ng-container>
</tr> </tr>
</ng-container> </ng-container>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
...@@ -606,13 +652,19 @@ ...@@ -606,13 +652,19 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScore(appraisalPms?.part3Detail)}} {{calExpectationTotalScore(appraisalPms?.part3Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> </ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class=" py-2"></td>
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBoss(appraisalPms?.part3Detail)}} {{calExpectationTotalScoreBoss(appraisalPms?.part3Detail)}}
</td> </td>
</ng-container>
</tr> </tr>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
<td class="align-start text-start !white-space-normal py-2" colspan="4"> <td class="align-start text-start !white-space-normal py-2" colspan="4">
...@@ -631,7 +683,7 @@ ...@@ -631,7 +683,7 @@
</div> </div>
</td> </td>
<td class=" py-2"></td> <td class=" py-2"></td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'"></td> <td class=" py-2" *ngIf="evaluaterId!=evaluateeId||complete"></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -762,8 +814,13 @@ ...@@ -762,8 +814,13 @@
<th scope="col">น้ำหนัก</th> <th scope="col">น้ำหนัก</th>
<th scope="col">เพิ่มเติม</th> <th scope="col">เพิ่มเติม</th>
<th scope="col" style="width: 300px;">ค่าเป้าหมาย</th> <th scope="col" style="width: 300px;">ค่าเป้าหมาย</th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนลูกน้อง</th> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<th scope="col">คะแนน</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col">ประเมินตนเอง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</ng-container>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
...@@ -855,14 +912,20 @@ ...@@ -855,14 +912,20 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * item.pmsWorkingTimScore)}} {{numberFixed2(item.weight * item.pmsWorkingTimScore)}}
</td> </td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{item.pmsWorkingTimScore}}
</td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * {{numberFixed2(item.weight *
(evaluaterId==evaluateeId?item.pmsWorkingTimScore:item.pmsWorkingTimScoreBoss))}} (evaluaterId==evaluateeId?item.pmsWorkingTimScore:item.pmsWorkingTimScoreBoss))}}
</td> </td>
</ng-container>
</tr> </tr>
</ng-container> </ng-container>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
...@@ -882,13 +945,19 @@ ...@@ -882,13 +945,19 @@
</div> </div>
</div> </div>
</td> </td>
<td *ngIf="evaluaterId!=evaluateeId||currentStep != '0'" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScorePart5(appraisalPms?.part5Detail)}} {{calExpectationTotalScorePart5(appraisalPms?.part5Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> </ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class=" py-2"></td>
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBossPart5(appraisalPms?.part5Detail)}} {{calExpectationTotalScoreBossPart5(appraisalPms?.part5Detail)}}
</td> </td>
</ng-container>
</tr> </tr>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
<td class="align-start text-start !white-space-normal py-2" colspan="4"> <td class="align-start text-start !white-space-normal py-2" colspan="4">
...@@ -906,7 +975,7 @@ ...@@ -906,7 +975,7 @@
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'"></td> <td class=" py-2" *ngIf="evaluaterId!=evaluateeId||complete"></td>
<td class=" py-2"></td> <td class=" py-2"></td>
</tr> </tr>
</tbody> </tbody>
...@@ -933,8 +1002,13 @@ ...@@ -933,8 +1002,13 @@
<th scope="col">น้ำหนัก</th> <th scope="col">น้ำหนัก</th>
<th scope="col">เพิ่มเติม</th> <th scope="col">เพิ่มเติม</th>
<th scope="col" style="width: 300px;">ค่าเป้าหมาย</th> <th scope="col" style="width: 300px;">ค่าเป้าหมาย</th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนลูกน้อง</th> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<th scope="col">คะแนน</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col">ประเมินตนเอง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</ng-container>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
...@@ -1049,14 +1123,20 @@ ...@@ -1049,14 +1123,20 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * item.scoreTopicExpectation)}} {{numberFixed2(item.weight * item.scoreTopicExpectation)}}
</td> </td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{item.scoreTopicExpectation}}
</td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * {{numberFixed2(item.weight *
(evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}} (evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}}
</td> </td>
</ng-container>
</tr> </tr>
</ng-container> </ng-container>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
...@@ -1076,13 +1156,19 @@ ...@@ -1076,13 +1156,19 @@
</div> </div>
</div> </div>
</td> </td>
<td *ngIf="evaluaterId!=evaluateeId||currentStep != '0'" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScore(appraisalPms?.part6Detail)}} {{calExpectationTotalScore(appraisalPms?.part6Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> </ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class=" py-2"></td>
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBoss(appraisalPms?.part6Detail)}} {{calExpectationTotalScoreBoss(appraisalPms?.part6Detail)}}
</td> </td>
</ng-container>
</tr> </tr>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
<td class="align-start text-start !white-space-normal py-2" colspan="4"> <td class="align-start text-start !white-space-normal py-2" colspan="4">
...@@ -1100,7 +1186,7 @@ ...@@ -1100,7 +1186,7 @@
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'"></td> <td class=" py-2" *ngIf="evaluaterId!=evaluateeId||complete"></td>
<td class=" py-2"></td> <td class=" py-2"></td>
</tr> </tr>
</tbody> </tbody>
...@@ -1127,8 +1213,13 @@ ...@@ -1127,8 +1213,13 @@
<th scope="col">น้ำหนัก</th> <th scope="col">น้ำหนัก</th>
<th scope="col">เพิ่มเติม</th> <th scope="col">เพิ่มเติม</th>
<th scope="col" style="width: 300px;">ค่าเป้าหมาย</th> <th scope="col" style="width: 300px;">ค่าเป้าหมาย</th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนลูกน้อง</th> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<th scope="col">คะแนน</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col">ประเมินตนเอง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</ng-container>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
...@@ -1243,14 +1334,20 @@ ...@@ -1243,14 +1334,20 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
*ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * item.scoreTopicExpectation)}} {{numberFixed2(item.weight * item.scoreTopicExpectation)}}
</td> </td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{item.scoreTopicExpectation}}
</td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.weight * {{numberFixed2(item.weight *
(evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}} (evaluaterId==evaluateeId?item.scoreTopicExpectation:item.scoreTopicExpectationBoss))}}
</td> </td>
</ng-container>
</tr> </tr>
</ng-container> </ng-container>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
...@@ -1270,13 +1367,19 @@ ...@@ -1270,13 +1367,19 @@
</div> </div>
</div> </div>
</td> </td>
<td *ngIf="evaluaterId!=evaluateeId||currentStep != '0'" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScore(appraisalPms?.part7Detail)}} {{calExpectationTotalScore(appraisalPms?.part7Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> </ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class=" py-2"></td>
<td
class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBoss(appraisalPms?.part7Detail)}} {{calExpectationTotalScoreBoss(appraisalPms?.part7Detail)}}
</td> </td>
</ng-container>
</tr> </tr>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
<td class="align-start text-start !white-space-normal py-2" colspan="4"> <td class="align-start text-start !white-space-normal py-2" colspan="4">
...@@ -1294,7 +1397,7 @@ ...@@ -1294,7 +1397,7 @@
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'"></td> <td class=" py-2" *ngIf="evaluaterId!=evaluateeId||complete"></td>
<td class=" py-2"></td> <td class=" py-2"></td>
</tr> </tr>
</tbody> </tbody>
...@@ -1319,11 +1422,17 @@ ...@@ -1319,11 +1422,17 @@
<th scope="col">การประเมินผล</th> <th scope="col">การประเมินผล</th>
<th scope="col">คะแนนดิบคิดเป็นร้อยละ</th> <th scope="col">คะแนนดิบคิดเป็นร้อยละ</th>
<th scope="col">ร้อยละของปัจจัย</th> <th scope="col">ร้อยละของปัจจัย</th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'"> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
คะแนนลูกน้องคิดเป็นร้อยละ</th> <th scope="col">คะแนนคิดเป็นร้อยละ</th>
<th scope="col">คะแนนสุทธิ</th>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<th scope="col">ประเมินตนเองคิดเป็นร้อยละ</th>
<th scope="col">คะแนนคิดเป็นร้อยละ</th> <th scope="col">คะแนนคิดเป็นร้อยละ</th>
<th scope="col" *ngIf="evaluaterId!=evaluateeId||currentStep != '0'">คะแนนสุทธิลูกน้อง</th> <th scope="col">คะแนนสุทธิลูกน้อง</th>
<th scope="col">คะแนนสุทธิ</th> <th scope="col">คะแนนสุทธิ</th>
</ng-container>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
...@@ -1340,20 +1449,28 @@ ...@@ -1340,20 +1449,28 @@
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{item.factors}} {{item.factors}}
</td> </td>
<td *ngIf="evaluaterId!=evaluateeId||currentStep != '0'" class="py-2 text-center" <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.scoreObtainedEmp)}}
</td>
<td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.netScoreEmp)}}
</td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.scoreObtainedEmp)}} {{numberFixed2(item.scoreObtainedEmp)}}
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.scoreObtained)}} {{numberFixed2(item.scoreObtained)}}
</td> </td>
<td *ngIf="evaluaterId!=evaluateeId||currentStep != '0'" class="py-2 text-center" <td class="py-2 text-center" style="vertical-align: top">
style="vertical-align: top">
{{numberFixed2(item.netScoreEmp)}} {{numberFixed2(item.netScoreEmp)}}
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"> <td class="py-2 text-center" style="vertical-align: top">
{{numberFixed2(item.netScore)}} {{numberFixed2(item.netScore)}}
</td> </td>
</ng-container>
</tr> </tr>
</ng-container> </ng-container>
<tr class="bg-table-soft-gray" style="height:35px"> <tr class="bg-table-soft-gray" style="height:35px">
...@@ -1365,18 +1482,28 @@ ...@@ -1365,18 +1482,28 @@
<td class="py-2 align-start text-center font-semibold text-indigo-600"> <td class="py-2 align-start text-center font-semibold text-indigo-600">
{{calFactors()}} {{calFactors()}}
</td> </td>
<td *ngIf="evaluaterId!=evaluateeId||currentStep != '0'" class="py-2 align-start text-center font-semibold text-indigo-600"> <ng-container *ngIf="evaluaterId==evaluateeId&&!complete">
<td class="py-2 align-start text-center font-semibold text-indigo-600">
{{calScoreObtainedEmp()}}
</td>
<td class="py-2 align-start text-center font-semibold text-indigo-600">
{{calNetScoreEmp()}}
</td>
</ng-container>
<ng-container *ngIf="evaluaterId!=evaluateeId||complete">
<td class="py-2 align-start text-center font-semibold text-indigo-600">
{{calScoreObtainedEmp()}} {{calScoreObtainedEmp()}}
</td> </td>
<td class="py-2 align-start text-center font-semibold text-indigo-600"> <td class="py-2 align-start text-center font-semibold text-indigo-600">
{{calScoreObtained()}} {{calScoreObtained()}}
</td> </td>
<td *ngIf="evaluaterId!=evaluateeId||currentStep != '0'" class="py-2 align-start text-center font-semibold text-indigo-600"> <td class="py-2 align-start text-center font-semibold text-indigo-600">
{{calNetScoreEmp()}} {{calNetScoreEmp()}}
</td> </td>
<td class="py-2 align-start text-center font-semibold text-indigo-600"> <td class="py-2 align-start text-center font-semibold text-indigo-600">
{{calNetScore()}} {{calNetScore()}}
</td> </td>
</ng-container>
</tr> </tr>
</tbody> </tbody>
</table> </table>
......
...@@ -29,6 +29,7 @@ export interface LevelStarModel { ...@@ -29,6 +29,7 @@ export interface LevelStarModel {
styleUrls: ['./pms-kpi.component.scss'] styleUrls: ['./pms-kpi.component.scss']
}) })
export class PmsKpiComponent { export class PmsKpiComponent {
@Input() complete = false
@Input() canSave = false @Input() canSave = false
@Input() inforWeight: Map<string, string> = new Map<string, string>() @Input() inforWeight: Map<string, string> = new Map<string, string>()
data8List: Part8Model[] = [{ data8List: Part8Model[] = [{
......
...@@ -2,7 +2,7 @@ export interface CompetencyModel { ...@@ -2,7 +2,7 @@ export interface CompetencyModel {
competency: Competency[] competency: Competency[]
idp: Idp idp: Idp
pms: Pms pms: Pms
statusAll: StatusAll statusAll: string
evaluationRoundId: string evaluationRoundId: string
tdesc: string tdesc: string
edesc: string edesc: string
...@@ -3872,9 +3872,3 @@ export interface StatusFrom3 { ...@@ -3872,9 +3872,3 @@ export interface StatusFrom3 {
edesc: string edesc: string
tdesc: string tdesc: string
} }
export interface StatusAll {
additionalProp1: string
additionalProp2: string
additionalProp3: string
}
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