Commit 99625429 by Nattana Chaiyamat

ประเมินโดยหัวหน้า

parent 1e7036b4
...@@ -95,7 +95,7 @@ const routes: Routes = [ ...@@ -95,7 +95,7 @@ const routes: Routes = [
{ path: "self-evaluation", title: 'ประเมินตนเอง', component: SelfEvaluationComponent }, { path: "self-evaluation", title: 'ประเมินตนเอง', component: SelfEvaluationComponent },
{ path: "day-type-registry", title: 'ประเมินตนเอง', component: DayTypeRegistryComponent }, { path: "day-type-registry", title: 'ประเมินตนเอง', component: DayTypeRegistryComponent },
{ path: "time-attendance", title: 'ทะเบียนการประเมินเวลาทำงาน', component: TimeAttendanceComponent }, { path: "time-attendance", title: 'ทะเบียนการประเมินเวลาทำงาน', component: TimeAttendanceComponent },
{ path: "role-permission-config", title: 'กำหนดสิทธิการเข้าใช้งาน', component: RolePermissionConfigComponent }, { path: "role-permission-config", title: 'กำหนดสิทธิการเข้าใช้งาน', component: RolePermissionConfigComponent }
] ]
} }
]; ];
......
...@@ -45,18 +45,18 @@ ...@@ -45,18 +45,18 @@
</div> </div>
</div> </div>
<div class="text-white"> <div class="text-white">
<h2 class="text-base font-semibold">Anderson Itumay</h2> <h2 class="text-base font-semibold">{{evaluatee.data.thFullName}}</h2>
<p class="text-xs text-white/50">{{'andersonitumay@abc.com'}}</p> <p class="text-xs text-white/50">{{evaluatee.data.email}}</p>
</div> </div>
<div class="flex space-x-2 rtl:space-x-reverse text-center justify-center"> <div class="flex space-x-2 rtl:space-x-reverse text-center justify-center">
<div id="stars-hover"> <div id="stars-hover">
<div class="cont"> <div class="cont">
<div class="stars"> <div class="stars">
<bar-rating [(rate)]="starRate" [max]="5" [theme]="'stars'"></bar-rating> <!-- <bar-rating [(rate)]="starRate" [max]="5" [theme]="'stars'"></bar-rating>
<button type="button" aria-label="button" <button type="button" aria-label="button"
class="ti-btn ti-btn-soft-success py-1 px-2 ltr:!ml-3 rtl:!mr-3 mt-1 " id="rater-reset-button"> class="ti-btn ti-btn-soft-success py-1 px-2 ltr:!ml-3 rtl:!mr-3 mt-1 " id="rater-reset-button">
<i>Grade: A</i> <i>Grade: A</i>
</button> </button> -->
</div> </div>
</div> </div>
</div> </div>
...@@ -80,34 +80,34 @@ ...@@ -80,34 +80,34 @@
<table class="ti-custom-table border-0"> <table class="ti-custom-table border-0">
<tbody> <tbody>
<tr class=""> <tr class="">
<td class="font-medium !p-2">Designation</td> <td class="font-medium !p-2">ตำเเหน่ง</td>
<td class="!p-2">:</td> <td class="!p-2">:</td>
<td class="!p-2">Sr.Ui Developer</td> <td class="!p-2">{{evaluatee.data.position.tdesc}}</td>
</tr> </tr>
<tr class="!border-0"> <tr class="!border-0">
<td class="font-medium !p-2">Joined</td> <td class="font-medium !p-2">ฝ่าย</td>
<td class="!p-2">:</td> <td class="!p-2">:</td>
<td class="!p-2">01 November 2019</td> <td class="!p-2">{{evaluatee.data.bu1.tdesc}}</td>
</tr> </tr>
<tr class="!border-0"> <tr class="!border-0">
<td class="font-medium !p-2">Age</td> <td class="font-medium !p-2">แผนก</td>
<td class="!p-2">:</td> <td class="!p-2">:</td>
<td class="!p-2">26</td> <td class="!p-2">{{evaluatee.data.bu2.tdesc}}</td>
</tr> </tr>
<tr class="!border-0"> <tr class="!border-0">
<td class="font-medium !p-2">City</td> <td class="font-medium !p-2">ส่วน</td>
<td class="!p-2">:</td> <td class="!p-2">:</td>
<td class="!p-2">Lake Park</td> <td class="!p-2">{{evaluatee.data.bu3.tdesc}}</td>
</tr> </tr>
<tr class="!border-0"> <tr class="!border-0">
<td class="font-medium !p-2">Country</td> <td class="font-medium !p-2">ส่วนย่อย 1</td>
<td class="!p-2">:</td> <td class="!p-2">:</td>
<td class="!p-2">Newyork</td> <td class="!p-2">{{evaluatee.data.bu4.tdesc}}</td>
</tr> </tr>
<tr class="!border-0"> <tr class="!border-0">
<td class="font-medium !p-2">State</td> <td class="font-medium !p-2">ส่วนย่อย 2</td>
<td class="!p-2">:</td> <td class="!p-2">:</td>
<td class="!p-2">U.S.A</td> <td class="!p-2">{{evaluatee.data.bu1.tdesc}}</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -299,19 +299,25 @@ ...@@ -299,19 +299,25 @@
</div> </div>
<div id="profile-2" [class.hidden]="currentTap=='idp'||currentTap=='pms'||currentTap==''" role="tabpanel" <div id="profile-2" [class.hidden]="currentTap=='idp'||currentTap=='pms'||currentTap==''" role="tabpanel"
aria-labelledby="profile-item-2"> aria-labelledby="profile-item-2">
<ng-container *ngIf="evaluationRoundId&&allCompetencyTypeId&&evaluaterId&&evaluateeId">
<app-pms-competency [currentTap]="currentTap" [evaluationRoundId]="evaluationRoundId" <app-pms-competency [currentTap]="currentTap" [evaluationRoundId]="evaluationRoundId"
[evaluaterId]="evaluaterId" [evaluateeId]="evaluateeId" [evaluaterId]="evaluaterId" [evaluateeId]="evaluateeId"
[allCompetencyTypeId]="allCompetencyTypeId"></app-pms-competency> [allCompetencyTypeId]="allCompetencyTypeId"></app-pms-competency>
</ng-container>
</div> </div>
<div id="profile-3" [class.hidden]="currentTap!='pms'" class="text-center" role="tabpanel" <div id="profile-3" [class.hidden]="currentTap!='pms'" class="text-center" role="tabpanel"
aria-labelledby="profile-item-3"> aria-labelledby="profile-item-3">
<ng-container *ngIf="evaluationRoundId&&evaluateeId&&evaluaterId">
<app-pms-kpi [evaluationRoundId]="evaluationRoundId" [evaluaterId]="evaluaterId" <app-pms-kpi [evaluationRoundId]="evaluationRoundId" [evaluaterId]="evaluaterId"
[evaluateeId]="evaluateeId"></app-pms-kpi> [evaluateeId]="evaluateeId"></app-pms-kpi>
</ng-container>
</div> </div>
<div id="profile-4" [class.hidden]="currentTap!='idp'" class="text-center" role="tabpanel" <div id="profile-4" [class.hidden]="currentTap!='idp'" class="text-center" role="tabpanel"
aria-labelledby="profile-item-4"> aria-labelledby="profile-item-4">
<ng-container *ngIf="evaluationRoundId&&evaluateeId&&evaluaterId">
<app-pms-idp [evaluationRoundId]="evaluationRoundId" [evaluaterId]="evaluaterId" <app-pms-idp [evaluationRoundId]="evaluationRoundId" [evaluaterId]="evaluaterId"
[evaluateeId]="evaluateeId"></app-pms-idp> [evaluateeId]="evaluateeId"></app-pms-idp>
</ng-container>
</div> </div>
<div id="profile-5" [class.hidden]="currentTap!='2'" class="text-center" role="tabpanel" <div id="profile-5" [class.hidden]="currentTap!='2'" class="text-center" role="tabpanel"
aria-labelledby="profile-item-5"> aria-labelledby="profile-item-5">
......
import { Component, EventEmitter, Input, Output } from '@angular/core'; import { ChangeDetectorRef, Component, EventEmitter, Input, Output } from '@angular/core';
import { Router } from '@angular/router';
import { TypeList } from 'src/app/shared/model/appraisal-subordinate.model'; import { TypeList } from 'src/app/shared/model/appraisal-subordinate.model';
import { EmployeeModel, MyEmployeeModel } from 'src/app/shared/model/employee.model';
import { EmployeeService } from 'src/app/shared/services/employee.service';
@Component({ @Component({
selector: 'app-pms-form-employee', selector: 'app-pms-form-employee',
...@@ -13,11 +16,54 @@ export class PmsFormEmployeeComponent { ...@@ -13,11 +16,54 @@ export class PmsFormEmployeeComponent {
@Input() evaluateeId = "" @Input() evaluateeId = ""
@Input() evaluaterId = "" @Input() evaluaterId = ""
@Input() evaluationForm: 'self' | 'sup' = "self" @Input() evaluationForm: 'self' | 'sup' = "self"
evaluatee: { loading: boolean, data: EmployeeModel } = { loading: false, data: new MyEmployeeModel() }
@Output() sendReturnPath: EventEmitter<any> = new EventEmitter<any>(); @Output() sendReturnPath: EventEmitter<any> = new EventEmitter<any>();
starRate = 5; starRate = 5;
url1 = ''; url1 = '';
url2 = '';
selectedItems = [];
dropdownSettings = {};
datePickerConfig = {
format: 'DD-MM-YY',
};
dropdownList = [
{ id: '1', itemName: 'Laravel' },
{ id: '2', itemName: 'Angular' },
{ id: '3', itemName: 'HTML' },
{ id: '4', itemName: 'React' },
{ id: '5', itemName: 'Bootstrap' },
];
constructor(
private router: Router,
private employeeService: EmployeeService,
private cdr: ChangeDetectorRef
) { }
ngOnInit() {
this.getEvaluatee()
}
getEvaluatee() {
this.evaluatee.loading = true
this.employeeService.getWorkingById(this.evaluateeId).subscribe({
next: response => {
this.evaluatee.data = new MyEmployeeModel(response)
this.evaluatee.loading = false
this.cdr.detectChanges()
}, error: error => {
this.evaluatee.loading = false
this.cdr.detectChanges()
}
})
}
currentTapChange() { currentTapChange() {
if (this.allCompetencyTypeId.length) { if (this.allCompetencyTypeId.length) {
this.currentTap = this.allCompetencyTypeId[0].shortName || '' this.currentTap = this.allCompetencyTypeId[0].shortName || ''
...@@ -36,7 +82,6 @@ export class PmsFormEmployeeComponent { ...@@ -36,7 +82,6 @@ export class PmsFormEmployeeComponent {
} }
} }
url2 = '';
onSelectFile2(event: any) { onSelectFile2(event: any) {
if (event.target && event.target.files && event.target.files[0]) { if (event.target && event.target.files && event.target.files[0]) {
const reader = new FileReader(); const reader = new FileReader();
...@@ -49,19 +94,6 @@ export class PmsFormEmployeeComponent { ...@@ -49,19 +94,6 @@ export class PmsFormEmployeeComponent {
}; };
} }
} }
selectedItems = [];
dropdownSettings = {};
datePickerConfig = {
format: 'DD-MM-YY',
};
dropdownList = [
{ id: '1', itemName: 'Laravel' },
{ id: '2', itemName: 'Angular' },
{ id: '3', itemName: 'HTML' },
{ id: '4', itemName: 'React' },
{ id: '5', itemName: 'Bootstrap' },
];
updateFormat() { updateFormat() {
this.datePickerConfig = { this.datePickerConfig = {
...@@ -69,7 +101,6 @@ export class PmsFormEmployeeComponent { ...@@ -69,7 +101,6 @@ export class PmsFormEmployeeComponent {
format: 'DD-MM-YY', format: 'DD-MM-YY',
}; };
} }
ngOnInit() { }
returnPath() { returnPath() {
this.sendReturnPath.emit() this.sendReturnPath.emit()
......
...@@ -8,10 +8,12 @@ ...@@ -8,10 +8,12 @@
</div> --> </div> -->
</ng-container> </ng-container>
<ng-template #newSelfEvaluation> <ng-template #newSelfEvaluation>
<app-pms-form-employee *ngIf="appraisalCompentency.select&&allCompetencyTypeId.length" [evaluationForm]="'self'" <ng-container *ngIf="appraisalCompentency.select&&allCompetencyTypeId.length">
<app-pms-form-employee [evaluationForm]="'self'"
[evaluationRoundId]="appraisalCompentency.select.masfromEvaluationRound.evaluationRoundId" [evaluationRoundId]="appraisalCompentency.select.masfromEvaluationRound.evaluationRoundId"
[evaluaterId]="evaluatee.data.employeeId" [allCompetencyTypeId]="allCompetencyTypeId" [evaluaterId]="evaluatee.data.employeeId" [allCompetencyTypeId]="allCompetencyTypeId"
[evaluateeId]="evaluatee.data.employeeId"></app-pms-form-employee> [evaluateeId]="evaluatee.data.employeeId"></app-pms-form-employee>
</ng-container>
</ng-template> </ng-template>
<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">
......
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