Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
myAppraisal
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
myAppraisal
Commits
d1d043a6
Commit
d1d043a6
authored
Feb 18, 2025
by
Nattana Chaiyamat
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'DEV' of
https://mygit.myhr.co.th/angular/myAppraisal
into DEV
parents
ae904fcd
c71538b8
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
39 additions
and
15 deletions
+39
-15
sub-employee-registration.component.ts
...loyee-registration/sub-employee-registration.component.ts
+1
-1
set-approvers.component.ts
...tency-management/set-approvers/set-approvers.component.ts
+0
-2
dashboard.module.ts
src/app/components/dashboard/dashboard.module.ts
+1
-1
sub-job-competency.component.html
...ency/sub-job-competency/sub-job-competency.component.html
+0
-0
sub-job-competency.component.ts
...etency/sub-job-competency/sub-job-competency.component.ts
+29
-7
job-code.model.ts
src/app/shared/model/job-code.model.ts
+3
-0
job-code.service.ts
src/app/shared/services/job-code.service.ts
+5
-4
No files found.
src/app/components/company-components/employee-registration/sub-employee-registration/sub-employee-registration.component.ts
View file @
d1d043a6
...
...
@@ -16,7 +16,7 @@ import { FileService } from 'src/app/shared/services/file.service';
import
{
PLService
}
from
'src/app/shared/services/pl.service'
;
import
{
PositionService
}
from
'src/app/shared/services/position.service'
;
import
{
BranchService
}
from
'src/app/shared/services/่branch.service'
;
import
{
JobCodeService
}
from
'src/app/shared/services/
่
job-code.service'
;
import
{
JobCodeService
}
from
'src/app/shared/services/job-code.service'
;
export
interface
DataEmployee
{
loading
:
boolean
select
:
EmployeeModel
|
any
...
...
src/app/components/competency-assessment/competency-management/set-approvers/set-approvers.component.ts
View file @
d1d043a6
...
...
@@ -70,7 +70,6 @@ export class SetApproversComponent {
})
}
employee_listFilter
()
{
console
.
log
(
this
.
employee
)
return
this
.
employee_list
.
filter
(
x
=>
x
.
fname
.
toLowerCase
().
includes
(
this
.
search
.
toLowerCase
())
||
x
.
lname
.
toLowerCase
().
includes
(
this
.
search
.
toLowerCase
()))
}
...
...
@@ -116,7 +115,6 @@ export class SetApproversComponent {
this
.
page
=
Array
.
from
({
length
:
Math
.
ceil
(
this
.
groupapprove_listFilter
().
length
/
10
)
},
(
_
,
i
)
=>
i
+
1
);
}
groupapprove_listFilter
()
{
console
.
log
(
this
.
groupapprove
)
return
this
.
groupapprove_list
.
filter
(
x
=>
x
.
apsapprove1
.
employeeId
||
x
.
apsapprove2
.
employeeId
||
x
.
apsapprove3
.
employeeId
||
x
.
apsapprove4
.
employeeId
||
x
.
apsapprove5
.
employeeId
.
toLowerCase
().
includes
(
this
.
search
.
toLowerCase
())
||
x
.
apsapprove1
.
fname
||
x
.
apsapprove1
.
lname
.
toLowerCase
().
includes
(
this
.
search
.
toLowerCase
())
||
x
.
apsapprove2
.
fname
||
x
.
apsapprove2
.
lname
.
toLowerCase
().
includes
(
this
.
search
.
toLowerCase
())
||
...
...
src/app/components/dashboard/dashboard.module.ts
View file @
d1d043a6
...
...
@@ -129,7 +129,7 @@ import { MatInputModule } from '@angular/material/input';
import
{
DateAdapter
,
MAT_DATE_FORMATS
}
from
'@angular/material/core'
;
import
{
NativeDateAdapter
}
from
'@angular/material/core'
;
import
{
BranchService
}
from
'src/app/shared/services/่branch.service'
;
import
{
JobCodeService
}
from
'src/app/shared/services/
่
job-code.service'
;
import
{
JobCodeService
}
from
'src/app/shared/services/job-code.service'
;
import
{
FileService
}
from
'src/app/shared/services/file.service'
;
import
{
CompetencyGroupGradeService
}
from
'src/app/shared/services/competency-group-grade.service'
;
import
{
IndicatorsCoursesService
}
from
'src/app/shared/services/indicators-courses.service'
;
...
...
src/app/components/job-detail-components/job-competency/sub-job-competency/sub-job-competency.component.html
View file @
d1d043a6
This diff is collapsed.
Click to expand it.
src/app/components/job-detail-components/job-competency/sub-job-competency/sub-job-competency.component.ts
View file @
d1d043a6
...
...
@@ -3,7 +3,7 @@ import { ToastrService } from 'ngx-toastr';
import
{
JobCodeModel
,
MyJobCodeModel
}
from
'src/app/shared/model/job-code.model'
;
import
{
JobModel
,
MyJobModel
}
from
'src/app/shared/model/job.model'
;
import
{
FileService
}
from
'src/app/shared/services/file.service'
;
import
{
JobCodeService
}
from
'src/app/shared/services/
่
job-code.service'
;
import
{
JobCodeService
}
from
'src/app/shared/services/job-code.service'
;
@
Component
({
...
...
@@ -14,12 +14,16 @@ import { JobCodeService } from 'src/app/shared/services/่job-code.service';
export
class
SubJobCompetencyComponent
{
currentPage
=
1
page
=
Array
.
from
({
length
:
1
},
(
_
,
i
)
=>
i
+
1
);
pageSize
=
10
search
=
""
jobCodeList
:
JobCodeModel
[]
=
[]
loading
=
false
selectedFile
:
File
|
null
=
null
;
selectedFileName
:
string
=
'กรุณาเลือกไฟล์'
;
selectJob
:
JobCodeModel
=
new
MyJobCodeModel
({})
modalStatus
=
''
constructor
(
private
toastr
:
ToastrService
,
private
fileService
:
FileService
,
...
...
@@ -34,7 +38,7 @@ export class SubJobCompetencyComponent {
this
.
jobcodeService
.
getList
().
subscribe
({
next
:
response
=>
{
this
.
jobCodeList
=
response
.
map
((
x
:
any
)
=>
new
MyJobCodeModel
(
x
))
console
.
log
(
"🚀 ~ SubJobCompetencyComponent ~ this.jobcodeService.getList ~ this.jobCodeList:"
,
this
.
jobCodeList
)
this
.
jobCodeList
=
this
.
jobCodeList
.
sort
((
a
,
b
)
=>
a
.
jobcodeId
.
localeCompare
(
b
.
jobcodeId
)
)
this
.
loading
=
false
this
.
searchChange
()
this
.
cdr
.
detectChanges
()
...
...
@@ -47,9 +51,27 @@ export class SubJobCompetencyComponent {
searchChange
()
{
this
.
currentPage
=
1
this
.
page
=
Array
.
from
({
length
:
Math
.
ceil
(
this
.
jobcodeFilter
().
length
/
10
)
},
(
_
,
i
)
=>
i
+
1
);
this
.
page
=
Array
.
from
({
length
:
Math
.
ceil
(
this
.
jobcodeFilter
().
length
/
this
.
pageSize
)
},
(
_
,
i
)
=>
i
+
1
);
}
edit
(
item
:
JobCodeModel
){
this
.
selectJob
=
new
MyJobCodeModel
({})
this
.
selectJob
=
new
MyJobCodeModel
(
item
)
}
save
(){
this
.
jobcodeService
.
post
(
this
.
selectJob
).
subscribe
((
response
:
any
)
=>
{
if
(
response
.
success
)
{
this
.
showAlert
(
response
.
message
,
'success'
)
this
.
selectJob
=
new
MyJobCodeModel
({})
this
.
getListJob
();
}
else
{
this
.
showAlert
(
response
.
message
,
'error'
)
}
this
.
cdr
.
detectChanges
()
})
}
deleteCompany
(){
}
jobcodeFilter
()
{
return
this
.
jobCodeList
.
filter
(
x
=>
x
.
tdesc
.
toLowerCase
().
includes
(
this
.
search
.
toLowerCase
())
||
...
...
@@ -69,19 +91,19 @@ export class SubJobCompetencyComponent {
}
const
formData
=
new
FormData
();
formData
.
append
(
'file'
,
this
.
selectedFile
);
// this.bu3ListL
oading = true
this
.
l
oading
=
true
this
.
fileService
.
upload
(
formData
,
'MJOBCODE_COMPETENCY'
).
subscribe
({
next
:
response
=>
{
if
(
response
.
success
)
{
this
.
showAlert
(
response
.
message
,
'success'
)
// this.getBu3List()
this
.
getListJob
();
}
else
{
this
.
showAlert
(
response
.
message
,
'error'
)
// this.bu3ListL
oading = false
this
.
l
oading
=
false
}
},
error
:
error
=>
{
this
.
showAlert
(
error
.
message
,
'error'
)
// this.bu3ListL
oading = false
this
.
l
oading
=
false
}
})
}
...
...
src/app/shared/model/job-code.model.ts
View file @
d1d043a6
...
...
@@ -32,6 +32,7 @@ export interface JobCodeModel {
equalification
:
string
jobObjective
:
string
supervisor
:
string
competencyWorkText
:
string
}
export
class
MyJobCodeModel
implements
JobCodeModel
{
...
...
@@ -58,6 +59,7 @@ export class MyJobCodeModel implements JobCodeModel {
equalification
:
string
jobObjective
:
string
supervisor
:
string
competencyWorkText
:
string
constructor
(
data
:
Partial
<
JobCodeModel
>
)
{
this
.
jobcodeId
=
data
.
jobcodeId
||
""
this
.
tdesc
=
data
.
tdesc
||
""
...
...
@@ -82,6 +84,7 @@ export class MyJobCodeModel implements JobCodeModel {
this
.
equalification
=
data
.
equalification
||
""
this
.
jobObjective
=
data
.
jobObjective
||
""
this
.
supervisor
=
data
.
supervisor
||
""
this
.
competencyWorkText
=
data
.
competencyWorkText
||
""
}
}
src/app/shared/services/
่
job-code.service.ts
→
src/app/shared/services/job-code.service.ts
View file @
d1d043a6
import
{
HttpClient
,
HttpHeaders
}
from
'@angular/common/http'
;
import
{
HttpClient
,
HttpHeaders
}
from
'@angula
r/common/http'
;
...
...
@@ -3,6 +3,7 @@ import { Injectable } from '@angular/core';
import
{
Observable
}
from
'rxjs'
;
import
{
environment
}
from
'src/environments/environment'
;
import
{
JobCodeModel
}
from
'../model/job-code.model'
;
import
{
AlertModel
}
from
'../model/alert.model'
;
@
Injectable
({
providedIn
:
'root'
...
...
@@ -18,9 +19,9 @@ export class JobCodeService {
getById
(
jobcodeId
:
string
):
Observable
<
JobCodeModel
>
{
return
this
.
http
.
get
<
JobCodeModel
>
(
this
.
urlApi
+
"/"
+
jobcodeId
)
}
//
post(body: JobCodeModel): Observable<AlertModel> {
//
return this.http.post<AlertModel>(this.urlApi, body)
//
}
post
(
body
:
JobCodeModel
):
Observable
<
AlertModel
>
{
return
this
.
http
.
post
<
AlertModel
>
(
this
.
urlApi
,
body
)
}
// delete(body: JobCodeModel | JobCodeModel[]): Observable<AlertModel> {
// const options = {
// headers: new HttpHeaders({
...
...
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