convertStatus ประวัติการลงเวลา
This commit is contained in:
parent
6a825999ad
commit
ad1dd1becb
2 changed files with 8 additions and 4 deletions
|
|
@ -10,7 +10,7 @@ const { date2Thai } = mixin
|
|||
export const useChekIn = defineStore('checkin', () => {
|
||||
const year = ref<number>(new Date().getFullYear())
|
||||
const rows = ref<Datalist[]>()
|
||||
const tab = ref<string>('history')
|
||||
const tab = ref<string>('history')
|
||||
|
||||
/**
|
||||
* ฟังก์ชั่นสำหรับ map ข้อมูล เพื่อแสดงรายการในตารางประวัติการลงเวลา
|
||||
|
|
@ -44,14 +44,16 @@ export const useChekIn = defineStore('checkin', () => {
|
|||
*/
|
||||
function convertStatus(status: string) {
|
||||
switch (status) {
|
||||
case '':
|
||||
case 'ABSENT':
|
||||
return 'ขาดราชการ'
|
||||
case 'NORMAL':
|
||||
return 'ปกติ'
|
||||
case 'LATE':
|
||||
return 'สาย'
|
||||
case 'NOT_COMPLETE':
|
||||
return 'ปฏิบัติงานไม่ครบตามกำหนดเวลา'
|
||||
default:
|
||||
return ''
|
||||
return '-'
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -96,6 +98,6 @@ export const useChekIn = defineStore('checkin', () => {
|
|||
year,
|
||||
fetchHistoryList,
|
||||
classColorStatus,
|
||||
tab
|
||||
tab,
|
||||
}
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue