Merge branch 'develop' of https://github.com/Frappet/bma-ehr-frontend into develop
This commit is contained in:
commit
9bbdddeb6d
15 changed files with 288 additions and 119 deletions
|
|
@ -42,7 +42,7 @@ const salary = ref<string>("");
|
||||||
const educationOld = ref<string>("");
|
const educationOld = ref<string>("");
|
||||||
const reason = ref<string>("");
|
const reason = ref<string>("");
|
||||||
const date = ref<Date | null>(null);
|
const date = ref<Date | null>(null);
|
||||||
|
const status = ref<string>("");
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
await fecthappointmentByid();
|
await fecthappointmentByid();
|
||||||
});
|
});
|
||||||
|
|
@ -61,7 +61,8 @@ const fecthappointmentByid = async () => {
|
||||||
title.value.organizationPositionOld = data.organizationPositionOld ?? "-";
|
title.value.organizationPositionOld = data.organizationPositionOld ?? "-";
|
||||||
title.value.positionLevelOld = data.positionLevelOld ?? "-";
|
title.value.positionLevelOld = data.positionLevelOld ?? "-";
|
||||||
title.value.positionTypeOld = data.positionTypeOld ?? "-";
|
title.value.positionTypeOld = data.positionTypeOld ?? "-";
|
||||||
|
status.value = data.status,
|
||||||
|
console.log("🚀 ~ file: Detail.vue:65 ~ .then ~ status:", status.value)
|
||||||
educationOld.value = data.educationOld;
|
educationOld.value = data.educationOld;
|
||||||
organizationPositionOld.value = data.organizationPositionOld;
|
organizationPositionOld.value = data.organizationPositionOld;
|
||||||
positionTypeOld.value = data.positionTypeOld;
|
positionTypeOld.value = data.positionTypeOld;
|
||||||
|
|
@ -71,6 +72,7 @@ const fecthappointmentByid = async () => {
|
||||||
// organization.value = data.organization; //ไม่มี
|
// organization.value = data.organization; //ไม่มี
|
||||||
reason.value = data.reason;
|
reason.value = data.reason;
|
||||||
date.value = data.positionDate;
|
date.value = data.positionDate;
|
||||||
|
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
messageError($q, e);
|
messageError($q, e);
|
||||||
|
|
@ -189,7 +191,8 @@ const getClass = (val: boolean) => {
|
||||||
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
||||||
</div>
|
</div>
|
||||||
<q-space />
|
<q-space />
|
||||||
<div class="q-gutter-sm" v-if="!edit">
|
<div v-if="status !== 'DONE' && status !== 'REPORT'" >
|
||||||
|
<div class="q-gutter-sm" v-if="!edit">
|
||||||
<q-btn outline color="primary" dense icon-right="mdi-file-edit-outline" class="q-px-sm" label="แก้ไข"
|
<q-btn outline color="primary" dense icon-right="mdi-file-edit-outline" class="q-px-sm" label="แก้ไข"
|
||||||
style="width: 80px" @click="edit = !edit" />
|
style="width: 80px" @click="edit = !edit" />
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -198,6 +201,10 @@ const getClass = (val: boolean) => {
|
||||||
<q-btn outline color="red" dense class="q-px-sm" label="ยกเลิก" style="width: 80px" @click="edit = !edit" />
|
<q-btn outline color="red" dense class="q-px-sm" label="ยกเลิก" style="width: 80px" @click="edit = !edit" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
<div class="col-12"><q-separator /></div>
|
<div class="col-12"><q-separator /></div>
|
||||||
<q-form ref="myForm">
|
<q-form ref="myForm">
|
||||||
<div class="row col-12 q-pa-md">
|
<div class="row col-12 q-pa-md">
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,7 @@ import DialogOrgTree from "@/modules/05_placement/components/AppointMent/Appoint
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
import { WeekNumberContainer } from "@fullcalendar/core/internal";
|
||||||
const mixin = useCounterMixin(); //เรียกฟังก์ชันกลาง
|
const mixin = useCounterMixin(); //เรียกฟังก์ชันกลาง
|
||||||
const {
|
const {
|
||||||
showLoader,
|
showLoader,
|
||||||
|
|
@ -53,6 +54,7 @@ const visibleColumns = ref<string[]>([
|
||||||
"fullname",
|
"fullname",
|
||||||
"organizationName",
|
"organizationName",
|
||||||
"birthday",
|
"birthday",
|
||||||
|
"createdAt",
|
||||||
"status",
|
"status",
|
||||||
]);
|
]);
|
||||||
const visibleColumns2 = ref<string[]>([
|
const visibleColumns2 = ref<string[]>([
|
||||||
|
|
@ -105,6 +107,8 @@ const fecthlistappointment = async () => {
|
||||||
positionNumber: e.positionNumber,
|
positionNumber: e.positionNumber,
|
||||||
positionPath: e.positionPath,
|
positionPath: e.positionPath,
|
||||||
status: status(e.status),
|
status: status(e.status),
|
||||||
|
createdAt:date2Thai(e.createdAt),
|
||||||
|
|
||||||
birthday: e.dateOfBirth == null ? "-" : date2Thai(e.dateOfBirth),
|
birthday: e.dateOfBirth == null ? "-" : date2Thai(e.dateOfBirth),
|
||||||
}));
|
}));
|
||||||
// console.log(rows.value);
|
// console.log(rows.value);
|
||||||
|
|
@ -169,8 +173,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
field: "organizationName",
|
field: "organizationName",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "birthday",
|
name: "birthday",
|
||||||
|
|
@ -181,6 +184,17 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "createdAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่ดำเนินการ",
|
||||||
|
sortable: true,
|
||||||
|
field: "createdAt",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
sort: (a, b) => (b.createdAt) - (a.createdAt)
|
||||||
|
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: "status",
|
name: "status",
|
||||||
align: "left",
|
align: "left",
|
||||||
|
|
@ -191,6 +205,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columns2 = ref<QTableProps["columns"]>([
|
const columns2 = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "no",
|
name: "no",
|
||||||
|
|
@ -239,6 +254,7 @@ const columns2 = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const openModalTree = (id: string) => {
|
const openModalTree = (id: string) => {
|
||||||
|
|
@ -390,7 +406,7 @@ const status = (val: string) => {
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
:rows="rows"
|
:rows="rows"
|
||||||
:filter="filterKeyword"
|
:filter="filterKeyword"
|
||||||
row-key="fullname"
|
row-key="citizenId"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
|
|
@ -469,11 +485,19 @@ const status = (val: string) => {
|
||||||
>
|
>
|
||||||
{{ props.row.birthday }}
|
{{ props.row.birthday }}
|
||||||
</q-td>
|
</q-td>
|
||||||
|
<q-td
|
||||||
|
key="createdAt"
|
||||||
|
:props="props"
|
||||||
|
@click="nextPage(props.row)"
|
||||||
|
>
|
||||||
|
{{ props.row.createdAt }}
|
||||||
|
</q-td>
|
||||||
<q-td key="status" :props="props" @click="nextPage(props.row)">
|
<q-td key="status" :props="props" @click="nextPage(props.row)">
|
||||||
{{ props.row.status }}
|
{{ props.row.status }}
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td auto-width>
|
<q-td auto-width>
|
||||||
<q-btn
|
<q-btn
|
||||||
|
v-if="props.row.status !== 'ส่งรายชื่อไปออกคำสั่ง' && props.row.status !== 'ออกคำสั่งแล้ว'"
|
||||||
icon="mdi-dots-vertical"
|
icon="mdi-dots-vertical"
|
||||||
size="12px"
|
size="12px"
|
||||||
color="grey-7"
|
color="grey-7"
|
||||||
|
|
|
||||||
|
|
@ -5,9 +5,7 @@ import { useRoute, useRouter } from "vue-router";
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
|
|
||||||
import type { ResponseTitle } from "@/modules/05_placement/interface/response/Receive";
|
import type { ResponseTitle } from "@/modules/05_placement/interface/response/Receive";
|
||||||
import type {
|
import type { ResponseDataDetail } from "@/modules/05_placement/interface/response/Transfer";
|
||||||
ResponseDataDetail,
|
|
||||||
} from "@/modules/05_placement/interface/response/Transfer";
|
|
||||||
import type { QTableProps, QForm } from "quasar";
|
import type { QTableProps, QForm } from "quasar";
|
||||||
|
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
|
|
@ -237,37 +235,43 @@ const getClass = (val: boolean) => {
|
||||||
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
||||||
</div>
|
</div>
|
||||||
<q-space />
|
<q-space />
|
||||||
<div class="q-gutter-sm" v-if="!edit">
|
<div
|
||||||
<q-btn
|
v-if="
|
||||||
outline
|
responseData.status !== 'DONE' && responseData.status !== 'REPORT'
|
||||||
color="primary"
|
"
|
||||||
dense
|
>
|
||||||
icon-right="mdi-file-edit-outline"
|
<div class="q-gutter-sm" v-if="!edit">
|
||||||
class="q-px-sm"
|
<q-btn
|
||||||
label="แก้ไข"
|
outline
|
||||||
style="width: 80px"
|
color="primary"
|
||||||
@click="edit = !edit"
|
dense
|
||||||
/>
|
icon-right="mdi-file-edit-outline"
|
||||||
</div>
|
class="q-px-sm"
|
||||||
<div class="q-gutter-sm" v-else>
|
label="แก้ไข"
|
||||||
<q-btn
|
style="width: 80px"
|
||||||
outline
|
@click="edit = !edit"
|
||||||
color="public"
|
/>
|
||||||
dense
|
</div>
|
||||||
class="q-px-sm"
|
<div class="q-gutter-sm" v-else>
|
||||||
label="บันทึก"
|
<q-btn
|
||||||
style="width: 80px"
|
outline
|
||||||
@click="clickEdit"
|
color="public"
|
||||||
/>
|
dense
|
||||||
<q-btn
|
class="q-px-sm"
|
||||||
outline
|
label="บันทึก"
|
||||||
color="red"
|
style="width: 80px"
|
||||||
dense
|
@click="clickEdit"
|
||||||
class="q-px-sm"
|
/>
|
||||||
label="ยกเลิก"
|
<q-btn
|
||||||
style="width: 80px"
|
outline
|
||||||
@click="(edit = !edit), fecthOther()"
|
color="red"
|
||||||
/>
|
dense
|
||||||
|
class="q-px-sm"
|
||||||
|
label="ยกเลิก"
|
||||||
|
style="width: 80px"
|
||||||
|
@click="(edit = !edit), fecthOther()"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12"><q-separator /></div>
|
<div class="col-12"><q-separator /></div>
|
||||||
|
|
|
||||||
|
|
@ -54,7 +54,7 @@ const visibleColumns = ref<string[]>([
|
||||||
"position",
|
"position",
|
||||||
"positionLevel",
|
"positionLevel",
|
||||||
"organizationPositionOld",
|
"organizationPositionOld",
|
||||||
|
"createdAt",
|
||||||
"statustext",
|
"statustext",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
|
@ -92,7 +92,7 @@ const fecthlistOthet = async () => {
|
||||||
// listRecevice.value = response;
|
// listRecevice.value = response;
|
||||||
console.log(response);
|
console.log(response);
|
||||||
rows.value = response.map((r: any) => ({
|
rows.value = response.map((r: any) => ({
|
||||||
createdAt: new Date(),
|
createdAt: date2Thai(r.createdAt),
|
||||||
date: new Date(),
|
date: new Date(),
|
||||||
firstName: r.firstname ?? "",
|
firstName: r.firstname ?? "",
|
||||||
personalId: r.id ?? "",
|
personalId: r.id ?? "",
|
||||||
|
|
@ -214,6 +214,15 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "createdAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่ดำเนินการ",
|
||||||
|
sortable: true,
|
||||||
|
field: "createdAt",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: "statustext",
|
name: "statustext",
|
||||||
align: "left",
|
align: "left",
|
||||||
|
|
@ -380,7 +389,7 @@ const status = (val: string) => {
|
||||||
color="add"
|
color="add"
|
||||||
icon="mdi-account-arrow-right"
|
icon="mdi-account-arrow-right"
|
||||||
>
|
>
|
||||||
<q-tooltip>ส่งไปออกคำสั่งรายการอื่นๆ</q-tooltip>
|
<q-tooltip>ประเภทคำสั่งรายการอื่นๆ</q-tooltip>
|
||||||
</q-btn>
|
</q-btn>
|
||||||
|
|
||||||
<q-space />
|
<q-space />
|
||||||
|
|
@ -472,11 +481,19 @@ const status = (val: string) => {
|
||||||
</q-tooltip> -->
|
</q-tooltip> -->
|
||||||
</div>
|
</div>
|
||||||
</q-td>
|
</q-td>
|
||||||
|
<q-td key="createdAt" :props="props">
|
||||||
|
{{ props.row.createdAt }}
|
||||||
|
</q-td>
|
||||||
<q-td key="statustext" :props="props">
|
<q-td key="statustext" :props="props">
|
||||||
{{ props.row.statustext }}
|
{{ props.row.statustext }}
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td key="statustext" :props="props">
|
|
||||||
|
<q-td auto-width>
|
||||||
<q-btn
|
<q-btn
|
||||||
|
v-if="
|
||||||
|
props.row.status !== 'DONE' &&
|
||||||
|
props.row.status !== 'REPORT'
|
||||||
|
"
|
||||||
flat
|
flat
|
||||||
round
|
round
|
||||||
class="text-red-14"
|
class="text-red-14"
|
||||||
|
|
@ -496,7 +513,7 @@ const status = (val: string) => {
|
||||||
|
|
||||||
<q-dialog v-model="modal">
|
<q-dialog v-model="modal">
|
||||||
<q-card style="width: 1200px; max-width: 80vw">
|
<q-card style="width: 1200px; max-width: 80vw">
|
||||||
<DialogHeader title="ส่งไปออกคำสั่งอื่นๆ" :close="clickClose" />
|
<DialogHeader title="ประเภทคำสั่งอื่นๆ" :close="clickClose" />
|
||||||
<q-separator />
|
<q-separator />
|
||||||
<q-card-section class="q-pt-none">
|
<q-card-section class="q-pt-none">
|
||||||
<div class="row justify-between">
|
<div class="row justify-between">
|
||||||
|
|
|
||||||
|
|
@ -45,6 +45,8 @@ const visibleColumns = ref<string[]>([
|
||||||
"fullname",
|
"fullname",
|
||||||
"organizationName",
|
"organizationName",
|
||||||
"dateOfBirth",
|
"dateOfBirth",
|
||||||
|
"createdAt",
|
||||||
|
"statusText",
|
||||||
"btn",
|
"btn",
|
||||||
]);
|
]);
|
||||||
const visibleColumns2 = ref<string[]>([
|
const visibleColumns2 = ref<string[]>([
|
||||||
|
|
@ -113,6 +115,25 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "createdAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่ดำเนินการ",
|
||||||
|
sortable: true,
|
||||||
|
field: "createdAt",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
name: "statusText",
|
||||||
|
align: "left",
|
||||||
|
label: "สถานะ",
|
||||||
|
sortable: true,
|
||||||
|
field: "statusText",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: "btn",
|
name: "btn",
|
||||||
align: "left",
|
align: "left",
|
||||||
|
|
@ -238,7 +259,7 @@ const getData = async () => {
|
||||||
positionLevelOld: item.positionLevelOld,
|
positionLevelOld: item.positionLevelOld,
|
||||||
positionNumberOld: item.positionNumberOld,
|
positionNumberOld: item.positionNumberOld,
|
||||||
organizationPositionOld: item.organizationPositionOld,
|
organizationPositionOld: item.organizationPositionOld,
|
||||||
createdAt: item.createdAt,
|
createdAt:date2Thai(item.createdAt),
|
||||||
}));
|
}));
|
||||||
console.log(rows.value);
|
console.log(rows.value);
|
||||||
})
|
})
|
||||||
|
|
@ -449,6 +470,13 @@ onMounted(async () => {
|
||||||
props.row.dateOfBirth !== null ? props.row.dateOfBirth : "-"
|
props.row.dateOfBirth !== null ? props.row.dateOfBirth : "-"
|
||||||
}}
|
}}
|
||||||
</q-td>
|
</q-td>
|
||||||
|
<q-td
|
||||||
|
key="createdAt"
|
||||||
|
:props="props"
|
||||||
|
@click="openDetail(props.row.id)"
|
||||||
|
>
|
||||||
|
{{ props.row.createdAt }}
|
||||||
|
</q-td>
|
||||||
<q-td
|
<q-td
|
||||||
key="organizationPositionOld"
|
key="organizationPositionOld"
|
||||||
:props="props"
|
:props="props"
|
||||||
|
|
@ -486,6 +514,7 @@ onMounted(async () => {
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td auto-width>
|
<q-td auto-width>
|
||||||
<q-btn
|
<q-btn
|
||||||
|
v-if="props.row.status !== 'DONE' && props.row.status !== 'REPORT'"
|
||||||
icon="mdi-dots-vertical"
|
icon="mdi-dots-vertical"
|
||||||
size="12px"
|
size="12px"
|
||||||
color="grey-7"
|
color="grey-7"
|
||||||
|
|
|
||||||
|
|
@ -294,7 +294,7 @@ onMounted(async () => {
|
||||||
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
||||||
</div>
|
</div>
|
||||||
<q-space />
|
<q-space />
|
||||||
<div class="q-gutter-sm" v-if="!edit">
|
<div v-if="status !== 'REPORT' && status !== 'DONE'"> <div class="q-gutter-sm" v-if="!edit">
|
||||||
<q-btn
|
<q-btn
|
||||||
outline
|
outline
|
||||||
color="primary"
|
color="primary"
|
||||||
|
|
@ -325,7 +325,8 @@ onMounted(async () => {
|
||||||
style="width: 80px"
|
style="width: 80px"
|
||||||
@click="cancelBtn"
|
@click="cancelBtn"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div></div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12"><q-separator /></div>
|
<div class="col-12"><q-separator /></div>
|
||||||
<q-form ref="myForm">
|
<q-form ref="myForm">
|
||||||
|
|
|
||||||
|
|
@ -43,6 +43,7 @@ const visibleColumns = ref<string[]>([
|
||||||
"position",
|
"position",
|
||||||
"positionLevel",
|
"positionLevel",
|
||||||
"organizationPositionOld",
|
"organizationPositionOld",
|
||||||
|
"createdAt",
|
||||||
"statustext",
|
"statustext",
|
||||||
]);
|
]);
|
||||||
const visibleColumns2 = ref<string[]>([
|
const visibleColumns2 = ref<string[]>([
|
||||||
|
|
@ -114,6 +115,15 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "createdAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่ดำเนินการ",
|
||||||
|
sortable: true,
|
||||||
|
field: "createdAt",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: "statustext",
|
name: "statustext",
|
||||||
align: "left",
|
align: "left",
|
||||||
|
|
@ -206,7 +216,7 @@ const getData = async () => {
|
||||||
let list: ResponseData[] = [];
|
let list: ResponseData[] = [];
|
||||||
data.map((r: ResponseData) => {
|
data.map((r: ResponseData) => {
|
||||||
list.push({
|
list.push({
|
||||||
createdAt: new Date(),
|
createdAt:date2Thai(r.createdAt),
|
||||||
date: new Date(),
|
date: new Date(),
|
||||||
firstName: r.firstName ?? "",
|
firstName: r.firstName ?? "",
|
||||||
id: r.id ?? "",
|
id: r.id ?? "",
|
||||||
|
|
@ -420,11 +430,19 @@ const saveOrder = async () => {
|
||||||
</q-tooltip> -->
|
</q-tooltip> -->
|
||||||
</div>
|
</div>
|
||||||
</q-td>
|
</q-td>
|
||||||
|
<q-td
|
||||||
|
key="createdAt"
|
||||||
|
:props="props"
|
||||||
|
@click="nextPage(props.row)"
|
||||||
|
>
|
||||||
|
{{ props.row.createdAt }}
|
||||||
|
</q-td>
|
||||||
<q-td key="statustext" :props="props">
|
<q-td key="statustext" :props="props">
|
||||||
{{ props.row.statustext }}
|
{{ props.row.statustext }}
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td auto-width>
|
<q-td auto-width>
|
||||||
<q-btn
|
<q-btn
|
||||||
|
v-if="props.row.status !=='DONE' && props.row.status !=='REPORT'"
|
||||||
dense
|
dense
|
||||||
size="12px"
|
size="12px"
|
||||||
flat
|
flat
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,8 @@
|
||||||
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
||||||
</div>
|
</div>
|
||||||
<q-space />
|
<q-space />
|
||||||
<div class="q-gutter-sm" v-if="!edit">
|
<div v-if="responseData.status !=='DONE' && responseData.status !=='REPORT'">
|
||||||
|
<div class="q-gutter-sm" v-if="!edit">
|
||||||
<q-btn
|
<q-btn
|
||||||
outline
|
outline
|
||||||
color="primary"
|
color="primary"
|
||||||
|
|
@ -103,7 +104,8 @@
|
||||||
style="width: 80px"
|
style="width: 80px"
|
||||||
@click="edit = !edit"
|
@click="edit = !edit"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div></div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12"><q-separator /></div>
|
<div class="col-12"><q-separator /></div>
|
||||||
<q-form ref="myForm">
|
<q-form ref="myForm">
|
||||||
|
|
|
||||||
|
|
@ -43,6 +43,7 @@ const visibleColumns = ref<string[]>([
|
||||||
"position",
|
"position",
|
||||||
"positionLevel",
|
"positionLevel",
|
||||||
"organizationPositionOld",
|
"organizationPositionOld",
|
||||||
|
"createdAt",
|
||||||
"statustext",
|
"statustext",
|
||||||
]);
|
]);
|
||||||
const visibleColumns2 = ref<string[]>([
|
const visibleColumns2 = ref<string[]>([
|
||||||
|
|
@ -114,6 +115,15 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "createdAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่ดำเนินการ",
|
||||||
|
sortable: true,
|
||||||
|
field: "createdAt",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: "statustext",
|
name: "statustext",
|
||||||
align: "left",
|
align: "left",
|
||||||
|
|
@ -206,7 +216,7 @@ const getData = async () => {
|
||||||
let list: ResponseData[] = [];
|
let list: ResponseData[] = [];
|
||||||
data.map((r: ResponseData) => {
|
data.map((r: ResponseData) => {
|
||||||
list.push({
|
list.push({
|
||||||
createdAt: new Date(),
|
createdAt:date2Thai(r.createdAt),
|
||||||
date: new Date(),
|
date: new Date(),
|
||||||
firstName: r.firstName ?? "",
|
firstName: r.firstName ?? "",
|
||||||
id: r.id ?? "",
|
id: r.id ?? "",
|
||||||
|
|
@ -420,11 +430,19 @@ const saveOrder = async () => {
|
||||||
</q-tooltip> -->
|
</q-tooltip> -->
|
||||||
</div>
|
</div>
|
||||||
</q-td>
|
</q-td>
|
||||||
|
<q-td
|
||||||
|
key="createdAt"
|
||||||
|
:props="props"
|
||||||
|
|
||||||
|
>
|
||||||
|
{{ props.row.createdAt }}
|
||||||
|
</q-td>
|
||||||
<q-td key="statustext" :props="props">
|
<q-td key="statustext" :props="props">
|
||||||
{{ props.row.statustext }}
|
{{ props.row.statustext }}
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td auto-width>
|
<q-td auto-width>
|
||||||
<q-btn
|
<q-btn
|
||||||
|
v-if="props.row.status !== 'DONE' && props.row.status !== 'REPORT'"
|
||||||
dense
|
dense
|
||||||
size="12px"
|
size="12px"
|
||||||
flat
|
flat
|
||||||
|
|
|
||||||
|
|
@ -72,37 +72,43 @@
|
||||||
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
||||||
</div>
|
</div>
|
||||||
<q-space />
|
<q-space />
|
||||||
<div class="q-gutter-sm" v-if="!edit">
|
<div
|
||||||
<q-btn
|
v-if="
|
||||||
outline
|
responseData.status !== 'DONE' && responseData.status !== 'REPORT'
|
||||||
color="primary"
|
"
|
||||||
dense
|
>
|
||||||
icon-right="mdi-file-edit-outline"
|
<div class="q-gutter-sm" v-if="!edit">
|
||||||
class="q-px-sm"
|
<q-btn
|
||||||
label="แก้ไข"
|
outline
|
||||||
style="width: 80px"
|
color="primary"
|
||||||
@click="edit = !edit"
|
dense
|
||||||
/>
|
icon-right="mdi-file-edit-outline"
|
||||||
</div>
|
class="q-px-sm"
|
||||||
<div class="q-gutter-sm" v-else>
|
label="แก้ไข"
|
||||||
<q-btn
|
style="width: 80px"
|
||||||
outline
|
@click="edit = !edit"
|
||||||
color="public"
|
/>
|
||||||
dense
|
</div>
|
||||||
class="q-px-sm"
|
<div class="q-gutter-sm" v-else>
|
||||||
label="บันทึก"
|
<q-btn
|
||||||
style="width: 80px"
|
outline
|
||||||
@click="conditionSave"
|
color="public"
|
||||||
/>
|
dense
|
||||||
<q-btn
|
class="q-px-sm"
|
||||||
outline
|
label="บันทึก"
|
||||||
color="red"
|
style="width: 80px"
|
||||||
dense
|
@click="conditionSave"
|
||||||
class="q-px-sm"
|
/>
|
||||||
label="ยกเลิก"
|
<q-btn
|
||||||
style="width: 80px"
|
outline
|
||||||
@click="edit = !edit"
|
color="red"
|
||||||
/>
|
dense
|
||||||
|
class="q-px-sm"
|
||||||
|
label="ยกเลิก"
|
||||||
|
style="width: 80px"
|
||||||
|
@click="edit = !edit"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12"><q-separator /></div>
|
<div class="col-12"><q-separator /></div>
|
||||||
|
|
@ -234,6 +240,7 @@
|
||||||
:outlined="edit"
|
:outlined="edit"
|
||||||
dense
|
dense
|
||||||
lazy-rules
|
lazy-rules
|
||||||
|
:readonly="!edit"
|
||||||
:borderless="!edit"
|
:borderless="!edit"
|
||||||
:model-value="date !== null ? date2Thai(date) : null"
|
:model-value="date !== null ? date2Thai(date) : null"
|
||||||
:rules="[(val) => !!val || `${'กรุณาเลือกตั้งแต่วัน'}`]"
|
:rules="[(val) => !!val || `${'กรุณาเลือกตั้งแต่วัน'}`]"
|
||||||
|
|
@ -383,7 +390,7 @@ const getData = async () => {
|
||||||
.get(config.API.outByid(dataId))
|
.get(config.API.outByid(dataId))
|
||||||
.then((res: any) => {
|
.then((res: any) => {
|
||||||
const data = res.data.result;
|
const data = res.data.result;
|
||||||
|
|
||||||
responseData.value.personId = data.profileId;
|
responseData.value.personId = data.profileId;
|
||||||
responseData.value.createdAt = data.createdAt;
|
responseData.value.createdAt = data.createdAt;
|
||||||
responseData.value.date =
|
responseData.value.date =
|
||||||
|
|
|
||||||
|
|
@ -43,6 +43,7 @@ const visibleColumns = ref<string[]>([
|
||||||
"position",
|
"position",
|
||||||
"positionLevel",
|
"positionLevel",
|
||||||
"organizationPositionOld",
|
"organizationPositionOld",
|
||||||
|
"createdAt",
|
||||||
"statustext",
|
"statustext",
|
||||||
]);
|
]);
|
||||||
const visibleColumns2 = ref<string[]>([
|
const visibleColumns2 = ref<string[]>([
|
||||||
|
|
@ -114,6 +115,15 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "createdAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่ดำเนินการ",
|
||||||
|
sortable: true,
|
||||||
|
field: "createdAt",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: "statustext",
|
name: "statustext",
|
||||||
align: "left",
|
align: "left",
|
||||||
|
|
@ -206,7 +216,7 @@ const getData = async () => {
|
||||||
let list: ResponseData[] = [];
|
let list: ResponseData[] = [];
|
||||||
data.map((r: ResponseData) => {
|
data.map((r: ResponseData) => {
|
||||||
list.push({
|
list.push({
|
||||||
createdAt: new Date(),
|
createdAt:date2Thai(r.createdAt),
|
||||||
date: new Date(),
|
date: new Date(),
|
||||||
firstName: r.firstName ?? "",
|
firstName: r.firstName ?? "",
|
||||||
id: r.id ?? "",
|
id: r.id ?? "",
|
||||||
|
|
@ -421,12 +431,20 @@ const saveOrder = async () => {
|
||||||
</q-tooltip> -->
|
</q-tooltip> -->
|
||||||
</div>
|
</div>
|
||||||
</q-td>
|
</q-td>
|
||||||
|
<q-td
|
||||||
|
key="createdAt"
|
||||||
|
:props="props"
|
||||||
|
|
||||||
|
>
|
||||||
|
{{ props.row.createdAt }}
|
||||||
|
</q-td>
|
||||||
<q-td key="statustext" :props="props">
|
<q-td key="statustext" :props="props">
|
||||||
{{ props.row.statustext }}
|
{{ props.row.statustext }}
|
||||||
</q-td>
|
</q-td>
|
||||||
|
|
||||||
<q-td auto-width>
|
<q-td auto-width>
|
||||||
<q-btn
|
<q-btn
|
||||||
|
v-if="props.row.status !== 'DONE' && props.row.status !=='REPORT'"
|
||||||
dense
|
dense
|
||||||
size="12px"
|
size="12px"
|
||||||
flat
|
flat
|
||||||
|
|
|
||||||
|
|
@ -72,37 +72,43 @@
|
||||||
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย
|
||||||
</div>
|
</div>
|
||||||
<q-space />
|
<q-space />
|
||||||
<div class="q-gutter-sm" v-if="!edit">
|
<div
|
||||||
<q-btn
|
v-if="
|
||||||
outline
|
responseData.status !== 'DONE' && responseData.status !== 'REPORT'
|
||||||
color="primary"
|
"
|
||||||
dense
|
>
|
||||||
icon-right="mdi-file-edit-outline"
|
<div class="q-gutter-sm" v-if="!edit">
|
||||||
class="q-px-sm"
|
<q-btn
|
||||||
label="แก้ไข"
|
outline
|
||||||
style="width: 80px"
|
color="primary"
|
||||||
@click="edit = !edit"
|
dense
|
||||||
/>
|
icon-right="mdi-file-edit-outline"
|
||||||
</div>
|
class="q-px-sm"
|
||||||
<div class="q-gutter-sm" v-else>
|
label="แก้ไข"
|
||||||
<q-btn
|
style="width: 80px"
|
||||||
outline
|
@click="edit = !edit"
|
||||||
color="public"
|
/>
|
||||||
dense
|
</div>
|
||||||
class="q-px-sm"
|
<div class="q-gutter-sm" v-else>
|
||||||
label="บันทึก"
|
<q-btn
|
||||||
style="width: 80px"
|
outline
|
||||||
@click="conditionSave"
|
color="public"
|
||||||
/>
|
dense
|
||||||
<q-btn
|
class="q-px-sm"
|
||||||
outline
|
label="บันทึก"
|
||||||
color="red"
|
style="width: 80px"
|
||||||
dense
|
@click="conditionSave"
|
||||||
class="q-px-sm"
|
/>
|
||||||
label="ยกเลิก"
|
<q-btn
|
||||||
style="width: 80px"
|
outline
|
||||||
@click="edit = !edit"
|
color="red"
|
||||||
/>
|
dense
|
||||||
|
class="q-px-sm"
|
||||||
|
label="ยกเลิก"
|
||||||
|
style="width: 80px"
|
||||||
|
@click="edit = !edit"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12"><q-separator /></div>
|
<div class="col-12"><q-separator /></div>
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ import config from "@/app.config";
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const { showLoader, hideLoader, messageError, success } = mixin;
|
const { showLoader, hideLoader, messageError, success ,date2Thai} = mixin;
|
||||||
|
|
||||||
const rows = ref<any>([]);
|
const rows = ref<any>([]);
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
|
|
@ -76,6 +76,15 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "createdAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่ดำเนินการ",
|
||||||
|
sortable: true,
|
||||||
|
field: "createdAt",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
},
|
||||||
]);
|
]);
|
||||||
const visibleColumns = ref<string[]>([
|
const visibleColumns = ref<string[]>([
|
||||||
"prefix",
|
"prefix",
|
||||||
|
|
@ -85,6 +94,7 @@ const visibleColumns = ref<string[]>([
|
||||||
"positionLevel",
|
"positionLevel",
|
||||||
"positionExecutive",
|
"positionExecutive",
|
||||||
"oc",
|
"oc",
|
||||||
|
"createdAt",
|
||||||
]);
|
]);
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
fectListDecased();
|
fectListDecased();
|
||||||
|
|
@ -104,6 +114,7 @@ const fectListDecased = async () => {
|
||||||
positionLevel: e.positionLevel,
|
positionLevel: e.positionLevel,
|
||||||
positionExecutive: e.positionExecutive,
|
positionExecutive: e.positionExecutive,
|
||||||
oc: e.organization,
|
oc: e.organization,
|
||||||
|
createdAt:date2Thai(e.createdAt),
|
||||||
}));
|
}));
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
|
|
@ -237,6 +248,13 @@ const nextPage = (id: string) => {
|
||||||
<q-td key="oc" :props="props">
|
<q-td key="oc" :props="props">
|
||||||
{{ props.row.oc }}
|
{{ props.row.oc }}
|
||||||
</q-td>
|
</q-td>
|
||||||
|
<q-td
|
||||||
|
key="createdAt"
|
||||||
|
:props="props"
|
||||||
|
@click="nextPage(props.row)"
|
||||||
|
>
|
||||||
|
{{ props.row.createdAt }}
|
||||||
|
</q-td>
|
||||||
</q-tr>
|
</q-tr>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:pagination="scope">
|
<template v-slot:pagination="scope">
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
interface ResponseData {
|
interface ResponseData {
|
||||||
createdAt: Date;
|
createdAt: any;
|
||||||
date: Date;
|
date: Date;
|
||||||
firstName: string;
|
firstName: string;
|
||||||
id: string;
|
id: string;
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
interface ResponseData {
|
interface ResponseData {
|
||||||
createdAt: Date;
|
createdAt: any;
|
||||||
date: Date;
|
date: Date;
|
||||||
firstName: string;
|
firstName: string;
|
||||||
id: string;
|
id: string;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue