แก้ไขการแสดงผลประวัติการลงเวลา

This commit is contained in:
Warunee Tamkoo 2023-11-21 10:56:37 +07:00
parent 31e5cf13f9
commit a95c320cf5
3 changed files with 94 additions and 131 deletions

View file

@ -1,5 +1,4 @@
<script setup lang="ts">
import type { QTableProps } from 'quasar'
import { ref, onMounted } from 'vue'
import { useQuasar } from 'quasar'
import { useRouter } from 'vue-router'
@ -19,7 +18,6 @@ const { fetchHistoryList } = stores
const $q = useQuasar() // noti quasar
onMounted(() => {
// fetchlist()
fetchlistHistory()
})
@ -33,7 +31,7 @@ const filter = ref<string>('') //search data table
async function changePage(
pageVal: number,
pageSizeVal: number,
loading: boolean = false
loading: false
) {
page.value = await pageVal
pageSize.value = await pageSizeVal
@ -41,7 +39,7 @@ async function changePage(
}
//
const fetchlistHistory = async (loading: boolean = true) => {
const fetchlistHistory = async (loading = true) => {
loading === true ?? showLoader()
await http
.get(
@ -61,60 +59,6 @@ const fetchlistHistory = async (loading: boolean = true) => {
hideLoader()
})
}
// function fetchlist() {
// const listData = [
// {
// no: '1',
// date: '13/08/66',
// in: '11:20',
// loIn: ' . ',
// out: '',
// loOut: '',
// status: '',
// Morningstatus: '1',
// AfternoonStatus: '1',
// statusEdit: 'wait',
// },
// {
// no: '2',
// date: '12/08/66',
// in: '08:04',
// loIn: ' . ',
// out: '17:01',
// loOut: ' . ',
// status: '',
// Morningstatus: '2',
// AfternoonStatus: '2',
// statusEdit: 'edit',
// },
// {
// no: '3',
// date: '11/08/66',
// in: '08:34',
// loIn: ' . ',
// out: '17:36',
// loOut: ' . ',
// status: ' ',
// Morningstatus: '3',
// AfternoonStatus: '2',
// statusEdit: 'edit',
// },
// {
// no: '4',
// date: '10/08/66',
// in: '08:48',
// loIn: ' . ',
// out: '17:00',
// loOut: ' . ',
// status: ' ',
// Morningstatus: '3',
// AfternoonStatus: '3',
// statusEdit: 'approve',
// },
// ]
// stores.fetchHistoryList(listData)
// }
</script>
<template>
<div class="col-12 row justify-center">
@ -125,8 +69,7 @@ const fetchlistHistory = async (loading: boolean = true) => {
>
<div class="col-2">
<q-btn
icon="arrow_backt"
unelevated
icon="arrow_back"
round
dense
flat