Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mySkill-x
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
angular
mySkill-x
Commits
ddf38e69
Commit
ddf38e69
authored
Mar 24, 2025
by
Nattana Chaiyamat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ปุ่มไม่อนุมัติหน้าประเมิน
parent
42d22de4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
65 additions
and
22 deletions
+65
-22
evaluation.component.html
...rformance-evaluation/evaluation/evaluation.component.html
+11
-2
evaluation.component.ts
...performance-evaluation/evaluation/evaluation.component.ts
+43
-13
supervisor-evaluation.component.html
...upervisor-evaluation/supervisor-evaluation.component.html
+11
-7
No files found.
src/app/components/performance-evaluation/evaluation/evaluation.component.html
View file @
ddf38e69
...
@@ -416,11 +416,20 @@
...
@@ -416,11 +416,20 @@
</div>
</div>
<div
class=
"flex justify-center mb-1rem pb-2rem"
*
ngIf=
"canSave"
>
<div
class=
"flex justify-center mb-1rem pb-2rem"
*
ngIf=
"canSave"
>
<button
*
ngIf=
"appraisalCompentency.data.checkStep!='0'&&appraisalCompentency.data.checkStep!='1'"
type=
"submit"
class=
"ti-btn ti-btn-danger mx-2rem"
(
click
)="
save
('
noApprove
')"
>
ไม่อนุมัติ
</button>
<button
type=
"submit"
class=
"ti-btn ti-btn-success mx-2rem"
(
click
)="
save
('
draft
')"
>
<button
type=
"submit"
class=
"ti-btn ti-btn-success mx-2rem"
(
click
)="
save
('
draft
')"
>
บันทึกร่าง
บันทึกร่าง
</button>
</button>
<button
type=
"submit"
class=
"ti-btn ti-btn-success mx-2rem"
(
click
)="
save
()"
>
<button
type=
"submit"
class=
"ti-btn ti-btn-secondary mx-2rem"
(
click
)="
save
('
approve
')"
>
บันทึกข้อมูล
<ng-container
*
ngIf=
"appraisalCompentency.data.checkStep=='0'"
>
ยืนยันข้อมูล
</ng-container>
<ng-container
*
ngIf=
"appraisalCompentency.data.checkStep!='0'"
>
อนุมัติ
</ng-container>
</button>
</button>
</div>
</div>
</ng-container>
</ng-container>
...
...
src/app/components/performance-evaluation/evaluation/evaluation.component.ts
View file @
ddf38e69
...
@@ -81,7 +81,7 @@ export class EvaluationComponent implements OnInit {
...
@@ -81,7 +81,7 @@ export class EvaluationComponent implements OnInit {
next
:
response
=>
{
next
:
response
=>
{
this
.
appraisalCompentency
.
data
=
JSON
.
parse
(
JSON
.
stringify
(
response
))
this
.
appraisalCompentency
.
data
=
JSON
.
parse
(
JSON
.
stringify
(
response
))
if
(
this
.
appraisalCompentency
.
data
?.
masfromEvaluationAssessment1lList
[
0
])
{
if
(
this
.
appraisalCompentency
.
data
?.
masfromEvaluationAssessment1lList
[
0
])
{
this
.
canSave
=
this
.
appraisalCompentency
.
data
.
currentStep
==
this
.
appraisalCompentency
.
data
.
checkStep
this
.
canSave
=
(
this
.
appraisalCompentency
.
data
.
currentStep
==
this
.
appraisalCompentency
.
data
.
checkStep
)
&&
this
.
appraisalCompentency
.
data
.
masfromStatusType
.
code
!=
'Boss_finish'
this
.
canEdit
=
(
this
.
appraisalCompentency
.
data
.
currentStep
==
this
.
appraisalCompentency
.
data
.
checkStep
&&
(
+
(
this
.
appraisalCompentency
.
data
.
checkStep
)
<=
1
))
this
.
canEdit
=
(
this
.
appraisalCompentency
.
data
.
currentStep
==
this
.
appraisalCompentency
.
data
.
checkStep
&&
(
+
(
this
.
appraisalCompentency
.
data
.
checkStep
)
<=
1
))
switch
(
this
.
appraisalCompentency
.
data
?.
currentStep
)
{
switch
(
this
.
appraisalCompentency
.
data
?.
currentStep
)
{
case
(
"0"
):
{
case
(
"0"
):
{
...
@@ -254,7 +254,33 @@ export class EvaluationComponent implements OnInit {
...
@@ -254,7 +254,33 @@ export class EvaluationComponent implements OnInit {
}
}
save
(
status
?:
string
)
{
save
(
status
:
'approve'
|
'noApprove'
|
'draft'
)
{
let
title
=
''
let
text
=
''
let
confirmButtonText
=
''
let
approveStatus
=
'0'
if
(
status
==
'draft'
)
{
title
=
'บันทึกแบบร่าง'
text
=
'คุณต้องการบันทึกแบบร่างของการประเมินนี้ใช่หรือไม่'
confirmButtonText
=
'ยืนยันการบันทึก'
approveStatus
=
'1'
}
else
if
(
status
==
'approve'
)
{
approveStatus
=
'2'
if
(
this
.
appraisalCompentency
?.
data
?.
checkStep
==
'0'
)
{
title
=
'ยืนยันข้อมูล'
text
=
'คุณต้องการยืนยันข้อมูลการประเมินนี้ใช่หรือไม่'
confirmButtonText
=
'ยืนยันการบันทึก'
}
else
{
title
==
'อนุมัติ'
text
=
'คุณต้องการอนุมัติข้อมูลการประเมินนี้ใช่หรือไม่'
confirmButtonText
=
'ยืนยันการอนุมัติ'
}
}
else
if
(
status
==
'noApprove'
)
{
approveStatus
=
'0'
title
==
'ไม่อนุมัติ'
text
=
'คุณต้องการไม่อนุมัติข้อมูลการประเมินนี้ใช่หรือไม่'
confirmButtonText
=
'ยืนยันการไม่อนุมัติ'
}
Swal
.
fire
({
Swal
.
fire
({
iconHtml
:
`
iconHtml
:
`
<div class="flex items-center justify-center rounded-full !h-80px !w-80px" style="background-color: #E8F8EE;">
<div class="flex items-center justify-center rounded-full !h-80px !w-80px" style="background-color: #E8F8EE;">
...
@@ -272,10 +298,10 @@ export class EvaluationComponent implements OnInit {
...
@@ -272,10 +298,10 @@ export class EvaluationComponent implements OnInit {
</svg>
</svg>
</div>
</div>
`
,
`
,
title
:
status
==
'draft'
?
'บันทึกแบบร่าง'
:
'บันทึกข้อมูล'
,
title
:
title
,
text
:
status
==
'draft'
?
'คุณต้องการบันทึกแบบร่างของการประเมินนี้ใช่หรือไม่'
:
'คุณต้องการบันทึกข้อมูลการประเมินนี้ใช่หรือไม่'
,
text
:
text
,
showCancelButton
:
true
,
showCancelButton
:
true
,
confirmButtonText
:
'ยืนยันการบันทึก'
,
confirmButtonText
:
confirmButtonText
,
cancelButtonText
:
'ย้อนกลับ'
,
cancelButtonText
:
'ย้อนกลับ'
,
customClass
:
{
customClass
:
{
title
:
'!swal2-title-mt-20px'
,
title
:
'!swal2-title-mt-20px'
,
...
@@ -286,7 +312,7 @@ export class EvaluationComponent implements OnInit {
...
@@ -286,7 +312,7 @@ export class EvaluationComponent implements OnInit {
},
},
}).
then
((
result
)
=>
{
}).
then
((
result
)
=>
{
if
(
result
.
isConfirmed
&&
this
.
appraisalCompentency
)
{
if
(
result
.
isConfirmed
&&
this
.
appraisalCompentency
)
{
this
.
saveApi
(
s
tatus
)
this
.
saveApi
(
approveS
tatus
)
}
else
if
(
result
.
dismiss
===
Swal
.
DismissReason
.
cancel
)
{
}
else
if
(
result
.
dismiss
===
Swal
.
DismissReason
.
cancel
)
{
Swal
.
fire
({
Swal
.
fire
({
title
:
'ยกเลิก!'
,
title
:
'ยกเลิก!'
,
...
@@ -299,14 +325,14 @@ export class EvaluationComponent implements OnInit {
...
@@ -299,14 +325,14 @@ export class EvaluationComponent implements OnInit {
}
}
})
})
}
}
saveApi
(
status
?
:
string
)
{
saveApi
(
approveStatus
:
string
)
{
let
body
=
this
.
appraisalCompentency
.
data
let
body
=
this
.
appraisalCompentency
.
data
switch
(
this
.
appraisalCompentency
.
data
?.
currentStep
)
{
switch
(
this
.
appraisalCompentency
.
data
?.
currentStep
)
{
case
(
"0"
):
{
case
(
"0"
):
{
body
=
{
body
=
{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
apsassessyStatus
:
status
==
'draft'
?
'1'
:
'2'
apsassessyStatus
:
approveStatus
}]
}]
}
}
break
break
...
@@ -315,7 +341,7 @@ export class EvaluationComponent implements OnInit {
...
@@ -315,7 +341,7 @@ export class EvaluationComponent implements OnInit {
body
=
{
body
=
{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
apsapprove1Status
:
status
==
'draft'
?
'1'
:
'2'
apsapprove1Status
:
approveStatus
}]
}]
}
}
break
break
...
@@ -324,7 +350,8 @@ export class EvaluationComponent implements OnInit {
...
@@ -324,7 +350,8 @@ export class EvaluationComponent implements OnInit {
body
=
{
body
=
{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
apsapprove2Status
:
status
==
'draft'
?
'1'
:
'2'
apsapprove1Status
:
approveStatus
==
'0'
?
approveStatus
:
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
].
apsapprove1Status
,
apsapprove2Status
:
approveStatus
}]
}]
}
}
break
break
...
@@ -333,7 +360,8 @@ export class EvaluationComponent implements OnInit {
...
@@ -333,7 +360,8 @@ export class EvaluationComponent implements OnInit {
body
=
{
body
=
{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
apsapprove3Status
:
status
==
'draft'
?
'1'
:
'2'
apsapprove2Status
:
approveStatus
==
'0'
?
approveStatus
:
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
].
apsapprove2Status
,
apsapprove3Status
:
approveStatus
}]
}]
}
}
break
break
...
@@ -342,7 +370,8 @@ export class EvaluationComponent implements OnInit {
...
@@ -342,7 +370,8 @@ export class EvaluationComponent implements OnInit {
body
=
{
body
=
{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
apsapprove4Status
:
status
==
'draft'
?
'1'
:
'2'
apsapprove3Status
:
approveStatus
==
'0'
?
approveStatus
:
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
].
apsapprove3Status
,
apsapprove4Status
:
approveStatus
}]
}]
}
}
break
break
...
@@ -351,7 +380,8 @@ export class EvaluationComponent implements OnInit {
...
@@ -351,7 +380,8 @@ export class EvaluationComponent implements OnInit {
body
=
{
body
=
{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
,
masfromEvaluationAssessment1lList
:
[{
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
...
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
],
apsapprove5Status
:
status
==
'draft'
?
'1'
:
'2'
apsapprove4Status
:
approveStatus
==
'0'
?
approveStatus
:
this
.
appraisalCompentency
.
data
.
masfromEvaluationAssessment1lList
[
0
].
apsapprove4Status
,
apsapprove5Status
:
approveStatus
}]
}]
}
}
break
break
...
...
src/app/components/performance-evaluation/supervisor-evaluation/supervisor-evaluation.component.html
View file @
ddf38e69
...
@@ -108,7 +108,6 @@
...
@@ -108,7 +108,6 @@
<button
type=
"button"
class=
"ti-btn rounded-sm "
<button
type=
"button"
class=
"ti-btn rounded-sm "
*
ngFor=
"let type of item.typeList"
*
ngFor=
"let type of item.typeList"
[
class
.
ti-btn-soft-mute
]="
type
.
statusType =
=
'
Not_evaluating_yet
'"
[
class
.
ti-btn-soft-mute
]="
type
.
statusType =
=
'
Not_evaluating_yet
'"
[
class
.
pointer-events-none
]="
type
.
statusType =
=
'
Not_evaluating_yet
'"
[
class
.
ti-btn-soft-secondary
]="
type
.
statusType =
=
'
Boss
'"
[
class
.
ti-btn-soft-secondary
]="
type
.
statusType =
=
'
Boss
'"
[
class
.
ti-btn-soft-warning
]="
type
.
statusType =
=
'
BossEvaluating
'"
[
class
.
ti-btn-soft-warning
]="
type
.
statusType =
=
'
BossEvaluating
'"
[
class
.
ti-btn-soft-success
]="
type
.
statusType =
=
'
Boss_finish
'"
[
class
.
ti-btn-soft-success
]="
type
.
statusType =
=
'
Boss_finish
'"
...
@@ -122,7 +121,6 @@
...
@@ -122,7 +121,6 @@
<div
class=
"flex justify-center"
>
<div
class=
"flex justify-center"
>
<button
type=
"button"
class=
"ti-btn rounded-sm"
<button
type=
"button"
class=
"ti-btn rounded-sm"
[
class
.
ti-btn-soft-mute
]="
item
.
statusIdp
.
statusType =
=
'
Not_evaluating_yet
'"
[
class
.
ti-btn-soft-mute
]="
item
.
statusIdp
.
statusType =
=
'
Not_evaluating_yet
'"
[
class
.
pointer-events-none
]="
item
.
statusIdp
.
statusType =
=
'
Not_evaluating_yet
'"
[
class
.
ti-btn-soft-secondary
]="
item
.
statusIdp
.
statusType =
=
'
Boss
'"
[
class
.
ti-btn-soft-secondary
]="
item
.
statusIdp
.
statusType =
=
'
Boss
'"
[
class
.
ti-btn-soft-warning
]="
item
.
statusIdp
.
statusType =
=
'
BossEvaluating
'"
[
class
.
ti-btn-soft-warning
]="
item
.
statusIdp
.
statusType =
=
'
BossEvaluating
'"
[
class
.
ti-btn-soft-success
]="
item
.
statusIdp
.
statusType =
=
'
Boss_finish
'"
[
class
.
ti-btn-soft-success
]="
item
.
statusIdp
.
statusType =
=
'
Boss_finish
'"
...
@@ -133,10 +131,13 @@
...
@@ -133,10 +131,13 @@
</div>
</div>
</td>
</td>
<td
class=
"text-center"
>
<td
class=
"text-center"
>
<!-- <button type="button" class="ti-btn rounded-sm ti-btn-soft-success"
<!-- <div class="flex justify-center">
style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;">
<button type="button" class="ti-btn rounded-sm ti-btn-soft-mute"
ประเมิน
style="height: 15px; width: 45px; font-size: 12px; display: flex; align-items: center; justify-content: center;margin-left:4px;"
</button> -->
(click)="selectSubordinate(item,'',subordinate.select?.evaluationRoundId);pageEvalution='pms'">
PMS
</button>
</div> -->
</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>
...
@@ -244,7 +245,10 @@
...
@@ -244,7 +245,10 @@
[
evaluateeId
]="
formEvaluation
.
evaluateeId
"
></app-idp-evalution>
[
evaluateeId
]="
formEvaluation
.
evaluateeId
"
></app-idp-evalution>
</ng-container>
</ng-container>
<ng-container
*
ngIf=
"pageEvalution=='pms'"
>
<ng-container
*
ngIf=
"pageEvalution=='pms'"
>
<app-pms-evalution
(
sendPageEvalution
)="
pageEvalution=
$event"
></app-pms-evalution>
<app-pms-evalution
[
pathTitle
]="['การประเมินผล',
'ประเมินโดยหัวหน้า','ประเมิน']"
(
sendReturnPath
)="
getBossList
();
pageEvalution=
''
;
pathTitle =
['การประเมินผล',
'ประเมินโดยหัวหน้า']"
[
evaluationRoundId
]="
formEvaluation
.
evaluationRoundId
"
[
evaluaterId
]="
formEvaluation
.
evaluaterId
"
[
evaluateeId
]="
formEvaluation
.
evaluateeId
"
></app-pms-evalution>
</ng-container>
</ng-container>
<ng-container
*
ngIf=
"pageEvalution=='evaluation'"
>
<ng-container
*
ngIf=
"pageEvalution=='evaluation'"
>
<app-evaluation
[
pathTitle
]="['การประเมินผล',
'ประเมินโดยหัวหน้า','ประเมิน']"
<app-evaluation
[
pathTitle
]="['การประเมินผล',
'ประเมินโดยหัวหน้า','ประเมิน']"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment