edit name import
This commit is contained in:
parent
5552055d65
commit
cc5c44a5f6
3 changed files with 89 additions and 100 deletions
|
|
@ -2,17 +2,17 @@
|
||||||
* Router ขอโอน
|
* Router ขอโอน
|
||||||
*/
|
*/
|
||||||
|
|
||||||
const Main = () => import("@/modules/03_retire/views/Main.vue")
|
const MainRetire = () => import("@/modules/03_retire/views/main.vue")
|
||||||
|
|
||||||
const AddRetire = () => import("@/modules/03_retire/views/AddRetire.vue")
|
const AddRetire = () => import("@/modules/03_retire/views/addRetire.vue")
|
||||||
|
|
||||||
const ResultQuestionair = () => import("@/modules/03_retire/views/Result.vue")
|
const ResultQuestionair = () => import("@/modules/03_retire/views/result.vue")
|
||||||
|
|
||||||
export default [
|
export default [
|
||||||
{
|
{
|
||||||
path: "/retire",
|
path: "/retire",
|
||||||
name: "Retire",
|
name: "Retire",
|
||||||
component: Main,
|
component: MainRetire,
|
||||||
meta: {
|
meta: {
|
||||||
Auth: true,
|
Auth: true,
|
||||||
Key: [7],
|
Key: [7],
|
||||||
|
|
|
||||||
|
|
@ -2,31 +2,31 @@
|
||||||
* Router Checkin
|
* Router Checkin
|
||||||
*/
|
*/
|
||||||
|
|
||||||
const Checkin = () => import("@/modules/04_checkin/views/CheckIn.vue");
|
const Checkin = () => import("@/modules/04_checkin/views/Checkin.vue")
|
||||||
const History = () => import("@/modules/04_checkin/views/History.vue");
|
const History = () => import("@/modules/04_checkin/views/history.vue")
|
||||||
|
|
||||||
/* const Checkout = () => import("@/modules/04_checkin/views/Checkout.vue");
|
/* const Checkout = () => import("@/modules/04_checkin/views/Checkout.vue");
|
||||||
*/
|
*/
|
||||||
export default [
|
export default [
|
||||||
{
|
{
|
||||||
path: "/check-in",
|
path: "/check-in",
|
||||||
name: "Checkin",
|
name: "Checkin",
|
||||||
component: Checkin,
|
component: Checkin,
|
||||||
meta: {
|
meta: {
|
||||||
Auth: true,
|
Auth: true,
|
||||||
Key: [7],
|
Key: [7],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/check-in/history",
|
path: "/check-in/history",
|
||||||
name: "History",
|
name: "History",
|
||||||
component: History,
|
component: History,
|
||||||
meta: {
|
meta: {
|
||||||
Auth: true,
|
Auth: true,
|
||||||
Key: [7],
|
Key: [7],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
/* {
|
/* {
|
||||||
path: "/check-out",
|
path: "/check-out",
|
||||||
name: "Checkout",
|
name: "Checkout",
|
||||||
component: Checkout,
|
component: Checkout,
|
||||||
|
|
@ -35,4 +35,4 @@ export default [
|
||||||
Key: [7],
|
Key: [7],
|
||||||
},
|
},
|
||||||
}, */
|
}, */
|
||||||
];
|
]
|
||||||
|
|
|
||||||
|
|
@ -1,37 +1,29 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="col-12 row justify-center">
|
<div class="col-12 row justify-center">
|
||||||
<div class="col-xs-12 col-sm-12 col-md-11 ">
|
<div class="col-xs-12 col-sm-12 col-md-11">
|
||||||
<q-card flat class="row col-12 cardNone" >
|
<q-card flat class="row col-12 cardNone">
|
||||||
<div class="bg-secondary text-white col-12 row items-center q-px-md q-py-sm">
|
<div class="bg-secondary text-white col-12 row items-center q-px-md q-py-sm">
|
||||||
<div class="col-2">
|
<div class="col-2">
|
||||||
<q-btn
|
<q-btn icon="mdi-arrow-left" unelevated round dense flat color="white" @click="router.go(-1)" />
|
||||||
icon="mdi-arrow-left"
|
</div>
|
||||||
unelevated
|
<q-space />
|
||||||
round
|
<span class="text-body1 text-weight-bold col-8 text-center">ประวัติการลงเวลา</span>
|
||||||
dense
|
<div class="col-2"></div>
|
||||||
flat
|
</div>
|
||||||
color="white"
|
<div class="col-12 q-pa-md text-grey-9">
|
||||||
@click="router.go(-1)"
|
<Table
|
||||||
/>
|
:style="$q.screen.gt.xs ? 'max-height: 64vh' : ''"
|
||||||
</div>
|
:rows="rows"
|
||||||
<q-space />
|
:columns="columns"
|
||||||
<span class="text-body1 text-weight-bold col-8 text-center">ประวัติการลงเวลา</span>
|
:filter="filter"
|
||||||
<div class="col-2"></div>
|
:visible-columns="visibleColumns"
|
||||||
</div>
|
v-model:inputfilter="filter"
|
||||||
<div class="col-12 q-pa-md text-grey-9">
|
v-model:inputvisible="visibleColumns"
|
||||||
<Table
|
:pagination="initialPagination"
|
||||||
:style="$q.screen.gt.xs ? 'max-height: 64vh' : ''"
|
:inputShow="false"
|
||||||
:rows="rows"
|
:grid="$q.screen.gt.xs ? false : true"
|
||||||
:columns="columns"
|
>
|
||||||
:filter="filter"
|
<template #columns="props">
|
||||||
:visible-columns="visibleColumns"
|
|
||||||
v-model:inputfilter="filter"
|
|
||||||
v-model:inputvisible="visibleColumns"
|
|
||||||
:pagination="initialPagination"
|
|
||||||
:inputShow="false"
|
|
||||||
:grid="$q.screen.gt.xs ? false : true"
|
|
||||||
>
|
|
||||||
<template #columns="props">
|
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
<q-td key="no" :props="props">
|
<q-td key="no" :props="props">
|
||||||
{{ props.rowIndex + 1 }}
|
{{ props.rowIndex + 1 }}
|
||||||
|
|
@ -48,49 +40,46 @@
|
||||||
<q-td key="out" :props="props">
|
<q-td key="out" :props="props">
|
||||||
{{ props.row.out }}
|
{{ props.row.out }}
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td key="loOut" :props="props">
|
<q-td key="loOut" :props="props">
|
||||||
{{ props.row.loOut }}
|
{{ props.row.loOut }}
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td key="status" :props="props">
|
<q-td key="status" :props="props">
|
||||||
<span :class="props.row.status == 'ลงเวลาเรียบร้อย' ? 'text-blue': 'text-orange'">{{ props.row.status }}</span>
|
<span :class="props.row.status == 'ลงเวลาเรียบร้อย' ? 'text-blue' : 'text-orange'">{{ props.row.status }}</span>
|
||||||
</q-td>
|
</q-td>
|
||||||
</q-tr>
|
</q-tr>
|
||||||
</template>
|
</template>
|
||||||
<template #item="props">
|
<template #item="props">
|
||||||
<div
|
<div class="q-pa-xs col-xs-12 col-sm-6 col-md-4 col-lg-3 grid-style-transition">
|
||||||
class="q-pa-xs col-xs-12 col-sm-6 col-md-4 col-lg-3 grid-style-transition"
|
<q-card bordered flat class="q-py-sm shadow-0">
|
||||||
>
|
<q-list dense>
|
||||||
<q-card bordered flat class="q-py-sm shadow-0">
|
<q-item v-for="col in props.cols" :key="col.name" :props="props">
|
||||||
<q-list dense>
|
<q-item-section>
|
||||||
<q-item v-for="col in props.cols" :key="col.name" :props="props">
|
<q-item-label caption>{{ col.label }}</q-item-label>
|
||||||
<q-item-section>
|
</q-item-section>
|
||||||
<q-item-label caption>{{ col.label }}</q-item-label>
|
<q-item-section side>
|
||||||
</q-item-section>
|
<q-item-label>
|
||||||
<q-item-section side >
|
<span v-if="col.name == 'status'" :class="props.row.status == 'ลงเวลาเรียบร้อย' ? 'text-blue' : 'text-orange'">{{ col.value }}</span>
|
||||||
<q-item-label>
|
<span v-else class="text-black">{{ col.value }}</span>
|
||||||
<span v-if="col.name == 'status'" :class="props.row.status == 'ลงเวลาเรียบร้อย' ? 'text-blue': 'text-orange'">{{ col.value }}</span>
|
</q-item-label>
|
||||||
<span v-else class="text-black">{{ col.value }}</span>
|
</q-item-section>
|
||||||
</q-item-label>
|
</q-item>
|
||||||
</q-item-section>
|
</q-list>
|
||||||
</q-item>
|
</q-card>
|
||||||
</q-list>
|
</div>
|
||||||
|
</template>
|
||||||
</q-card>
|
</Table>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</q-card>
|
||||||
</Table>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</q-card>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import type { QTableProps } from "quasar";
|
import type { QTableProps } from "quasar"
|
||||||
import { ref } from "vue";
|
import { ref } from "vue"
|
||||||
import { useRouter } from "vue-router";
|
import { useRouter } from "vue-router"
|
||||||
import Table from "@/modules/04_checkin/componenst/TableHistory.vue"
|
import Table from "@/modules/04_checkin/componenst/tableHistory.vue"
|
||||||
|
|
||||||
const router = useRouter();
|
const router = useRouter()
|
||||||
|
|
||||||
const filter = ref<string>("")
|
const filter = ref<string>("")
|
||||||
const visibleColumns = ref<String[]>(["date", "in", "loIn", "out", "loOut", "status"])
|
const visibleColumns = ref<String[]>(["date", "in", "loIn", "out", "loOut", "status"])
|
||||||
|
|
@ -131,7 +120,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "out",
|
name: "out",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "เวลาออกงาน",
|
label: "เวลาออกงาน",
|
||||||
|
|
@ -160,10 +149,10 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
},
|
},
|
||||||
])
|
])
|
||||||
const rows = ref<any>([
|
const rows = ref<any>([
|
||||||
{no:'1',date: '13/08/66',in: '11:20',loIn: 'สำนักงาน ก.ก ', out: '',loOut: '',status: '' },
|
{ no: "1", date: "13/08/66", in: "11:20", loIn: "สำนักงาน ก.ก ", out: "", loOut: "", status: "" },
|
||||||
{no:'2',date: '12/08/66',in: '08:04',loIn: 'สำนักงาน ก.ก ', out: '17:01',loOut: 'สำนักงาน ก.ก ',status: 'ลงเวลาเรียบร้อย' },
|
{ no: "2", date: "12/08/66", in: "08:04", loIn: "สำนักงาน ก.ก ", out: "17:01", loOut: "สำนักงาน ก.ก ", status: "ลงเวลาเรียบร้อย" },
|
||||||
{no:'3',date: '11/08/66',in: '08:34',loIn: 'สำนักงาน ก.ก ', out: '17:36',loOut: 'สำนักงาน ก.ก ',status: 'สาย ทำงานครบ' },
|
{ no: "3", date: "11/08/66", in: "08:34", loIn: "สำนักงาน ก.ก ", out: "17:36", loOut: "สำนักงาน ก.ก ", status: "สาย ทำงานครบ" },
|
||||||
{no:'4',date: '10/08/66',in: '08:48',loIn: 'สำนักงาน ก.ก ', out: '17:00',loOut: 'สำนักงาน ก.ก ',status: 'สาย ทำงานไม่ครบ' },
|
{ no: "4", date: "10/08/66", in: "08:48", loIn: "สำนักงาน ก.ก ", out: "17:00", loOut: "สำนักงาน ก.ก ", status: "สาย ทำงานไม่ครบ" },
|
||||||
])
|
])
|
||||||
const initialPagination = ref({
|
const initialPagination = ref({
|
||||||
rowsPerPage: 0,
|
rowsPerPage: 0,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue