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
682153de
Commit
682153de
authored
Dec 26, 2024
by
LAPTOP-CV4JFSHE\kantavee
Browse files
Options
Browse Files
Download
Plain Diff
เเก้ชน
parents
6c297a2e
25b1613f
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
462 additions
and
5 deletions
+462
-5
competency-management.component.html
...ompetency-management/competency-management.component.html
+4
-0
competency-management.component.ts
.../competency-management/competency-management.component.ts
+2
-2
edit-group-competencies.component.html
...group-competencies/edit-group-competencies.component.html
+0
-0
edit-group-competencies.component.scss
...group-competencies/edit-group-competencies.component.scss
+119
-0
edit-group-competencies.component.ts
...t-group-competencies/edit-group-competencies.component.ts
+106
-0
group-competencies.component.html
...ment/group-competencies/group-competencies.component.html
+0
-0
group-competencies.component.scss
...ment/group-competencies/group-competencies.component.scss
+116
-0
group-competencies.component.ts
...gement/group-competencies/group-competencies.component.ts
+106
-0
dashboard-routing.module.ts
src/app/components/dashboard/dashboard-routing.module.ts
+2
-0
dashboard.module.ts
src/app/components/dashboard/dashboard.module.ts
+4
-0
competency-topic.component.html
...stration/competency-topic/competency-topic.component.html
+3
-3
No files found.
src/app/components/competency-management/competency-management.component.html
View file @
682153de
...
...
@@ -33,6 +33,10 @@
(
sendPathTitle
)="
pathTitle=
$event"
(
sendGroupShow
)="
groupShow=
$event"
></app-edit-group-indicators>
</div>
<div
id=
"underline-2"
role=
"tabpanel"
aria-labelledby=
"underline-item-2"
>
<app-group-competencies
*
ngIf=
"groupShow=='1'"
[
pathTitle
]="
pathTitle
"
(
sendPathTitle
)="
pathTitle=
$event"
(
sendGroupShow
)="
groupShow=
$event"
></app-group-competencies>
<app-edit-group-competencies
*
ngIf=
"groupShow=='2'"
[
pathTitle
]="
pathTitle
"
(
sendPathTitle
)="
pathTitle=
$event"
(
sendGroupShow
)="
groupShow=
$event"
></app-edit-group-competencies>
</div>
<div
id=
"underline-3"
role=
"tabpanel"
aria-labelledby=
"underline-item-3"
>
</div>
...
...
src/app/components/competency-management/competency-management.component.ts
View file @
682153de
...
...
@@ -6,6 +6,6 @@ import { Component } from '@angular/core';
styleUrls
:
[
'./competency-management.component.scss'
]
})
export
class
CompetencyManagementComponent
{
pathTitle
=
[
'การประเมินสมรรถนะ'
,
'การจัดการสมรรถนะ'
,
'ตัวชี้วัดและหลักสูตร'
]
;
groupShow
:
string
=
'1'
;
// Initialize groupShow property
pathTitle
=
[
'การประเมินสมรรถนะ'
,
'การจัดการสมรรถนะ'
,
'ตัวชี้วัดและหลักสูตร'
]
groupShow
=
'1'
}
src/app/components/competency-management/group-competencies/edit-group-competencies/edit-group-competencies.component.html
0 → 100644
View file @
682153de
This diff is collapsed.
Click to expand it.
src/app/components/competency-management/group-competencies/edit-group-competencies/edit-group-competencies.component.scss
0 → 100644
View file @
682153de
.button-clear
{
position
:
absolute
;
top
:
96px
;
z-index
:
1
;
right
:
41vw
;
}
.button-help
{
position
:
absolute
;
top
:
0px
;
z-index
:
1
;
right
:
0vw
;
margin
:
4
.2rem
;
margin-right
:
10px
;
/* เพิ่มใหม่ 12/16*/
}
table
.ti-custom-table
th
{
height
:
60px
;
}
table
.ti-custom-table
thead
{
height
:
50px
;
}
table
.ti-custom-table
thead
th
span
{
font-size
:
12px
;
font-weight
:
bold
;
}
a
.custom-link
{
padding
:
10px
40px
;
/* ปรับ padding ให้เพิ่มขนาด */
}
/* สไตล์ของแถบเมนู */
.nav-tabs
{
display
:
flex
;
width
:
100%
;
cursor
:
pointer
;
margin-bottom
:
10px
;
height
:
20%
;
}
.nav-item
{
list-style
:
none
;
margin-right
:
10px
;
/* ช่องว่างระหว่างเมนู */
}
.nav-link
{
text-decoration
:
none
;
padding
:
10px
20px
;
display
:
inline-block
;
font-size
:
large
;
border-width
:
2px
2px
0px
2px
;
border-style
:
solid
;
border-color
:
#ccc
;
border-radius
:
5px
5px
0px
0px
;
}
.nav-link
:hover
{
background-color
:
#f0f0f0
;
/* เปลี่ยนสีเมื่อ hover */
}
.nav-link.active
{
color
:
#ffffff
;
/* สีตัวอักษรในสถานะ active */
font-size
:
large
;
border-bottom
:
3
.5px
solid
rgb
(
var
(
--
color-primary
));
/* เส้นใต้ */
background-color
:
rgb
(
var
(
--
color-primary
));
border-width
:
2px
2px
0px
2px
;
border-style
:
solid
;
border-color
:
rgb
(
var
(
--
color-primary
));
border-radius
:
5px
5px
0px
0px
;
}
.tab-content
{
margin-top
:
20px
;
}
.tab-pane.active
{
display
:
block
;
}
.nav-item-text
{
list-style
:
none
;
margin-right
:
10px
;
/* ช่องว่างระหว่างเมนู */
}
.nav-link-text
{
text-decoration
:
none
;
display
:
inline-block
;
font-size
:
large
;
color
:
#569bf5
;
border-bottom
:
2px
solid
#569bf5
;
line-height
:
0
.8
;
}
.ti-pagination
.page-link.active
{
background-color
:
#569bf5
;
color
:
white
;
border-radius
:
50%
;
padding
:
8px
12px
;
}
.box-body
{
padding
:
0rem
;
}
.page
{
min-height
:
0vh
;
}
.ti-modal
{
overflow
:
hidden
;
}
.header-title-type
{
width
:
100%
;
min-height
:
50px
;
/* ใช้ min-height เพื่อให้มีความยืดหยุ่น */
// margin-top: 50px;
// margin-bottom: 16px;
justify-content
:
space-between
;
/* จัดเรียงองค์ประกอบภายใน */
align-items
:
center
;
/* จัดกลางแนวตั้ง */
padding-top
:
50px
;
padding-bottom
:
1rem
;
}
.bg-input-readonly
{
background-color
:
rgb
(
241
245
249
);
}
\ No newline at end of file
src/app/components/competency-management/group-competencies/edit-group-competencies/edit-group-competencies.component.ts
0 → 100644
View file @
682153de
import
{
Component
,
EventEmitter
,
Input
,
Output
}
from
'@angular/core'
;
import
{
ToastrService
}
from
'ngx-toastr'
;
@
Component
({
selector
:
'app-edit-group-competencies'
,
templateUrl
:
'./edit-group-competencies.component.html'
,
styleUrls
:
[
'./edit-group-competencies.component.scss'
]
})
export
class
EditGruopCompetenciesComponent
{
@
Input
()
pathTitle
=
[
'การประเมินสมรรถนะ'
,
'การจัดการสมรรถนะ'
,
'จัดกลุ่มสมรรถนะ'
];
@
Output
()
sendPathTitle
:
EventEmitter
<
string
[]
>
=
new
EventEmitter
<
string
[]
>
();
@
Output
()
sendGroupShow
:
EventEmitter
<
string
>
=
new
EventEmitter
<
string
>
();
activeTab
:
string
=
'tab1'
;
// กำหนด tab เริ่มต้น
// ฟังก์ชันในการเปลี่ยนแท็บ
changeTab
(
tab
:
{
id
:
string
,
text
:
string
})
{
this
.
sendPathTitle
.
emit
([
'การประเมินสมรรถนะ'
,
'การจัดการสมรรถนะ'
,
tab
.
text
]);
this
.
activeTab
=
tab
.
id
;
}
onBack
()
{
this
.
sendGroupShow
.
emit
(
'1'
);
// เปลี่ยนกลับไปหน้า 1
}
// การจัดการการเปิดปิด modal
modalOptions
:
{
[
nameModal
:
string
]:
{
isModalOpen
:
boolean
;
modalSize
:
string
;
backdropClose
:
boolean
;
};
}
=
{
"add"
:
{
isModalOpen
:
false
,
modalSize
:
'm'
,
backdropClose
:
true
,
},
"edit"
:
{
isModalOpen
:
false
,
modalSize
:
'm'
,
backdropClose
:
true
,
}
};
openModal
(
name
:
string
,
size
:
string
,
closeOnBackdrop
?:
boolean
)
{
this
.
modalOptions
[
name
].
modalSize
=
size
;
this
.
modalOptions
[
name
].
backdropClose
=
closeOnBackdrop
||
false
;
this
.
modalOptions
[
name
].
isModalOpen
=
true
;
this
.
currentModal
=
name
;
// ตั้งค่าค่าของ currentModal เป็น 'add' หรือ 'edit'
document
.
body
.
style
.
overflow
=
'hidden'
;
}
closeModal
(
name
:
string
)
{
this
.
modalOptions
[
name
].
isModalOpen
=
false
;
if
(
!
this
.
isAnyModalOpen
())
{
document
.
body
.
style
.
overflow
=
''
;
// คืนค่าการ Scroll เฉพาะเมื่อ Modal ทั้งหมดปิดแล้ว
}
}
isAnyModalOpen
():
boolean
{
return
Object
.
values
(
this
.
modalOptions
).
some
(
modal
=>
modal
.
isModalOpen
);
// ตรวจสอบว่า modal อื่นยังเปิดอยู่หรือไม่
}
// ฟังก์ชัน toggle checkbox
isChecked
:
boolean
=
false
;
// ใช้สำหรับตรวจสอบสถานะของ checkbox
toggleCheckbox
()
{
this
.
isChecked
=
!
this
.
isChecked
;
// สลับสถานะ
}
// ฟังก์ชันสำหรับการเพิ่ม ลบ หรือแก้ไข ข้อมูล
addUser
()
{
console
.
log
(
'เพิ่มผู้ใช้งาน'
);
}
deleteUser
()
{
console
.
log
(
'ลบผู้ใช้งาน'
);
}
editUser
()
{
console
.
log
(
'แก้ไขผู้ใช้งาน'
);
}
currentModal
=
""
;
constructor
(
private
toastr
:
ToastrService
)
{
}
showSuccess
()
{
this
.
toastr
.
success
(
'บันทึกข้อมูลสำเร็จ'
,
'เเจ้งเตือน'
,
{
timeOut
:
3000
,
positionClass
:
'toast-top-right'
,
});
}
showSuccessEdit
()
{
this
.
toastr
.
success
(
'เเก้ไขข้อมูลสำเร็จ'
,
'เเจ้งเตือน'
,
{
timeOut
:
3000
,
positionClass
:
'toast-top-right'
,
});
}
showSuccessDelete
()
{
this
.
toastr
.
success
(
'ลบข้อมูลสำเร็จ'
,
'เเจ้งเตือน'
,
{
timeOut
:
3000
,
positionClass
:
'toast-top-right'
,
});
}
}
src/app/components/competency-management/group-competencies/group-competencies.component.html
0 → 100644
View file @
682153de
This diff is collapsed.
Click to expand it.
src/app/components/competency-management/group-competencies/group-competencies.component.scss
0 → 100644
View file @
682153de
.button-clear
{
position
:
absolute
;
top
:
96px
;
z-index
:
1
;
right
:
41vw
;
}
.button-help
{
position
:
absolute
;
top
:
0px
;
z-index
:
1
;
right
:
0vw
;
margin
:
4
.2rem
;
margin-right
:
10px
;
/* เพิ่มใหม่ 12/16*/
}
table
.ti-custom-table
th
{
height
:
60px
;
}
table
.ti-custom-table
thead
{
height
:
50px
;
}
table
.ti-custom-table
thead
th
span
{
font-size
:
12px
;
font-weight
:
bold
;
}
a
.custom-link
{
padding
:
10px
40px
;
/* ปรับ padding ให้เพิ่มขนาด */
}
/* สไตล์ของแถบเมนู */
.nav-tabs
{
display
:
flex
;
width
:
100%
;
cursor
:
pointer
;
margin-bottom
:
10px
;
height
:
20%
;
}
.nav-item
{
list-style
:
none
;
margin-right
:
10px
;
/* ช่องว่างระหว่างเมนู */
}
.nav-link
{
text-decoration
:
none
;
padding
:
10px
20px
;
display
:
inline-block
;
font-size
:
large
;
border-width
:
2px
2px
0px
2px
;
border-style
:
solid
;
border-color
:
#ccc
;
border-radius
:
5px
5px
0px
0px
;
}
.nav-link
:hover
{
background-color
:
#f0f0f0
;
/* เปลี่ยนสีเมื่อ hover */
}
.nav-link.active
{
color
:
#ffffff
;
/* สีตัวอักษรในสถานะ active */
font-size
:
large
;
border-bottom
:
3
.5px
solid
rgb
(
var
(
--
color-primary
));
/* เส้นใต้ */
background-color
:
rgb
(
var
(
--
color-primary
));
border-width
:
2px
2px
0px
2px
;
border-style
:
solid
;
border-color
:
rgb
(
var
(
--
color-primary
));
border-radius
:
5px
5px
0px
0px
;
}
.tab-content
{
margin-top
:
20px
;
}
.tab-pane.active
{
display
:
block
;
}
.nav-item-text
{
list-style
:
none
;
margin-right
:
10px
;
/* ช่องว่างระหว่างเมนู */
}
.nav-link-text
{
text-decoration
:
none
;
display
:
inline-block
;
font-size
:
large
;
color
:
#569bf5
;
border-bottom
:
2px
solid
#569bf5
;
line-height
:
0
.8
;
}
.ti-pagination
.page-link.active
{
background-color
:
#569bf5
;
color
:
white
;
border-radius
:
50%
;
padding
:
8px
12px
;
}
.box-body
{
padding
:
0rem
;
}
.page
{
min-height
:
0vh
;
}
.ti-modal
{
overflow
:
hidden
;
}
.header-title-type
{
width
:
100%
;
min-height
:
50px
;
/* ใช้ min-height เพื่อให้มีความยืดหยุ่น */
// margin-top: 50px;
// margin-bottom: 16px;
justify-content
:
space-between
;
/* จัดเรียงองค์ประกอบภายใน */
align-items
:
center
;
/* จัดกลางแนวตั้ง */
padding-top
:
50px
;
padding-bottom
:
1rem
;
}
\ No newline at end of file
src/app/components/competency-management/group-competencies/group-competencies.component.ts
0 → 100644
View file @
682153de
import
{
Component
,
EventEmitter
,
Input
,
Output
}
from
'@angular/core'
;
import
{
ToastrService
}
from
'ngx-toastr'
;
@
Component
({
selector
:
'app-group-competencies'
,
templateUrl
:
'./group-competencies.component.html'
,
styleUrls
:
[
'./group-competencies.component.scss'
]
})
export
class
GruopCompetenciesComponent
{
@
Input
()
pathTitle
=
[
'การประเมินสมรรถนะ'
,
'การจัดการสมรรถนะ'
,
'จัดกลุ่มสมรรถนะ'
];
@
Output
()
sendPathTitle
:
EventEmitter
<
string
[]
>
=
new
EventEmitter
<
string
[]
>
();
@
Output
()
sendGroupShow
:
EventEmitter
<
string
>
=
new
EventEmitter
<
string
>
();
activeTab
:
string
=
'tab1'
;
// กำหนด tab เริ่มต้น
// ฟังก์ชันในการเปลี่ยนแท็บ
changeTab
(
tab
:
{
id
:
string
,
text
:
string
})
{
this
.
sendPathTitle
.
emit
([
'การประเมินสมรรถนะ'
,
'การจัดการสมรรถนะ'
,
tab
.
text
]);
this
.
activeTab
=
tab
.
id
;
}
onEdit
(){
this
.
sendGroupShow
.
emit
(
'2'
);
}
// การจัดการการเปิดปิด modal
modalOptions
:
{
[
nameModal
:
string
]:
{
isModalOpen
:
boolean
;
modalSize
:
string
;
backdropClose
:
boolean
;
};
}
=
{
"add"
:
{
isModalOpen
:
false
,
modalSize
:
'm'
,
backdropClose
:
true
,
},
"edit"
:
{
isModalOpen
:
false
,
modalSize
:
'm'
,
backdropClose
:
true
,
}
};
openModal
(
name
:
string
,
size
:
string
,
closeOnBackdrop
?:
boolean
)
{
this
.
modalOptions
[
name
].
modalSize
=
size
;
this
.
modalOptions
[
name
].
backdropClose
=
closeOnBackdrop
||
false
;
this
.
modalOptions
[
name
].
isModalOpen
=
true
;
this
.
currentModal
=
name
;
// ตั้งค่าค่าของ currentModal เป็น 'add' หรือ 'edit'
document
.
body
.
style
.
overflow
=
'hidden'
;
}
closeModal
(
name
:
string
)
{
this
.
modalOptions
[
name
].
isModalOpen
=
false
;
if
(
!
this
.
isAnyModalOpen
())
{
document
.
body
.
style
.
overflow
=
''
;
// คืนค่าการ Scroll เฉพาะเมื่อ Modal ทั้งหมดปิดแล้ว
}
}
isAnyModalOpen
():
boolean
{
return
Object
.
values
(
this
.
modalOptions
).
some
(
modal
=>
modal
.
isModalOpen
);
// ตรวจสอบว่า modal อื่นยังเปิดอยู่หรือไม่
}
// ฟังก์ชัน toggle checkbox
isChecked
:
boolean
=
false
;
// ใช้สำหรับตรวจสอบสถานะของ checkbox
toggleCheckbox
()
{
this
.
isChecked
=
!
this
.
isChecked
;
// สลับสถานะ
}
// ฟังก์ชันสำหรับการเพิ่ม ลบ หรือแก้ไข ข้อมูล
addUser
()
{
console
.
log
(
'เพิ่มผู้ใช้งาน'
);
}
deleteUser
()
{
console
.
log
(
'ลบผู้ใช้งาน'
);
}
editUser
()
{
console
.
log
(
'แก้ไขผู้ใช้งาน'
);
}
currentModal
=
""
;
constructor
(
private
toastr
:
ToastrService
)
{
}
showSuccess
()
{
this
.
toastr
.
success
(
'บันทึกข้อมูลสำเร็จ'
,
'เเจ้งเตือน'
,
{
timeOut
:
3000
,
positionClass
:
'toast-top-right'
,
});
}
showSuccessEdit
()
{
this
.
toastr
.
success
(
'เเก้ไขข้อมูลสำเร็จ'
,
'เเจ้งเตือน'
,
{
timeOut
:
3000
,
positionClass
:
'toast-top-right'
,
});
}
showSuccessDelete
()
{
this
.
toastr
.
success
(
'ลบข้อมูลสำเร็จ'
,
'เเจ้งเตือน'
,
{
timeOut
:
3000
,
positionClass
:
'toast-top-right'
,
});
}
}
src/app/components/dashboard/dashboard-routing.module.ts
View file @
682153de
...
...
@@ -20,6 +20,7 @@ import { ToolRegisterComponent } from '../tool-register/tool-register.component'
import
{
CompetencyManagementComponent
}
from
'../competency-management/competency-management.component'
;
import
{
JobDetailManagementComponent
}
from
'../job-detail-components/job-detail-management/job-detail-management.component'
;
import
{
CourseRegistrationComponent
}
from
'../course-registration/course-registration.component'
;
import
{
EditGruopCompetenciesComponent
}
from
'../competency-management/group-competencies/edit-group-competencies/edit-group-competencies.component'
;
const
routes
:
Routes
=
[
...
...
@@ -48,6 +49,7 @@ const routes: Routes = [
{
path
:
"competency-management"
,
title
:
'การจัดการสมรรถนะ'
,
component
:
CompetencyManagementComponent
},
{
path
:
"job-detail-management"
,
title
:
'การจัดการรายละเอียดงาน'
,
component
:
JobDetailManagementComponent
},
{
path
:
"course-registration"
,
title
:
'ทะเบียนหลักสูตร'
,
component
:
CourseRegistrationComponent
},
{
path
:
"edit-group-competencies"
,
title
:
'แก้ไขกลุ่มสมรรถนะ'
,
component
:
EditGruopCompetenciesComponent
},
]
}
];
...
...
src/app/components/dashboard/dashboard.module.ts
View file @
682153de
...
...
@@ -62,6 +62,8 @@ import { DevelopmentCourseComponent } from '../course-registration/development-c
import
{
IndicatorsAndCurriculumComponent
}
from
'../competency-management/indicators-and-curriculum/indicators-and-curriculum.component'
;
import
{
CourseRegistrationComponent
}
from
'../course-registration/course-registration.component'
;
import
{
EditGroupIndicators
}
from
'../competency-management/indicators-and-curriculum/edit-group-indicators/edit-group-indicators'
;
import
{
GruopCompetenciesComponent
}
from
'../competency-management/group-competencies/group-competencies.component'
;
import
{
EditGruopCompetenciesComponent
}
from
'../competency-management/group-competencies/edit-group-competencies/edit-group-competencies.component'
;
...
...
@@ -109,6 +111,8 @@ import { EditGroupIndicators } from '../competency-management/indicators-and-cur
DevelopmentCourseComponent
,
IndicatorsAndCurriculumComponent
,
EditGroupIndicators
,
GruopCompetenciesComponent
,
EditGruopCompetenciesComponent
,
],
imports
:
[
CommonModule
,
...
...
src/app/components/name-registration/competency-topic/competency-topic.component.html
View file @
682153de
...
...
@@ -209,7 +209,7 @@
<div
class=
"relative flex rounded-md w-1/2"
>
<input
type=
"text"
id=
"hs-leading-button-add-on-with-icon-and-button"
name=
"hs-leading-button-add-on-with-icon-and-button"
class=
"ti-form-input rounded-md ltr:rounded-r-md rtl:rounded-l-md focus:z-10"
style=
"padding-right: 2.5rem;"
>
<div
class=
"absolute inset-y-0 ltr:right-0 rtl:left-0 flex items-center z-20 ltr:pr-4 rtl:pl-4 space-x-2"
>
<button
type=
"button"
class=
"flex items-center text-gray-500 dark:text-white/70"
data-hs-overlay=
"#competency-topic-table-modal-
add
"
>
<button
type=
"button"
class=
"flex items-center text-gray-500 dark:text-white/70"
data-hs-overlay=
"#competency-topic-table-modal-
select
"
>
<i
class=
"ri-search-line cursor-pointer text-gray"
></i>
</button>
</div>
...
...
@@ -341,7 +341,7 @@
</div>
</div>
<div
id=
"competency-topic-table-modal-
add
"
class=
"hs-overlay hidden ti-modal"
>
<div
id=
"competency-topic-table-modal-
select
"
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"
>
<div
class=
"max-h-full overflow-hidden ti-modal-content"
>
<div
class=
"ti-modal-header"
>
...
...
@@ -379,7 +379,7 @@
</div>
<div
class=
"overflow-auto table-bordered"
style=
"border-radius: 5px;"
>
<div
class=
"overflow-auto border"
>
<table
class=
"ti-custom-table ti-custom-table-head"
>
<table
class=
"ti-custom-table ti-custom-table-head
ti-custom-table-hover
"
>
<thead>
<tr>
<ng-container
...
...
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