Commit 0e59955b by Nattana Chaiyamat

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

parent 8ff65caf
<app-page-header [pathTitle]="pathTitle"></app-page-header> <ng-container *ngIf="!onEdit">
<div class="bg-card-white"> <app-page-header [pathTitle]="pathTitle"></app-page-header>
</div> <div class="bg-card-white">
<div class="block-main-content"> </div>
<ng-container *ngTemplateOutlet="currentTemplate"></ng-container> <div class="block-main-content">
</div> <ng-container *ngTemplateOutlet="selfEvaluation"></ng-container>
</div>
</ng-container>
<ng-template #selfEvaluation> <ng-template #selfEvaluation>
<div class="font-size-18px font-weight-700 pt-1.5rem text-primary px-2rem"> <div class="font-size-18px font-weight-700 pt-1.5rem text-primary px-2rem">
...@@ -117,10 +119,13 @@ ...@@ -117,10 +119,13 @@
{{masfromEvaluationAssessment1.masfromStatusType.tdesc}} {{masfromEvaluationAssessment1.masfromStatusType.tdesc}}
</td> </td>
<td class="flex justify-center items-center"> <td class="flex justify-center items-center">
<span class="rounded-md bg-success text-white px-3 py-1 cursor-pointer" (click)="selectCompentencyForm(masfromEvaluationAssessment1.competencyType.competencyTypeId);currentTemplate = selfEvaluationEdit ; <button type="button" class="ti-btn rounded-sm " (click)="selectCompentencyForm(masfromEvaluationAssessment1.competencyType.competencyTypeId);onEdit = true ;
pathTitle = ['การประเมินผล', 'ประเมินตนเอง','ประเมินผล']"> pathTitle = ['การประเมินผล', 'ประเมินตนเอง','ประเมินผล']"
[class.ti-btn-soft-secondary]="masfromEvaluationAssessment1.masfromStatusType.code == 'employee'"
[class.ti-btn-soft-warning]="masfromEvaluationAssessment1.masfromStatusType.code != 'employee'&&masfromEvaluationAssessment1.masfromStatusType.code != 'Boss_finish'"
[class.ti-btn-soft-success]="masfromEvaluationAssessment1.masfromStatusType.code == 'Boss_finish'">
ประเมิน ประเมิน
</span> </button>
</td> </td>
</tr> </tr>
</tbody> </tbody>
...@@ -200,10 +205,10 @@ ...@@ -200,10 +205,10 @@
<ng-template #selfEvaluationEdit> <ng-container *ngIf="onEdit">
<app-evaluation [pathTitle]="['การประเมินผล', 'ประเมินตนเอง','ประเมิน']" <app-evaluation [pathTitle]="['การประเมินผล', 'ประเมินตนเอง','ประเมิน']"
(sendReturnPath)="currentTemplate = selfEvaluation ; pathTitle = ['การประเมินผล', 'ประเมินตนเอง']" (sendReturnPath)="onEdit = false ; pathTitle = ['การประเมินผล', 'ประเมินตนเอง']"
[evaluationRoundId]="appraisalCompentency.select?.masfromEvaluationRound?.evaluationRoundId || ''" [evaluationRoundId]="appraisalCompentency.select?.masfromEvaluationRound?.evaluationRoundId || ''"
[evaluaterId]="evaluatee.data.employeeId" [evaluateeId]="evaluatee.data.employeeId" [evaluaterId]="evaluatee.data.employeeId" [evaluateeId]="evaluatee.data.employeeId"
[competencyTypeId]="competencyTypeId"></app-evaluation> [competencyTypeId]="competencyTypeId"></app-evaluation>
</ng-template> </ng-container>
\ No newline at end of file \ No newline at end of file
...@@ -24,20 +24,18 @@ export class SelfEvaluationComponent implements OnInit { ...@@ -24,20 +24,18 @@ export class SelfEvaluationComponent implements OnInit {
score: ["หากได้คะแนน 90 - 100% ถือว่า Gap +1", "หากได้คะแนน 80 - 89% ถือว่า ไม่มี Gap", "หากได้คะแนน 60 - 79% ถือว่า Gap - 1", "หากได้คะแนน 40 - 59% ถือว่า Gap -2", "หากได้คะแนน 0 - 39% ถือว่า Gap - 3"], score: ["หากได้คะแนน 90 - 100% ถือว่า Gap +1", "หากได้คะแนน 80 - 89% ถือว่า ไม่มี Gap", "หากได้คะแนน 60 - 79% ถือว่า Gap - 1", "หากได้คะแนน 40 - 59% ถือว่า Gap -2", "หากได้คะแนน 0 - 39% ถือว่า Gap - 3"],
condition: ["1.หากได้คะแนนสูงกว่า 80% แต่มี 3 2 หรือ 1 ด้วย ถือว่า Gap -1", "2.หากได้คะแนนต่ำกว่า 80% แต่มี 4 และ 5 ให้คิด Gap ตาม %", "3.คะแนนต่ำกว่า 80% แต่มี 2 และ 1 ให้คิด Gap ตาม %"], condition: ["1.หากได้คะแนนสูงกว่า 80% แต่มี 3 2 หรือ 1 ด้วย ถือว่า Gap -1", "2.หากได้คะแนนต่ำกว่า 80% แต่มี 4 และ 5 ให้คิด Gap ตาม %", "3.คะแนนต่ำกว่า 80% แต่มี 2 และ 1 ให้คิด Gap ตาม %"],
}] }]
@ViewChild('selfEvaluation', { static: true }) selfEvaluation!: TemplateRef<any>;
@ViewChild('selfEvaluationEdit', { static: true }) selfEvaluationEdit!: TemplateRef<any>;
currentTemplate: TemplateRef<any> = this.selfEvaluation
appraisalCompentency: { loading: boolean, select?: AppraisalCompentencyModel, dataList: AppraisalCompentencyModel[] } = { loading: false, select: undefined, dataList: [] } appraisalCompentency: { loading: boolean, select?: AppraisalCompentencyModel, dataList: AppraisalCompentencyModel[] } = { loading: false, select: undefined, dataList: [] }
appraisalPms: { loading: boolean, select: undefined, dataList: { check: boolean, data: undefined }[] } = { loading: false, select: undefined, dataList: [] } appraisalPms: { loading: boolean, select: undefined, dataList: { check: boolean, data: undefined }[] } = { loading: false, select: undefined, dataList: [] }
evaluatee: { loading: boolean, data: EmployeeModel } = { loading: false, data: new MyEmployeeModel() } evaluatee: { loading: boolean, data: EmployeeModel } = { loading: false, data: new MyEmployeeModel() }
currentDate = new Date() currentDate = new Date()
competencyTypeId = "" competencyTypeId = ""
onEdit = false
constructor(private appraisalService: AppraisalService, constructor(private appraisalService: AppraisalService,
private employeeService: EmployeeService, private employeeService: EmployeeService,
private cdr: ChangeDetectorRef private cdr: ChangeDetectorRef
) { } ) { }
ngOnInit(): void { ngOnInit(): void {
this.currentTemplate = this.selfEvaluation
this.getEvaluatee() this.getEvaluatee()
this.getAppraisalCompentencyList() this.getAppraisalCompentencyList()
} }
......
...@@ -27,9 +27,8 @@ ...@@ -27,9 +27,8 @@
<div class="px-1"> <div class="px-1">
<div class="relative shadow-md"> <div class="relative shadow-md">
<input type="text" id="hs-leading-icon" name="hs-leading-icon" <input type="text" id="hs-leading-icon" name="hs-leading-icon"
class="ti-form-input ltr:pl-11 rtl:pr-11 focus:z-10 " class="ti-form-input ltr:pl-11 rtl:pr-11 focus:z-10 " placeholder="Search"
placeholder="Search" style="height: 40px;" [(ngModel)]="search" style="height: 40px;" [(ngModel)]="search" (ngModelChange)="searchChange()">
(ngModelChange)="searchChange()">
<div <div
class="absolute inset-y-0 ltr:left-0 rtl:right-0 flex items-center pointer-events-none z-20 ltr:pl-4 rtl:pr-4"> class="absolute inset-y-0 ltr:left-0 rtl:right-0 flex items-center pointer-events-none z-20 ltr:pl-4 rtl:pr-4">
<i class="ri-search-line text-gray"></i> <i class="ri-search-line text-gray"></i>
...@@ -105,8 +104,11 @@ ...@@ -105,8 +104,11 @@
<td style="font-size: 12px;">{{item.apsassessy.position.tdesc}}</td> <td style="font-size: 12px;">{{item.apsassessy.position.tdesc}}</td>
<td class="text-center"> <td class="text-center">
<div class="flex"> <div class="flex">
<button type="button" class="ti-btn rounded-sm ti-btn-soft-success" <button type="button" class="ti-btn rounded-sm "
*ngFor="let type of item.typeList" *ngFor="let type of item.typeList"
[class.ti-btn-soft-secondary]="type.statusType == 'employee'"
[class.ti-btn-soft-warning]="type.statusType != 'employee'&&type.statusType != 'Boss_finish'"
[class.ti-btn-soft-success]="type.statusType == 'Boss_finish'"
style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;" style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;"
(click)="selectSubordinate(item,type.competencyTypeId,subordinate.select?.evaluationRoundId);pageEvalution='evaluation'"> (click)="selectSubordinate(item,type.competencyTypeId,subordinate.select?.evaluationRoundId);pageEvalution='evaluation'">
{{type.shortName}} {{type.shortName}}
...@@ -114,16 +116,16 @@ ...@@ -114,16 +116,16 @@
</div> </div>
</td> </td>
<td class="text-center"> <td class="text-center">
<button type="button" class="ti-btn rounded-sm ti-btn-soft-dark" <!-- <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;"> style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;">
IDP IDP
</button> </button> -->
</td> </td>
<td class="text-center"> <td class="text-center">
<button type="button" class="ti-btn rounded-sm ti-btn-soft-success" <!-- <button type="button" class="ti-btn rounded-sm ti-btn-soft-success"
style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;"> style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;">
ประเมิน ประเมิน
</button> </button> -->
</td> </td>
<td class="text-center" style="font-size: 12px;">{{item.sumScore}}</td> <td class="text-center" style="font-size: 12px;">{{item.sumScore}}</td>
<td class="text-center" style="font-size: 12px;">{{item.gread}}</td> <td class="text-center" style="font-size: 12px;">{{item.gread}}</td>
......
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