Commit e251e6f8 by Nattana Chaiyamat

คะแนนลูกน้อง

parent 2b8f3a2d
...@@ -54,6 +54,8 @@ import { ReportPms2Component } from '../report-component/report-pms/report-pms-2 ...@@ -54,6 +54,8 @@ import { ReportPms2Component } from '../report-component/report-pms/report-pms-2
import { ReportPms3Component } from '../report-component/report-pms/report-pms-3/report-pms-3.component'; import { ReportPms3Component } from '../report-component/report-pms/report-pms-3/report-pms-3.component';
import { EssProfileComponent } from '../ess-profile/ess-profile.component'; import { EssProfileComponent } from '../ess-profile/ess-profile.component';
import { ExcelReportComponent } from '../excel-report/excel-report.component'; import { ExcelReportComponent } from '../excel-report/excel-report.component';
import { SettingIndividualKpiComponent } from '../setting-individual-kpi/setting-individual-kpi.component';
import { SettingIndividualKpiSupervisorComponent } from '../setting-individual-kpi-supervisor/setting-individual-kpi-supervisor.component';
...@@ -119,7 +121,10 @@ const routes: Routes = [ ...@@ -119,7 +121,10 @@ const routes: Routes = [
{ path: "admin/report-pms-1", title: 'report-pms-1', component: ReportPms1Component }, { path: "admin/report-pms-1", title: 'report-pms-1', component: ReportPms1Component },
{ path: "admin/report-pms-2", title: 'report-pms-2', component: ReportPms2Component }, { path: "admin/report-pms-2", title: 'report-pms-2', component: ReportPms2Component },
{ path: "admin/report-pms-3", title: 'report-pms-3', component: ReportPms3Component }, { path: "admin/report-pms-3", title: 'report-pms-3', component: ReportPms3Component },
{ path: "admin/excel-export/:id", title: 'รายงาน Excel', component: ExcelReportComponent } { path: "admin/excel-export/:id", title: 'รายงาน Excel', component: ExcelReportComponent },
{ path: "ess/self-setting-individual-kpi", title: 'แก้ไข Individual KPI ตนเอง', component: SettingIndividualKpiComponent },
{ path: "ess/supervisor-setting-individual-kpi", title: 'แก้ไข Individual KPI โดยหัวหน้า', component: SettingIndividualKpiSupervisorComponent },
] ]
} }
]; ];
......
...@@ -204,6 +204,8 @@ import { ...@@ -204,6 +204,8 @@ import {
PageService, PageService,
FilterService, FilterService,
} from '@syncfusion/ej2-angular-grids'; } from '@syncfusion/ej2-angular-grids';
import { SettingIndividualKpiComponent } from '../setting-individual-kpi/setting-individual-kpi.component';
import { SettingIndividualKpiSupervisorComponent } from '../setting-individual-kpi-supervisor/setting-individual-kpi-supervisor.component';
export const MY_DATE_FORMATS = { export const MY_DATE_FORMATS = {
parse: { parse: {
...@@ -349,7 +351,9 @@ export class CustomDateAdapter extends NativeDateAdapter { ...@@ -349,7 +351,9 @@ export class CustomDateAdapter extends NativeDateAdapter {
ReportPms3Component, ReportPms3Component,
EssProfileComponent, EssProfileComponent,
ExcelReportComponent, ExcelReportComponent,
PivotSyncfutionComponent PivotSyncfutionComponent,
SettingIndividualKpiComponent,
SettingIndividualKpiSupervisorComponent
], ],
imports: [ imports: [
CommonModule, CommonModule,
......
...@@ -75,6 +75,7 @@ ...@@ -75,6 +75,7 @@
<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">คะแนนลูกน้อง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</tr> </tr>
</thead> </thead>
...@@ -190,6 +191,10 @@ ...@@ -190,6 +191,10 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"
*ngIf="evaluaterId!=evaluateeId">
{{numberFixed2(item.weight * 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))}}
...@@ -213,9 +218,13 @@ ...@@ -213,9 +218,13 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> <td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"
*ngIf="evaluaterId!=evaluateeId">
{{calExpectationTotalScore(appraisalPms?.part1Detail)}} {{calExpectationTotalScore(appraisalPms?.part1Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBoss(appraisalPms?.part1Detail)}}
</td>
</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">
...@@ -229,11 +238,12 @@ ...@@ -229,11 +238,12 @@
</div> </div>
<div class="flex-1 font-semibold"> <div class="flex-1 font-semibold">
คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span
class="text-indigo-600 ">{{calPercentage(calExpectationTotalScore(appraisalPms?.part1Detail),calRawScore(appraisalPms?.part1Detail))}}</span> class="text-indigo-600 ">{{calPercentage(calExpectationTotalScoreBoss(appraisalPms?.part1Detail),calRawScore(appraisalPms?.part1Detail))}}</span>
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2"></td> <td class=" py-2"></td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId"></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -259,6 +269,7 @@ ...@@ -259,6 +269,7 @@
<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">คะแนนลูกน้อง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</tr> </tr>
</thead> </thead>
...@@ -374,6 +385,10 @@ ...@@ -374,6 +385,10 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"
*ngIf="evaluaterId!=evaluateeId">
{{numberFixed2(item.weight * 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))}}
...@@ -397,9 +412,13 @@ ...@@ -397,9 +412,13 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> <td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"
*ngIf="evaluaterId!=evaluateeId">
{{calExpectationTotalScore(appraisalPms?.part2Detail)}} {{calExpectationTotalScore(appraisalPms?.part2Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBoss(appraisalPms?.part2Detail)}}
</td>
</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">
...@@ -413,11 +432,12 @@ ...@@ -413,11 +432,12 @@
</div> </div>
<div class="flex-1 font-semibold"> <div class="flex-1 font-semibold">
คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span
class="text-indigo-600 ">{{calPercentage(calExpectationTotalScore(appraisalPms?.part2Detail),calRawScore(appraisalPms?.part2Detail))}}</span> class="text-indigo-600 ">{{calPercentage(calExpectationTotalScoreBoss(appraisalPms?.part2Detail),calRawScore(appraisalPms?.part2Detail))}}</span>
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2"></td> <td class=" py-2"></td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId"></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -443,6 +463,7 @@ ...@@ -443,6 +463,7 @@
<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">คะแนนลูกน้อง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</tr> </tr>
</thead> </thead>
...@@ -558,6 +579,10 @@ ...@@ -558,6 +579,10 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"
*ngIf="evaluaterId!=evaluateeId">
{{numberFixed2(item.weight * 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))}}
...@@ -581,9 +606,13 @@ ...@@ -581,9 +606,13 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> <td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"
*ngIf="evaluaterId!=evaluateeId">
{{calExpectationTotalScore(appraisalPms?.part3Detail)}} {{calExpectationTotalScore(appraisalPms?.part3Detail)}}
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScoreBoss(appraisalPms?.part3Detail)}}
</td>
</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">
...@@ -597,11 +626,12 @@ ...@@ -597,11 +626,12 @@
</div> </div>
<div class="flex-1 font-semibold"> <div class="flex-1 font-semibold">
คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span
class="text-indigo-600 ">{{calPercentage(calExpectationTotalScore(appraisalPms?.part3Detail),calRawScore(appraisalPms?.part3Detail))}}</span> class="text-indigo-600 ">{{calPercentage(calExpectationTotalScoreBoss(appraisalPms?.part3Detail),calRawScore(appraisalPms?.part3Detail))}}</span>
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2"></td> <td class=" py-2"></td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId"></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -687,7 +717,7 @@ ...@@ -687,7 +717,7 @@
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> <td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600">
{{calExpectationTotalScorePart4(appraisalPms?.part4Detail)}} {{calExpectationTotalScoreBossPart4(appraisalPms?.part4Detail)}}
</td> </td>
</tr> </tr>
<tr class="bg-table-soft-gray"> <tr class="bg-table-soft-gray">
...@@ -702,7 +732,7 @@ ...@@ -702,7 +732,7 @@
</div> </div>
<div class="flex-1 font-semibold"> <div class="flex-1 font-semibold">
คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span
class="text-indigo-600 ">{{calPercentage(calExpectationTotalScorePart4(appraisalPms?.part4Detail),calRawScorePart4(appraisalPms?.part4Detail))}}</span> class="text-indigo-600 ">{{calPercentage(calExpectationTotalScoreBossPart4(appraisalPms?.part4Detail),calRawScorePart4(appraisalPms?.part4Detail))}}</span>
</div> </div>
</div> </div>
</td> </td>
...@@ -732,6 +762,7 @@ ...@@ -732,6 +762,7 @@
<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">คะแนนลูกน้อง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</tr> </tr>
</thead> </thead>
...@@ -824,6 +855,10 @@ ...@@ -824,6 +855,10 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"
*ngIf="evaluaterId!=evaluateeId">
{{numberFixed2(item.weight * 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))}}
...@@ -847,9 +882,13 @@ ...@@ -847,9 +882,13 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> <td *ngIf="evaluaterId!=evaluateeId"
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">
{{calExpectationTotalScoreBossPart5(appraisalPms?.part5Detail)}}
</td>
</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">
...@@ -863,10 +902,11 @@ ...@@ -863,10 +902,11 @@
</div> </div>
<div class="flex-1 font-semibold"> <div class="flex-1 font-semibold">
คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span
class="text-indigo-600 ">{{calPercentage(calExpectationTotalScorePart5(appraisalPms?.part5Detail),calRawScorePart5(appraisalPms?.part5Detail))}}</span> class="text-indigo-600 ">{{calPercentage(calExpectationTotalScoreBossPart5(appraisalPms?.part5Detail),calRawScorePart5(appraisalPms?.part5Detail))}}</span>
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId"></td>
<td class=" py-2"></td> <td class=" py-2"></td>
</tr> </tr>
</tbody> </tbody>
...@@ -893,6 +933,7 @@ ...@@ -893,6 +933,7 @@
<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">คะแนนลูกน้อง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</tr> </tr>
</thead> </thead>
...@@ -1008,6 +1049,10 @@ ...@@ -1008,6 +1049,10 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"
*ngIf="evaluaterId!=evaluateeId">
{{numberFixed2(item.weight * 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))}}
...@@ -1031,9 +1076,13 @@ ...@@ -1031,9 +1076,13 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> <td *ngIf="evaluaterId!=evaluateeId"
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">
{{calExpectationTotalScoreBoss(appraisalPms?.part6Detail)}}
</td>
</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">
...@@ -1047,10 +1096,11 @@ ...@@ -1047,10 +1096,11 @@
</div> </div>
<div class="flex-1 font-semibold"> <div class="flex-1 font-semibold">
คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span
class="text-indigo-600 ">{{calPercentage(calExpectationTotalScore(appraisalPms?.part6Detail),calRawScore(appraisalPms?.part6Detail))}}</span> class="text-indigo-600 ">{{calPercentage(calExpectationTotalScoreBoss(appraisalPms?.part6Detail),calRawScore(appraisalPms?.part6Detail))}}</span>
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId"></td>
<td class=" py-2"></td> <td class=" py-2"></td>
</tr> </tr>
</tbody> </tbody>
...@@ -1077,6 +1127,7 @@ ...@@ -1077,6 +1127,7 @@
<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">คะแนนลูกน้อง</th>
<th scope="col">คะแนน</th> <th scope="col">คะแนน</th>
</tr> </tr>
</thead> </thead>
...@@ -1192,6 +1243,10 @@ ...@@ -1192,6 +1243,10 @@
</span> </span>
</div> </div>
</td> </td>
<td class="py-2 text-center" style="vertical-align: top"
*ngIf="evaluaterId!=evaluateeId">
{{numberFixed2(item.weight * 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))}}
...@@ -1215,9 +1270,13 @@ ...@@ -1215,9 +1270,13 @@
</div> </div>
</div> </div>
</td> </td>
<td class="align-start !white-space-normal text-center py-2 font-semibold text-indigo-600"> <td *ngIf="evaluaterId!=evaluateeId"
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">
{{calExpectationTotalScoreBoss(appraisalPms?.part7Detail)}}
</td>
</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">
...@@ -1231,10 +1290,11 @@ ...@@ -1231,10 +1290,11 @@
</div> </div>
<div class="flex-1 font-semibold"> <div class="flex-1 font-semibold">
คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span คะแนนที่ได้คิดเป็นร้อยละ&nbsp;:&nbsp;<span
class="text-indigo-600 ">{{calPercentage(calExpectationTotalScore(appraisalPms?.part7Detail),calRawScore(appraisalPms?.part7Detail))}}</span> class="text-indigo-600 ">{{calPercentage(calExpectationTotalScoreBoss(appraisalPms?.part7Detail),calRawScore(appraisalPms?.part7Detail))}}</span>
</div> </div>
</div> </div>
</td> </td>
<td class=" py-2" *ngIf="evaluaterId!=evaluateeId"></td>
<td class=" py-2"></td> <td class=" py-2"></td>
</tr> </tr>
</tbody> </tbody>
......
...@@ -252,6 +252,12 @@ export class PmsKpiComponent { ...@@ -252,6 +252,12 @@ export class PmsKpiComponent {
} }
calExpectationTotalScore(data?: any) { calExpectationTotalScore(data?: any) {
if (data) { if (data) {
return data.reduce((sum: number, item: any) => sum + (item.scoreTopicExpectation * item.weight), 0).toFixed(2);
}
return "0.00"
}
calExpectationTotalScoreBoss(data?: any) {
if (data) {
return data.reduce((sum: number, item: any) => sum + (item.scoreTopicExpectationBoss * item.weight), 0).toFixed(2); return data.reduce((sum: number, item: any) => sum + (item.scoreTopicExpectationBoss * item.weight), 0).toFixed(2);
} }
return "0.00" return "0.00"
...@@ -265,37 +271,37 @@ export class PmsKpiComponent { ...@@ -265,37 +271,37 @@ export class PmsKpiComponent {
changePercentage() { changePercentage() {
this.data8List.forEach(x => { this.data8List.forEach(x => {
if (x.id == 1 && this.appraisalPms?.part1Detail) { if (x.id == 1 && this.appraisalPms?.part1Detail) {
x.scoreObtained = +this.calPercentage(this.calExpectationTotalScore(this.appraisalPms?.part1Detail), this.calRawScore(this.appraisalPms?.part1Detail)) x.scoreObtained = +this.calPercentage(this.calExpectationTotalScoreBoss(this.appraisalPms?.part1Detail), this.calRawScore(this.appraisalPms?.part1Detail))
if (this.appraisalPms) { if (this.appraisalPms) {
this.appraisalPms.part1SumScore = x.scoreObtained this.appraisalPms.part1SumScore = x.scoreObtained
} }
} else if (x.id == 2 && this.appraisalPms?.part2Detail) { } else if (x.id == 2 && this.appraisalPms?.part2Detail) {
x.scoreObtained = +this.calPercentage(this.calExpectationTotalScore(this.appraisalPms?.part2Detail), this.calRawScore(this.appraisalPms?.part2Detail)) x.scoreObtained = +this.calPercentage(this.calExpectationTotalScoreBoss(this.appraisalPms?.part2Detail), this.calRawScore(this.appraisalPms?.part2Detail))
if (this.appraisalPms) { if (this.appraisalPms) {
this.appraisalPms.part2SumScore = x.scoreObtained this.appraisalPms.part2SumScore = x.scoreObtained
} }
} else if (x.id == 3 && this.appraisalPms?.part3Detail) { } else if (x.id == 3 && this.appraisalPms?.part3Detail) {
x.scoreObtained = +this.calPercentage(this.calExpectationTotalScore(this.appraisalPms?.part3Detail), this.calRawScore(this.appraisalPms?.part3Detail)) x.scoreObtained = +this.calPercentage(this.calExpectationTotalScoreBoss(this.appraisalPms?.part3Detail), this.calRawScore(this.appraisalPms?.part3Detail))
if (this.appraisalPms) { if (this.appraisalPms) {
this.appraisalPms.part3SumScore = x.scoreObtained this.appraisalPms.part3SumScore = x.scoreObtained
} }
} else if (x.id == 4 && this.appraisalPms?.part4Detail) { } else if (x.id == 4 && this.appraisalPms?.part4Detail) {
x.scoreObtained = +this.calPercentage(this.calExpectationTotalScorePart4(this.appraisalPms?.part4Detail), this.calRawScorePart4(this.appraisalPms?.part4Detail)) x.scoreObtained = +this.calPercentage(this.calExpectationTotalScoreBossPart4(this.appraisalPms?.part4Detail), this.calRawScorePart4(this.appraisalPms?.part4Detail))
if (this.appraisalPms) { if (this.appraisalPms) {
this.appraisalPms.part4SumScore = x.scoreObtained this.appraisalPms.part4SumScore = x.scoreObtained
} }
} else if (x.id == 5 && this.appraisalPms?.part5Detail) { } else if (x.id == 5 && this.appraisalPms?.part5Detail) {
x.scoreObtained = +this.calPercentage(this.calExpectationTotalScorePart5(this.appraisalPms?.part5Detail), this.calRawScorePart5(this.appraisalPms?.part5Detail)) x.scoreObtained = +this.calPercentage(this.calExpectationTotalScoreBossPart5(this.appraisalPms?.part5Detail), this.calRawScorePart5(this.appraisalPms?.part5Detail))
if (this.appraisalPms) { if (this.appraisalPms) {
this.appraisalPms.part5SumScore = x.scoreObtained this.appraisalPms.part5SumScore = x.scoreObtained
} }
} else if (x.id == 6 && this.appraisalPms?.part6Detail) { } else if (x.id == 6 && this.appraisalPms?.part6Detail) {
x.scoreObtained = +this.calPercentage(this.calExpectationTotalScore(this.appraisalPms?.part6Detail), this.calRawScore(this.appraisalPms?.part6Detail)) x.scoreObtained = +this.calPercentage(this.calExpectationTotalScoreBoss(this.appraisalPms?.part6Detail), this.calRawScore(this.appraisalPms?.part6Detail))
if (this.appraisalPms) { if (this.appraisalPms) {
this.appraisalPms.part6SumScore = x.scoreObtained this.appraisalPms.part6SumScore = x.scoreObtained
} }
} else if (x.id == 7 && this.appraisalPms?.part7Detail) { } else if (x.id == 7 && this.appraisalPms?.part7Detail) {
x.scoreObtained = +this.calPercentage(this.calExpectationTotalScore(this.appraisalPms?.part7Detail), this.calRawScore(this.appraisalPms?.part7Detail)) x.scoreObtained = +this.calPercentage(this.calExpectationTotalScoreBoss(this.appraisalPms?.part7Detail), this.calRawScore(this.appraisalPms?.part7Detail))
if (this.appraisalPms) { if (this.appraisalPms) {
this.appraisalPms.part7SumScore = x.scoreObtained this.appraisalPms.part7SumScore = x.scoreObtained
} }
...@@ -363,7 +369,7 @@ export class PmsKpiComponent { ...@@ -363,7 +369,7 @@ export class PmsKpiComponent {
} }
return "0.00" return "0.00"
} }
calExpectationTotalScorePart4(data?: any) { calExpectationTotalScoreBossPart4(data?: any) {
if (data) { if (data) {
return data.reduce((sum: number, item: any) => sum + (item.competencyType.weight * this.calAverage(this.convertToNumber(this.inforWeight.get(item.competencyType.shortName) return data.reduce((sum: number, item: any) => sum + (item.competencyType.weight * this.calAverage(this.convertToNumber(this.inforWeight.get(item.competencyType.shortName)
!== 'null' ? this.inforWeight.get(item.competencyType.shortName) : '0'))), 0).toFixed(2); !== 'null' ? this.inforWeight.get(item.competencyType.shortName) : '0'))), 0).toFixed(2);
...@@ -392,6 +398,12 @@ export class PmsKpiComponent { ...@@ -392,6 +398,12 @@ export class PmsKpiComponent {
} }
calExpectationTotalScorePart5(data?: any) { calExpectationTotalScorePart5(data?: any) {
if (data) { if (data) {
return data.reduce((sum: number, item: any) => sum + (item.pmsWorkingTimScore * item.weight), 0).toFixed(2);
}
return "0.00"
}
calExpectationTotalScoreBossPart5(data?: any) {
if (data) {
return data.reduce((sum: number, item: any) => sum + (item.pmsWorkingTimScoreBoss * item.weight), 0).toFixed(2); return data.reduce((sum: number, item: any) => sum + (item.pmsWorkingTimScoreBoss * item.weight), 0).toFixed(2);
} }
return "0.00" return "0.00"
......
...@@ -187,13 +187,13 @@ ...@@ -187,13 +187,13 @@
<thead> <thead>
<tr> <tr>
<ng-container <ng-container
*ngFor="let item of subordinate.select?.showPms?['','รหัสพนักงาน','ชื่อพนักงาน','ตำเเหน่งงาน','ประเมิน','ผลประเมิน','เกรด' ,'สถานะผู้ประเมิน']: *ngFor="let item of subordinate.select?.showPms?['รหัสพนักงาน','ชื่อพนักงาน','ตำเเหน่งงาน','ประเมิน','ผลประเมิน','เกรด' ,'สถานะผู้ประเมิน']:
['','รหัสพนักงาน','ชื่อพนักงาน','ตำเเหน่งงาน','ประเมิน','เเผนพัฒนา','สถานะผู้ประเมิน']; let f = first; let l = last; let i = index"> ['รหัสพนักงาน','ชื่อพนักงาน','ตำเเหน่งงาน','ประเมิน','เเผนพัฒนา','สถานะผู้ประเมิน']; let f = first; let l = last; let i = index">
<th scope="col" <th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center" class="relative px-10px py-10px bg-soft-secondary text-primary !text-center"
[ngClass]="{'!p-0':f, '!pl-0':i==1}"> [ngClass]="{'!p-0':f, '!pl-0':i==1}" [colSpan]="f?2:1">
<span class="text-sm">{{ item }}</span> <span class="text-sm">{{ item }}</span>
<div *ngIf="!f" <div *ngIf="!l"
class="absolute top-1/2 transform -translate-y-1/2 right-0"> class="absolute top-1/2 transform -translate-y-1/2 right-0">
<svg class="head-table-icon" <svg class="head-table-icon"
xmlns="http://www.w3.org/2000/svg" width="50" xmlns="http://www.w3.org/2000/svg" width="50"
...@@ -254,7 +254,8 @@ ...@@ -254,7 +254,8 @@
</ng-container> </ng-container>
</div> </div>
</td> </td>
<td class="text-center !pl-0" style="font-size: 12px; width: 150px;"> <td class="text-left"
style="font-size: 12px;width: 90px;min-width: 90px;max-width: 90px;padding-left: 10px;">
{{item.apsassessy.employeeId}} {{item.apsassessy.employeeId}}
</td> </td>
<td style="font-size: 12px; width: 175px;"> <td style="font-size: 12px; width: 175px;">
......
<ng-container *ngIf="!settingIndividualKpi">
<div class=" pt-1.5rem mb-2">
<div class="flex flex-col gap-2">
<div class="flex flex-col gap-2 w-full">
<div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px">
<div class="box-body py-2">
<div class="flex item-center w-full font-size-18px font-weight-700 text-primary px-5 mt-1 mb-4"
style="height: 50px;align-items: center;border-width: 1px;background: #eff6fe; border-radius:20px">
รายชื่อผู้ใต้บังคับบัญชา
</div>
<div class="flex w-full mb-4">
<div class="flex w-1/4 justify-between">
<div class="flex">
<div class="flex items-center">
<input type="checkbox" class="ti-form-checkbox pointer-events-none" id="hs-default-checkbox"
[checked]="selectEmp.size-1 > 0">
<label for="hs-default-checkbox" class="text-sm text-gray-500 mx-2 pointer-events-none">
{{selectEmp.size-1 < 0 ? 0 : selectEmp.size-1}} Selected</label>
</div>
<div class="mx-1 flex items-center">
<button id='check-boxall' (click)="toggleSelectAll()"
class="focus:ring-2 focus:ring-primary rounded-sm flex item-center">
<i class="fs-l transition-all duration-200"
[ngClass]="{'ri-checkbox-multiple-line text-gray-500': !selectEmp.get('selectAll'), 'ri-checkbox-multiple-fill text-primary': selectEmp.get('selectAll')}"></i>
</button>
<label class="text-sm text-gray-500 ml-2 cursor-pointer" for="check-boxall"
(click)="toggleSelectAll()">Select All</label>
</div>
</div>
</div>
<div class="flex w-3/4 justify-end">
<div class="px-1">
<div class="relative shadow-md">
<input type="text" class="ti-form-input ltr:pl-11 rtl:pr-11 focus:z-10 "
placeholder="Search by No. or Name" [(ngModel)]="search">
<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">
<i class="ri-search-line text-gray"></i>
</div>
</div>
</div>
</div>
</div>
<div class="flex flex-col w-100">
<div class="overflow-auto rounded-t-md">
<div id="card-type-1" role="tabpanel" aria-labelledby="card-type-item-1">
<div class="overflow-auto shadow-md">
<table class="ti-custom-table ti-custom-table-head ti-custom-table-hover">
<thead>
<tr>
<ng-container
*ngFor="let item of ['รหัสพนักงาน','ชื่อพนักงาน','ตำเเหน่งงาน','สถานะ']; let f = first; let l = last; let i = index">
<th scope="col"
class="relative px-10px py-10px bg-soft-secondary text-primary !text-center"
[ngClass]="{'!p-0':f, '!pl-0':i==1}" [colSpan]="f?2:1">
<span class="text-sm">{{ item }}</span>
<div *ngIf="!l" class="absolute top-1/2 transform -translate-y-1/2 right-0">
<svg class="head-table-icon" xmlns="http://www.w3.org/2000/svg" width="50" height="16"
fill="currentColor" viewBox="0 0 16 16">
<path
d="M9.5 13a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0zm0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0zm0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0z">
</path>
</svg>
</div>
</th>
</ng-container>
</tr>
</thead>
<tbody *ngIf="subordinate.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="!subordinate.loading&&!subordinateFilter().length">
<tr>
<td class="text-center" colspan="100%">
ไม่พบข้อมูล
</td>
</tr>
</tbody>
<tbody *ngIf="!subordinate.loading&&subordinateFilter().length">
<tr *ngFor="let item of subordinateFilter();let i = index">
<td class="text-center !pr-1"
style="font-size: 12px;width: 90px;;min-width: 90px;max-width: 90px;">
<div class="flex-col gap-2">
<input
[disabled]="!(item.apsapproveType.code!='Apsapprove1'&&(item.masfromStatusType.code=='evaluating'||item.masfromStatusType.code=='pending'))"
[class.cursor-not-allowed]="!(item.apsapproveType.code!='Apsapprove1'&&(item.masfromStatusType.code=='evaluating'||item.masfromStatusType.code=='pending'))"
[class.accent-gray-400]="!(item.apsapproveType.code!='Apsapprove1'&&(item.masfromStatusType.code=='evaluating'||item.masfromStatusType.code=='pending'))"
[class.opacity-50]="!(item.apsapproveType.code!='Apsapprove1'&&(item.masfromStatusType.code=='evaluating'||item.masfromStatusType.code=='pending'))"
type="checkbox" class="ti-form-checkbox cursor-pointer"
[checked]="selectEmp.get(item.apsassessy.employeeId)"
(click)="!selectEmp.get(item.apsassessy.employeeId)?selectEmp.set(item.apsassessy.employeeId , true):selectEmp.delete(item.apsassessy.employeeId);checkSelectAll()">
&nbsp;
<ng-container
*ngIf="item.apsapproveType.code!='Apsapprove1'&&(item.masfromStatusType.code=='evaluating'||item.masfromStatusType.code=='pending')">
<img
(click)="!selectEmp.get(item.apsassessy.employeeId)?selectEmp.set(item.apsassessy.employeeId , true):selectEmp.delete(item.apsassessy.employeeId);checkSelectAll()"
class="cursor-pointer avatar shadow-none rounded-full !ring-transparent object-cover h-12 w-12"
[src]="item.apsassessy.picture?getImg(item.apsassessy.picture):'./assets/img/users/defaultperson.jpg'"
(error)="onImageError($event)">
</ng-container>
<ng-container
*ngIf="!(item.apsapproveType.code!='Apsapprove1'&&(item.masfromStatusType.code=='evaluating'||item.masfromStatusType.code=='pending'))">
<img
class="cursor-pointer avatar shadow-none rounded-full !ring-transparent object-cover h-12 w-12"
[src]="item.apsassessy.picture?getImg(item.apsassessy.picture):'./assets/img/users/defaultperson.jpg'"
(error)="onImageError($event)">
</ng-container>
</div>
</td>
<td class="text-left"
style="font-size: 12px;width: 90px;min-width: 90px;max-width: 90px;padding-left: 10px;">
{{item.apsassessy.employeeId}}
</td>
<td style="font-size: 12px; width: 175px;">
{{item.apsassessy.thFullName}}
</td>
<td style="font-size: 12px;">{{item.apsassessy.position.tdesc}}</td>
<td class="text-center">
<div class="flex justify-center">
<button type="button" class="ti-btn rounded-sm "
[class]="statusButtonClass(item.statusIdp.statusType)"
style="height: 30px; width: auto; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;"
(click)="settingIndividualKpi=true">
{{statusCompetencyText(item.statusIdp.statusType)}}
</button>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<nav class="pagination-style-3 my-5" *ngIf="page.length">
<ul class="ti-pagination">
<li>
<a aria-label="anchor" class="page-link" href="javascript:void(0);"
(click)="currentPage = (currentPage-1 || 1)">
<i class="ri-arrow-left-s-line align-middle rtl:rotate-180"></i>
</a>
</li>
<li *ngFor="let item of page;let f = first;let l = last">
<ng-container *ngIf="item==3&&currentPage!=1&&currentPage!=2&&currentPage!=3">
<a aria-label="anchor" class="page-link" href="javascript:void(0);"><i class="ri-more-line"></i>
</a>
</ng-container>
<ng-container *ngIf="(f||l)||(item==currentPage-1||item==currentPage||item==currentPage+1)">
<a class="page-link" href="javascript:void(0);" [class.active]="item==currentPage"
(click)="currentPage=item">{{item}}
</a>
</ng-container>
<ng-container
*ngIf="item==page.length-2&&currentPage!=page.length&&currentPage!=page.length-1&&currentPage!=page.length-2">
<a aria-label="anchor" class="page-link" href="javascript:void(0);"><i class="ri-more-line"></i>
</a>
</ng-container>
</li>
<li>
<a aria-label="anchor" class="page-link" href="javascript:void(0);"
(click)="currentPage = (currentPage > page.length-1 ? currentPage: currentPage+1 )">
<i class="ri-arrow-right-s-line align-middle rtl:rotate-180"></i>
</a>
</li>
</ul>
<ul class="nav-tabs mt-3">
<span>Show {{((currentPage-1) * 10)+1}} to {{subordinateFilter().length<10
?subordinateFilter().length: (currentPage==page.length ? ((currentPage * 10) - ((currentPage * 10)
- subordinateFilter().length) ) :(currentPage * 10) ) }} of {{subordinateFilter().length}}
items</span>
</ul>
</nav>
</div>
</div>
</div>
</div>
</div>
</div>
</ng-container>
<ng-container *ngIf="settingIndividualKpi">
<app-setting-individual-kpi [evaluationForm]="'sup'"
(sendReturnPath)="getBossList();settingIndividualKpi=false"></app-setting-individual-kpi>
</ng-container>
\ No newline at end of file
import { ChangeDetectorRef, Component, Input } from '@angular/core';
import { Router, ActivatedRoute } from '@angular/router';
import { AppraisalSubordinateModel, Masfromevaluationassessment } from 'src/app/shared/model/appraisal-subordinate.model';
import { EmployeeModel, MyEmployeeModel } from 'src/app/shared/model/employee.model';
import { AppraisalService } from 'src/app/shared/services/appraisal.service';
import { EmployeeService } from 'src/app/shared/services/employee.service';
import { FileService } from 'src/app/shared/services/file.service';
import { TokenService } from 'src/app/shared/services/token.service';
interface Row { label: string; value: number | string; }
@Component({
selector: 'app-setting-individual-kpi-supervisor',
templateUrl: './setting-individual-kpi-supervisor.component.html',
styleUrls: ['./setting-individual-kpi-supervisor.component.scss']
})
export class SettingIndividualKpiSupervisorComponent {
subordinate: { loading: false, select?: AppraisalSubordinateModel, dataList: AppraisalSubordinateModel[] } = { loading: false, select: undefined, dataList: [] }
selectEmp: Map<string, boolean> = new Map<string, boolean>()
currentPage = 1
page = Array.from({ length: 1 }, (_, i) => i + 1)
search = ""
settingIndividualKpi = false
constructor(private appraisalService: AppraisalService,
private fileService: FileService,
private cdr: ChangeDetectorRef) {
}
ngOnInit(): void {
this.getBossList()
}
getBossList() {
this.appraisalService.getBossList().subscribe({
next: response => {
this.subordinate.dataList = JSON.parse(JSON.stringify(response))
this.cdr.detectChanges()
if (this.subordinate.dataList.length) {
this.subordinate.select = JSON.parse(JSON.stringify(this.subordinate.dataList[0]))
this.cdr.detectChanges()
}
this.searchChange()
}, error: error => {
this.cdr.detectChanges()
}
})
}
searchChange() {
this.currentPage = 1
this.page = Array.from({ length: Math.ceil(this.subordinateFilter().length / 10) }, (_, i) => i + 1);
}
toggleSelectAll() {
if (this.subordinateFilter().filter(e => e.apsapproveType.code != 'Apsapprove1' && (e.masfromStatusType.code == 'evaluating' || e.masfromStatusType.code == 'pending')).length > 0) {
if (!this.selectEmp.get('selectAll')) {
this.selectEmp.set('selectAll', true)
this.subordinateFilter().filter(e => e.apsapproveType.code != 'Apsapprove1' && (e.masfromStatusType.code == 'evaluating' || e.masfromStatusType.code == 'pending')).forEach(e => {
this.selectEmp.set(e.apsassessy.employeeId, true)
})
} else {
this.selectEmp.set('selectAll', false)
this.selectEmp.clear()
}
}
}
subordinateFilter() {
if (this.subordinate.select) {
return this.subordinate.select.masfromevaluationassessment.filter(x => {
return x.apsassessy.employeeId.toLowerCase().includes(this.search.toLowerCase()) ||
x.apsassessy.thFullName.toLowerCase().includes(this.search.toLowerCase()) ||
x.apsassessy.position.tdesc.toLowerCase().includes(this.search.toLowerCase()) ||
this.statusCompetencyText(x.apsassessy.position.tdesc).toLowerCase().includes(this.search.toLowerCase()) ||
x.grade.toLowerCase().includes(this.search.toLowerCase()) ||
x.apsapproveType.tdesc.toLowerCase().includes(this.search.toLowerCase())
})
}
return []
}
statusCompetencyText = (status: string) => {
if (status === "no access") {
return "ยังไม่ถึงขั้นตอนดำเนินการ"
} else if (status === "pending") {
return "รอดำเนินการ"
} else if (status === "evaluating") {
return "อยู่ระหว่างดำเนินการ"
} else if (status === "completed") {
return "ดำเนินการเสร็จสิ้น"
} else if (status === "rejected") {
return "ส่งกลับ"
} else {
return ""
}
}
statusButtonClass = (status: string) => {
if (status === "no access") {
return "ti-btn-soft-mute"
} else if (status === "pending") {
return "ti-btn-soft-secondary"
} else if (status === "evaluating") {
return "ti-btn-soft-warning"
} else if (status === "completed") {
return "ti-btn-soft-success"
} else if (status === "rejected") {
return "ti-btn-soft-danger"
} else {
return ""
}
}
getImg(text: string) {
return this.fileService.getImg(text)
}
onImageError(event: Event) {
const imgElement = event.target as HTMLImageElement;
imgElement.src = './assets/img/users/defaultperson.jpg';
}
checkSelectAll() {
this.selectEmp.set('selectAll', (this.subordinateFilter().filter(e => e.apsapproveType.code != 'Apsapprove1' && (e.masfromStatusType.code == 'evaluating' || e.masfromStatusType.code == 'pending')).length > 0 && this.subordinateFilter().filter(e => e.apsapproveType.code != 'Apsapprove1' && (e.masfromStatusType.code == 'evaluating' || e.masfromStatusType.code == 'pending')).length == this.selectEmp.size - 1))
}
selectSubordinate(data: Masfromevaluationassessment, competencyTypeId: string, evaluationRoundId?: string, masfromStatusType?: string) {
if (data && evaluationRoundId) {
// this.formEvaluation.evaluateeId = data.apsassessy.employeeId
// this.formEvaluation.competencyTypeId = competencyTypeId
// this.formEvaluation.evaluationRoundId = evaluationRoundId
// this.formEvaluation.masfromStatusType = masfromStatusType || ''
// this.formEvaluation.allCompetencyTypeId = data.typeList
this.cdr.detectChanges()
}
}
}
<ng-container *ngTemplateOutlet="evaluation"></ng-container>
<ng-template #evaluation>
<div class=" pt-1.5rem">
<div class="flex flex-col gap-2">
<div class="flex flex-row gap-2">
<div class="flex flex-col gap-2 w-1/4">
<div class="w-full mb-2">
<div class="font-size-18px font-weight-700 text-primary">
<div class="absolute " style="transform:translateY(-9px)">
<button type="button" *ngIf="evaluationForm=='sup'"
class="ti-btn ti-btn-outline ti-btn-outline-light h-20px m-0 shadow-md hover:shadow-xl transition text-blue-500 bg-white"
(click)="returnPath()">
<i class="ti ti-chevron-left"></i>
ย้อนกลับ
</button>
</div>
<span class="whitespace-nowrap relative" [ngStyle]="{'left': evaluationForm=='sup' ? '105px':'0px'}">
แก้ไข Individual KPI {{evaluationForm=='sup'?'โดยหัวหน้า':'ตัวเอง'}}
</span>
</div>
</div>
</div>
</div>
<div class="flex flex-row gap-2">
<div class="flex flex-col gap-2 w-1/4" [class.hidden]="menuClose.get('ข้อมูลรายละเอียด')">
<div class="flex flex-col gap-2" style="height:calc(100vh - 177px);overflow-y: auto;">
<div class="w-full">
<div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px">
<div class="box-body py-2">
<div class="flex flex-col items-center gap-3">
<img
[src]="evaluatee.data.picture?getImg(evaluatee.data.picture):'./assets/img/users/defaultperson.jpg'"
(error)="onImageError($event)" class="h-24 w-24 rounded-full ring-4 ring-primary object-cover"
alt="profile-img" />
</div>
</div>
</div>
</div>
<div class="w-full">
<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="flex justify-between">
<h5 class="box-title align-center">ข้อมูลพนักงาน</h5>
<i *ngIf="menuClose.get('ข้อมูลพนักงาน')" title="แสดง"
class="bg-white cursor-pointer border ti ti-chevron-down"
style="padding: 1px;border-radius:10px;font-size:27px"
(click)="menuClose.set('ข้อมูลพนักงาน',false)"></i>
<i *ngIf="!menuClose.get('ข้อมูลพนักงาน')" title="ปิด"
class="bg-white cursor-pointer border ti ti-chevron-up"
style="padding: 1px;border-radius:10px;font-size:27px"
(click)="menuClose.set('ข้อมูลพนักงาน',true)"></i>
</div>
</div>
<div class="box-body py-2" [class.hidden]="menuClose.get('ข้อมูลพนักงาน')">
<table class="ti-custom-table border-0 ellipsis-text">
<tbody>
<tr class="!border-0">
<td class="!p-2 align-start" style="font-size: 1rem;font-weight: 500;color:black;">รหัสพนักงาน
</td>
<td class="!p-2 align-start">:</td>
<td class="font-medium !p-2 align-start !text-warp">
{{evaluatee.data.employeeId}}
</td>
</tr>
<tr class="!border-0">
<td class="!p-2 align-start" style="font-size: 1rem;font-weight: 500;color:black;">ชื่อ - สกุล
</td>
<td class="!p-2 align-start">:</td>
<td class="font-medium !p-2 align-start !text-warp">
{{evaluatee.data.thFullName}}
</td>
</tr>
<tr class="!border-0">
<td class="!p-2 align-start" style="font-size: 1rem;font-weight: 500;color:black;">ตำเเหน่ง</td>
<td class="!p-2 align-start">:</td>
<td class="font-medium !p-2 align-start !text-warp">
{{evaluatee.data.position.tdesc}}
</td>
</tr>
<tr class="!border-0">
<td class="!p-2 align-start" style="font-size: 1rem;font-weight: 500;color:black;">ฝ่าย</td>
<td class="!p-2 align-start">:</td>
<td class="font-medium !p-2 align-start !text-warp">
{{evaluatee.data.bu1.tdesc}}
</td>
</tr>
<tr class="!border-0">
<td class="!p-2 align-start" style="font-size: 1rem;font-weight: 500;color:black;">แผนก</td>
<td class="!p-2 align-start">:</td>
<td class="font-medium !p-2 align-start !text-warp">
{{evaluatee.data.bu2.tdesc}}
</td>
</tr>
<tr class="!border-0">
<td class="!p-2 align-start" style="font-size: 1rem;font-weight: 500;color:black;">ระดับ</td>
<td class="!p-2 align-start">:</td>
<td class="font-medium !p-2 align-start !text-warp">
{{evaluatee.data.pl.tdesc}}
</td>
</tr>
<tr class="!border-0">
<td class="!p-2 align-start" style="font-size: 1rem;font-weight: 500;color:black;">E-mail</td>
<td class="!p-2 align-start">:</td>
<td class="font-medium !p-2 align-start !text-warp">
{{evaluatee.data.email}}
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
<div class="flex flex-col gap-2"
[ngClass]="{ 'w-3/4': !menuClose.get('ข้อมูลรายละเอียด'), 'w-full':menuClose.get('ข้อมูลรายละเอียด')}">
<div class="w-full relative">
<div class="absolute h-full hover-visible" style="z-index: 1;transform: translateX(-15%);">
<div [title]="menuClose.get('ข้อมูลรายละเอียด')?'แสดงข้อมูลรายละเอียด':'ปิดข้อมูลรายละเอียด'"
(click)="menuClose.get('ข้อมูลรายละเอียด')?menuClose.set('ข้อมูลรายละเอียด',false):menuClose.set('ข้อมูลรายละเอียด',true)"
class="cursor-pointer hover-show h-full border"
style="border-right:0 ;align-content:center;background: linear-gradient(to right, rgb(237, 237, 237), rgb(245 , 245 , 245 ),rgb(255, 255, 255 , 0));border-radius:20px 0 0 20px">
<i *ngIf="menuClose.get('ข้อมูลรายละเอียด')" class="cursor-pointer ti ti-chevron-right "
style="padding: 1px;font-size:27px;height:33px" (click)="menuClose.set('ข้อมูลรายละเอียด',true)"></i>
<i *ngIf="!menuClose.get('ข้อมูลรายละเอียด')" class="cursor-pointer ti ti-chevron-left "
style="padding: 1px;font-size:27px;height:33px" (click)="menuClose.set('ข้อมูลรายละเอียด',false)"></i>
</div>
</div>
<div class="box shadow-md hover:shadow-xl transition m-0" style="border-radius:20px;">
<div class="box-header" style="border:0">
</div>
<div #scrollContainer class="box-body pt-0" style="overflow-y: auto; height: calc(100vh - 253px)">
<div class="min-height: calc(100vh - 406px);">
<ng-container *ngTemplateOutlet="pmsEvaluation"></ng-container>
</div>
<div class="box-footer text-end space-x-3 rtl:space-x-reverse"
style="margin: 0.5rem -24px -24px -24px;">
<button class="ti-btn m-0 ti-btn-soft-secondary">
<i class="ri-save-3-fill"></i>
ยืนยันข้อมูล
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</ng-template>
<ng-template #pmsEvaluation>
<div class="flex flex-col">
<div class="flex flex-col gap-2" style="min-height: calc(100vh - 479px);">
<div class=" flex flex-col gap-2" [attr.id]="'menu-part-3'">
<button type="button"
class="p-4 w-full bg-gradient-to-r from-primary to-secondary text-white text-left font-semibold"
style="border-radius:20px">
ประเมินผลการปฏิบัติงานประจำ&nbsp;(Individual KPI)
</button>
<div class="relative">
<table style="table-layout: fixed; width: 100%;">
<thead class="border-b border-gray-200">
<tr style="height:35px">
<th scope="col">ตัวชี้วัด</th>
<th scope="col">น้ำหนัก</th>
<th scope="col">เป้าหมาย</th>
<th scope="col">หน่วยนับ</th>
<th scope="col">กำหนดเสร็จ</th>
<th scope="col">เพิ่มเติม</th>
</tr>
</thead>
<tbody>
<ng-container *ngFor="let item of individualKPI.list;let i = index">
<tr class="border-b border-gray-200"
(mouseenter)="tableHover.set(item.groupAssessment1.pmsTopic.indicatorsDetail,true)"
(mouseleave)="tableHover.clear()"
[ngStyle]="{'background':tableHover.get(item.groupAssessment1.pmsTopic.indicatorsDetail)?'#f1f5f9':'#ffffff'}">
<td class="py-2" style="vertical-align: top">
{{item.groupAssessment1.pmsTopic.indicatorsDetail}}</td>
<td class="py-2 text-center" style="vertical-align: top">{{item.weight}}</td>
<td class="py-2 text-center" style="vertical-align: top">
{{item.groupAssessment1.pmsTopic.performanceGoalsDetail}}
</td>
<td class="py-2 text-center" style="vertical-align: top">
{{item.groupAssessment1.pmsTopic.detailUnit}}
</td>
<td class="py-2 text-center" style="vertical-align: top">
{{item.groupAssessment1.pmsTopic.completionDate}}
</td>
<td class="py-2 text-center" style="vertical-align: top">
<div class="hs-tooltip ti-main-tooltip [--trigger:hover]">
<div class="hs-tooltip-toggle ti-main-tooltip-toggle">
<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 gap-2 font-weight-700">
<div>รายละเอียดข้อมูล</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
ที่มาของนโยบาย
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
{{item.groupAssessment1.pmsTopic.tdesc}}
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
ตัวชี้วัด
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
{{item.groupAssessment1.pmsTopic.indicatorsDetail}}
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
เป้าหมาย
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
{{item.groupAssessment1.pmsTopic.performanceGoalsDetail}}
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
หน่วยนับ
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
{{item.groupAssessment1.pmsTopic.detailUnit}}
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
กำหนดเสร็จ
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
{{item.groupAssessment1.pmsTopic.completionDate}}
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
น้ำหนัก
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
{{item.weight}}
</div>
</div>
</div>
</div>
</div>
</div>
</td>
</tr>
</ng-container>
<tr>
<td class="py-2 text-center">
<input type="text" id="input-label" class="ti-form-input">
</td>
<td class="py-2 text-center">
<input type="text" id="input-label" class="ti-form-input">
</td>
<td class="py-2 text-center">
<input type="text" id="input-label" class="ti-form-input">
</td>
<td class="py-2 text-center">
<input type="text" id="input-label" class="ti-form-input">
</td>
<td class="py-2 text-center">
<input type="text" id="input-label" class="ti-form-input">
</td>
<td class="py-2 text-center" style="justify-items:center">
<ng-container *ngIf="true">
<button type="button" class="flex text-start items-center cursor-default">
<i class="ti ti-circle-plus text-green-500 cursor-pointer" style="font-size: 20px;"
data-hs-overlay="#assessment-table-modal"></i>
</button>
</ng-container>
<ng-container *ngIf="false">
<div class="hs-tooltip ti-main-tooltip [--trigger:hover]">
<div class="hs-tooltip-toggle ti-main-tooltip-toggle">
<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 gap-2 font-weight-700">
<div>รายละเอียดข้อมูล</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
ที่มาของนโยบาย
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
ตัวชี้วัด
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
เป้าหมาย
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
หน่วยนับ
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
กำหนดเสร็จ
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
</div>
</div>
<div class="text-start flex flex-row">
<div style="width: 100px;">
น้ำหนัก
</div>
<div class="px-1">
&nbsp;:&nbsp;
</div>
<div class="flex-1">
</div>
</div>
</div>
</div>
</div>
</div>
</ng-container>
</td>
</tr>
<tr>
<td class="py-2 text-center" style="vertical-align: center;justify-items:center" colspan="6">
<button type="button" class="flex text-start items-center cursor-default">
<i class="ti ti-circle-plus text-green-500 cursor-pointer" style="font-size: 20px;"></i>
</button>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
</ng-template>
<div id="assessment-table-modal" class="hs-overlay hidden ti-modal">
<div class="hs-overlay-open:mt-7 ti-modal-box mt-0 ease-out lg:!max-w-4xl lg:w-full m-3 lg:!mx-auto !max-w-3/4">
<div class="max-h-full overflow-hidden ti-modal-content">
<div class="ti-modal-header">
<h3 class="text-xxl font-bold text-primary">
รายการประเมิน
</h3>
<div class="flex justify-end">
<button type="button" class="hs-dropdown-toggle ti-modal-clode-btn text-danger"
data-hs-overlay="#assessment-table-modal">
<span class="sr-only">Close</span>
<i class="ti ti-circle-x fs-xxl"></i>
</button>
</div>
</div>
<div class="ti-modal-body">
<div class="flex justify-end pb-1rem">
<div class="px-1">
<div class="relative shadow-md">
<input type="text" id="hs-leading-icon" name="hs-leading-icon"
class="ti-form-input ltr:pl-11 rtl:pr-11 focus:z-10 " placeholder="Search by No. or Name"
[(ngModel)]="modal.search" (ngModelChange)="searchModalChange(pmstopicListFilter())">
<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">
<i class="ri-search-line text-gray"></i>
</div>
</div>
</div>
</div>
<div class="page px-rem">
<div class="overflow-auto table-bordered rounded-t-md">
<div class="overflow-auto shadow-md rounded-t-md">
<table class="ti-custom-table ti-custom-table-head ti-custom-table-hover">
<thead>
<tr>
<ng-container
*ngFor="let item of ['รหัส','ชื่อหัวข้อ','ประเภท','น้ำหนัก','การจัดการ']; let f = first; let l = last; let i = index">
<th scope="col" class=" 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>
</tr>
</thead>
<tbody *ngIf="pmstopic.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="!pmstopic.loading&&!pmstopicListFilter().length">
<tr>
<td class="text-center" colspan="100%">
ไม่พบข้อมูล
</td>
</tr>
</tbody>
<tbody *ngIf="!pmstopic.loading&&pmstopicListFilter().length">
<tr
*ngFor="let item of pmstopicListFilter() | slice:((modal.currentPage-1) * 10) : (((modal.currentPage-1) * 10) + 10);let i = index">
<td class="text-center">
{{item.data.pmsTopicId}}
</td>
<td>{{item.data.tdesc}}</td>
<td>{{item.data.pmsType.tdesc}}</td>
<td>{{item.data.weight}}</td>
<td class="text-center"> <button type="button"
class="ti-btn ti-btn-soft-secondary h-20px m-0 shadow-md"
data-hs-overlay="#assessment-table-modal" (click)="selectPmstopic(item.data)">
<i class="ri-add-line"></i>
Select
</button></td>
</tr>
</tbody>
</table>
</div>
</div>
<nav class="pagination-style-3 my-5" *ngIf="modal.page.length">
<ul class="ti-pagination">
<li>
<a aria-label="anchor" class="page-link" href="javascript:void(0);"
(click)="modal.currentPage = (modal.currentPage-1 || 1)">
<i class="ri-arrow-left-s-line align-middle rtl:rotate-180"></i>
</a>
</li>
<li *ngFor="let item of modal.page;let f = first;let l = last">
<ng-container *ngIf="item==3&&modal.currentPage!=1&&modal.currentPage!=2&&modal.currentPage!=3">
<a aria-label="anchor" class="page-link" href="javascript:void(0);"><i class="ri-more-line"></i>
</a>
</ng-container>
<ng-container
*ngIf="(f||l)||(item==modal.currentPage-1||item==modal.currentPage||item==modal.currentPage+1)">
<a class="page-link" href="javascript:void(0);" [class.active]="item==modal.currentPage"
(click)="modal.currentPage=item">{{item}}
</a>
</ng-container>
<ng-container
*ngIf="item==modal.page.length-2&&modal.currentPage!=modal.page.length&&modal.currentPage!=modal.page.length-1&&modal.currentPage!=modal.page.length-2">
<a aria-label="anchor" class="page-link" href="javascript:void(0);"><i class="ri-more-line"></i>
</a>
</ng-container>
</li>
<li>
<a aria-label="anchor" class="page-link" href="javascript:void(0);"
(click)="modal.currentPage = (modal.currentPage > modal.page.length-1 ? modal.currentPage: modal.currentPage+1 )">
<i class="ri-arrow-right-s-line align-middle rtl:rotate-180"></i>
</a>
</li>
</ul>
<ul class="nav-tabs mt-3">
<span>Show {{((modal.currentPage-1) * 10)+1}} to {{pmstopicListFilter().length<10
?pmstopicListFilter().length: (modal.currentPage==modal.page.length ? ((modal.currentPage * 10) -
((modal.currentPage * 10) - pmstopicListFilter().length) ) :(modal.currentPage * 10) ) }} of
{{pmstopicListFilter().length}} items</span>
</ul>
</nav>
</div>
<div class="flex justify-end mt-2rem mb-1rem space-x-4">
<button type="button"
class="hs-dropdown-toggle ti-btn ti-border font-medium bg-white text-gray-700 shadow-sm align-middle hover:bg-gray-50 focus:ring-offset-white focus:ring-primary dark:bg-bgdark dark:hover:bg-black/20 dark:border-white/10 dark:text-white/70 dark:hover:text-white dark:focus:ring-offset-white/10"
data-hs-overlay="#assessment-table-modal">
ย้อนกลับ
</button>
</div>
</div>
</div>
</div>
</div>
\ No newline at end of file
.hover-visible {
.hover-show {
opacity: 0;
}
}
.hover-visible:hover {
.hover-show {
opacity: 1;
}
}
import { ChangeDetectorRef, Component, EventEmitter, Input, Output } from '@angular/core';
import { Router, ActivatedRoute } from '@angular/router';
import { EmployeeModel, MyEmployeeModel } from 'src/app/shared/model/employee.model';
import { MyPmsGroupAssessment1Model } from 'src/app/shared/model/pms-group-assessment1.model';
import { MyPmstopicModel, PmstopicModel } from 'src/app/shared/model/pmstopic.model';
import { AppraisalService } from 'src/app/shared/services/appraisal.service';
import { EmployeeService } from 'src/app/shared/services/employee.service';
import { FileService } from 'src/app/shared/services/file.service';
import { PmstopicService } from 'src/app/shared/services/pmstopic.service';
import { TokenService } from 'src/app/shared/services/token.service';
export interface DataModal {
search: string,
currentPage: number,
page: number[]
}
@Component({
selector: 'app-setting-individual-kpi',
templateUrl: './setting-individual-kpi.component.html',
styleUrls: ['./setting-individual-kpi.component.scss']
})
export class SettingIndividualKpiComponent {
@Input() evaluateeId = ""
individualKPI: { loading: boolean, list: any[] } = { loading: false, list: [] }
@Input() evaluationForm: 'self' | 'sup' = "self"
menuClose: Map<string, boolean> = new Map<string, boolean>()
tableHover: Map<string, boolean> = new Map<string, boolean>()
evaluatee: { loading: boolean, data: EmployeeModel } = { loading: false, data: new MyEmployeeModel() }
@Output() sendReturnPath: EventEmitter<any> = new EventEmitter<any>();
modal: DataModal = {
search: "",
currentPage: 1,
page: Array.from({ length: 1 }, (_, i) => i + 1)
}
pmstopic: { loading: boolean, select: PmstopicModel, dataList: { check: boolean, data: PmstopicModel }[] } = { loading: false, select: new MyPmstopicModel(), dataList: [] }
constructor(
private router: Router,
private employeeService: EmployeeService,
private appraisalService: AppraisalService,
private cdr: ChangeDetectorRef,
private tokenService: TokenService,
private route: ActivatedRoute,
private fileService: FileService,
private pmstopicService: PmstopicService
) {
}
ngOnInit(): void {
this.getEvaluatee()
this.getPmstopicList()
}
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()
}
})
}
returnPath() {
this.sendReturnPath.emit()
}
getImg(text: string) {
return this.fileService.getImg(text)
}
onImageError(event: Event) {
const imgElement = event.target as HTMLImageElement;
imgElement.src = './assets/img/users/defaultperson.jpg';
}
searchModalChange(dataList: any[]) {
this.modal.currentPage = 1
this.modal.page = Array.from({ length: Math.ceil(dataList.length / 10) }, (_, i) => i + 1);
this.cdr.markForCheck()
}
getPmstopicList() {
this.pmstopic.loading = true
this.pmstopicService.getList().subscribe({
next: response => {
this.pmstopic.dataList = response.map(x => ({ check: false, data: new MyPmstopicModel(x) }))
this.pmstopic.loading = false
this.cdr.detectChanges()
}, error: error => {
this.pmstopic.loading = false
this.cdr.detectChanges()
}
})
}
pmstopicListFilter() {
return this.pmstopic.dataList.filter(x => {
const data = x.data
const match = data.pmsTopicId.toLowerCase().includes(this.modal.search.toLowerCase()) ||
data.tdesc.toLowerCase().includes(this.modal.search.toLowerCase()) ||
data.pmsType.tdesc.toLowerCase().includes(this.modal.search.toLowerCase()) ||
(data.weight + "").toLowerCase().includes(this.modal.search.toLowerCase())
return match
})
}
selectPmstopic(data?: PmstopicModel) {
this.cdr.markForCheck()
}
}
...@@ -114,7 +114,7 @@ export class NavService implements OnDestroy { ...@@ -114,7 +114,7 @@ export class NavService implements OnDestroy {
selected: false, selected: false,
active: false, active: false,
path: 'ess/supervisor-evaluation', path: 'ess/supervisor-evaluation',
id: 'm1', id: 'm2',
show: true, show: true,
icon: 'assets/img/icons-menu/com-boss.png' icon: 'assets/img/icons-menu/com-boss.png'
// children: [ // children: [
...@@ -122,6 +122,26 @@ export class NavService implements OnDestroy { ...@@ -122,6 +122,26 @@ export class NavService implements OnDestroy {
// { id: 'm12', path: 'ess/supervisor-evaluation', title: 'ประเมินโดยหัวหน้า', type: 'link', show: true }, // { id: 'm12', path: 'ess/supervisor-evaluation', title: 'ประเมินโดยหัวหน้า', type: 'link', show: true },
// ], // ],
}, },
// {
// title: 'แก้ไข Individual KPI ตนเอง',
// type: 'link',
// selected: false,
// active: false,
// path: 'ess/self-setting-individual-kpi',
// id: 'm3',
// show: false,
// icon: ''
// },
// {
// title: 'แก้ไข Individual KPI โดยหัวหน้า',
// type: 'link',
// selected: false,
// active: false,
// path: 'ess/supervisor-setting-individual-kpi',
// id: 'm4',
// show: false,
// icon: ''
// },
]; ];
} }
......
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