ทะเบียนประวัติ ==> sort
This commit is contained in:
parent
ec57059dc3
commit
0e5e7ac5be
22 changed files with 194 additions and 72 deletions
|
|
@ -64,10 +64,9 @@ const visibleColumnsHistory = ref<string[]>([
|
||||||
"ethnicity",
|
"ethnicity",
|
||||||
"religion",
|
"religion",
|
||||||
"phone",
|
"phone",
|
||||||
"createdFullName",
|
"lastUpdateFullName",
|
||||||
"createdAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columnsHistory = ref<QTableProps["columns"]>([
|
const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "citizenId",
|
name: "citizenId",
|
||||||
|
|
@ -214,25 +213,25 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "createdFullName",
|
name: "lastUpdateFullName",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "ผู้ดำเนินการ",
|
label: "ผู้ดำเนินการ",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "createdFullName",
|
field: "lastUpdateFullName",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "createdAt",
|
name: "lastUpdatedAt",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -94,6 +94,9 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"prefix",
|
"prefix",
|
||||||
|
|
@ -309,6 +312,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -211,7 +211,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
@ -267,7 +267,7 @@ function getHistory() {
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
const data = res.data.result;
|
const data = res.data.result;
|
||||||
rowsHistory.value = data;
|
rowsHistory.value = data;
|
||||||
console.log("🚀 ~ .then ~ data:", data)
|
console.log("🚀 ~ .then ~ data:", data);
|
||||||
rowsHistoryData.value = data;
|
rowsHistoryData.value = data;
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ import DialogHistory from "@/modules/10_registry/Dialog/DialogHistory.vue";
|
||||||
const link = ref<string>("");
|
const link = ref<string>("");
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const { showLoader, hideLoader, messageError } = mixin;
|
const { showLoader, hideLoader, messageError, date2Thai } = mixin;
|
||||||
|
|
||||||
const idFamily = ref<string>("");
|
const idFamily = ref<string>("");
|
||||||
const store = useRegistryInFormationStore();
|
const store = useRegistryInFormationStore();
|
||||||
|
|
@ -67,6 +67,8 @@ const visibleColumnsHistory = ref<string[]>([
|
||||||
"job",
|
"job",
|
||||||
"isLive",
|
"isLive",
|
||||||
"lastNameOld",
|
"lastNameOld",
|
||||||
|
"lastUpdateFullName",
|
||||||
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
const columnsHistory = ref<QTableProps["columns"]>([
|
const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
|
|
@ -134,6 +136,29 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (val) => (val ? "มีชีวิต" : "ถึงแก่กรรม"),
|
format: (val) => (val ? "มีชีวิต" : "ถึงแก่กรรม"),
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "lastUpdateFullName",
|
||||||
|
align: "left",
|
||||||
|
label: "ผู้ดำเนินการ",
|
||||||
|
sortable: true,
|
||||||
|
field: "lastUpdateFullName",
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
sort: (a: string, b: string) =>
|
||||||
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: "lastUpdatedAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่แก้ไข",
|
||||||
|
sortable: true,
|
||||||
|
field: "lastUpdatedAt",
|
||||||
|
format: (v) => date2Thai(v, false, true),
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
sort: (a: string, b: string) =>
|
||||||
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
|
},
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const checkFatherData = ref<boolean>(false);
|
const checkFatherData = ref<boolean>(false);
|
||||||
|
|
@ -202,6 +227,8 @@ async function getData(type: string) {
|
||||||
|
|
||||||
/** get history */
|
/** get history */
|
||||||
function getHistory() {
|
function getHistory() {
|
||||||
|
rowsHistory.value = [];
|
||||||
|
rowsHistoryData.value = [];
|
||||||
const url =
|
const url =
|
||||||
dataStore.officerType == "OFFICER"
|
dataStore.officerType == "OFFICER"
|
||||||
? config.API.dataUserFamilyHistory(typeForm.value, "", idFamily.value)
|
? config.API.dataUserFamilyHistory(typeForm.value, "", idFamily.value)
|
||||||
|
|
@ -216,8 +243,8 @@ function getHistory() {
|
||||||
.get(url)
|
.get(url)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
const data = res.data.result;
|
const data = res.data.result;
|
||||||
const listData =
|
const listData = data.map((e: any) => ({
|
||||||
data.map((e: any) => ({
|
...e,
|
||||||
citizenId: e[`${typeForm.value}CitizenId`],
|
citizenId: e[`${typeForm.value}CitizenId`],
|
||||||
prefix: e[`${typeForm.value}Prefix`],
|
prefix: e[`${typeForm.value}Prefix`],
|
||||||
firstName: e[`${typeForm.value}FirstName`],
|
firstName: e[`${typeForm.value}FirstName`],
|
||||||
|
|
@ -227,8 +254,8 @@ function getHistory() {
|
||||||
lastNameOld:
|
lastNameOld:
|
||||||
typeForm.value === "couple" ? e.coupleLastNameOld : undefined,
|
typeForm.value === "couple" ? e.coupleLastNameOld : undefined,
|
||||||
}));
|
}));
|
||||||
rowsHistory.value = listData
|
rowsHistory.value = listData;
|
||||||
rowsHistoryData.value = listData
|
rowsHistoryData.value = listData;
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
messageError($q, e);
|
messageError($q, e);
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,6 @@ const visibleColumns = ref<string[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "educationLevel",
|
name: "educationLevel",
|
||||||
|
|
@ -237,13 +236,16 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const columnsHistory = ref<QTableProps["columns"]>([
|
const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
|
|
@ -434,14 +436,13 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"educationLevel",
|
"educationLevel",
|
||||||
"institute",
|
"institute",
|
||||||
|
|
@ -569,6 +570,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
@ -589,7 +591,7 @@ onMounted(async () => {
|
||||||
{{ props.row.status ? props.row.status : "-" }}
|
{{ props.row.status ? props.row.status : "-" }}
|
||||||
</div>
|
</div>
|
||||||
<div v-else>
|
<div v-else>
|
||||||
{{ col.value ? col.value:'-' }}
|
{{ col.value ? col.value : "-" }}
|
||||||
</div>
|
</div>
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td auto-width>
|
<q-td auto-width>
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,6 @@ const visibleColumns = ref<string[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "field",
|
name: "field",
|
||||||
|
|
@ -99,13 +98,16 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"field",
|
"field",
|
||||||
|
|
@ -177,7 +179,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
|
|
@ -290,6 +292,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -127,13 +127,16 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
function onHistory(id: string) {
|
function onHistory(id: string) {
|
||||||
modalHistory.value = true;
|
modalHistory.value = true;
|
||||||
|
|
@ -236,6 +239,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -83,7 +83,9 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a
|
||||||
|
.toString()
|
||||||
|
.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "status",
|
name: "status",
|
||||||
|
|
@ -124,13 +126,16 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"no",
|
"no",
|
||||||
|
|
@ -187,7 +192,9 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a
|
||||||
|
.toString()
|
||||||
|
.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "status",
|
name: "status",
|
||||||
|
|
@ -387,6 +394,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -22,7 +22,8 @@ const rowsHistoryData = ref<DutyFormType[]>([]);
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const mode = ref<any>($q.screen.gt.xs);
|
const mode = ref<any>($q.screen.gt.xs);
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const { showLoader, hideLoader, messageError, date2Thai,onSearchDataTable } = mixin;
|
const { showLoader, hideLoader, messageError, date2Thai, onSearchDataTable } =
|
||||||
|
mixin;
|
||||||
|
|
||||||
const modalHistory = ref<boolean>(false);
|
const modalHistory = ref<boolean>(false);
|
||||||
/** ตัวแปรข้อมูล */
|
/** ตัวแปรข้อมูล */
|
||||||
|
|
@ -126,11 +127,14 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"dateStart",
|
"dateStart",
|
||||||
|
|
@ -340,6 +344,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
import { useQuasar, type QTableProps } from "quasar";
|
import { useQuasar, type QTableProps } from "quasar";
|
||||||
import { ref, reactive, onMounted } from "vue";
|
import { ref, onMounted } from "vue";
|
||||||
|
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
|
@ -34,6 +34,7 @@ const visibleColumns = ref<String[]>([
|
||||||
"posNo",
|
"posNo",
|
||||||
"position",
|
"position",
|
||||||
"status",
|
"status",
|
||||||
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
|
|
@ -83,10 +84,25 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format(val, row) {
|
format(val, row) {
|
||||||
return row.status ? "Active" : "-";
|
return row.status ? "ใช้งาน" : "-";
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "lastUpdatedAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่แก้ไข",
|
||||||
|
sortable: true,
|
||||||
|
field: "lastUpdatedAt",
|
||||||
|
format: (v) => date2Thai(v, false, true),
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
sort: (a: string, b: string) =>
|
||||||
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"dateStart",
|
"dateStart",
|
||||||
|
|
@ -144,7 +160,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "status",
|
field: "status",
|
||||||
format(val, row) {
|
format(val, row) {
|
||||||
return row.status ? "Active" : "-";
|
return row.status ? "ใช้งาน" : "-";
|
||||||
},
|
},
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
|
@ -224,6 +240,7 @@ onMounted(async () => {
|
||||||
getData();
|
getData();
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<!-- v-if="mode" -->
|
<!-- v-if="mode" -->
|
||||||
<div class="col-12">
|
<div class="col-12">
|
||||||
|
|
@ -273,6 +290,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
@ -352,6 +370,7 @@ onMounted(async () => {
|
||||||
:columns="columnsHistory"
|
:columns="columnsHistory"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.absolute_button {
|
.absolute_button {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
import { useQuasar, type QTableProps } from "quasar";
|
import { useQuasar, type QTableProps } from "quasar";
|
||||||
import { ref, reactive, onMounted } from "vue";
|
import { ref, onMounted } from "vue";
|
||||||
|
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
|
@ -34,6 +34,7 @@ const visibleColumns = ref<string[]>([
|
||||||
"dateEnd",
|
"dateEnd",
|
||||||
"commandNo",
|
"commandNo",
|
||||||
"document",
|
"document",
|
||||||
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
|
|
@ -83,7 +84,22 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "lastUpdatedAt",
|
||||||
|
align: "left",
|
||||||
|
label: "วันที่แก้ไข",
|
||||||
|
sortable: true,
|
||||||
|
field: "lastUpdatedAt",
|
||||||
|
format: (v) => date2Thai(v, false, true),
|
||||||
|
headerStyle: "font-size: 14px",
|
||||||
|
style: "font-size: 14px",
|
||||||
|
sort: (a: string, b: string) =>
|
||||||
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"agency",
|
"agency",
|
||||||
|
|
@ -264,6 +280,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -22,7 +22,8 @@ const rowsHistoryData = ref<NopaidFormType[]>([]);
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const mode = ref<boolean>($q.screen.gt.xs);
|
const mode = ref<boolean>($q.screen.gt.xs);
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const { showLoader, hideLoader, messageError, date2Thai,onSearchDataTable } = mixin;
|
const { showLoader, hideLoader, messageError, date2Thai, onSearchDataTable } =
|
||||||
|
mixin;
|
||||||
|
|
||||||
const modalHistory = ref<boolean>(false);
|
const modalHistory = ref<boolean>(false);
|
||||||
/** ตัวแปรข้อมูล */
|
/** ตัวแปรข้อมูล */
|
||||||
|
|
@ -115,11 +116,14 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"date",
|
"date",
|
||||||
|
|
@ -208,7 +212,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
@ -319,6 +323,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,8 @@ const link = ref<string>("");
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const dataPerson = useDataStore();
|
const dataPerson = useDataStore();
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const { showLoader, hideLoader, messageError, date2Thai,onSearchDataTable } = mixin;
|
const { showLoader, hideLoader, messageError, date2Thai, onSearchDataTable } =
|
||||||
|
mixin;
|
||||||
|
|
||||||
const idByRow = ref<string>("");
|
const idByRow = ref<string>("");
|
||||||
const rows = ref<CertificateDetail[]>([]);
|
const rows = ref<CertificateDetail[]>([]);
|
||||||
|
|
@ -38,7 +39,6 @@ const visibleColumns = ref<string[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "certificateType",
|
name: "certificateType",
|
||||||
|
|
@ -114,13 +114,16 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"certificateType",
|
"certificateType",
|
||||||
|
|
@ -131,7 +134,6 @@ const visibleColumnsHistory = ref<string[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columnsHistory = ref<QTableProps["columns"]>([
|
const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "certificateType",
|
name: "certificateType",
|
||||||
|
|
@ -207,7 +209,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
|
|
@ -323,6 +325,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,6 @@ const visibleColumns = ref<string[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "name",
|
name: "name",
|
||||||
|
|
@ -178,13 +177,16 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"name", // ชื่อโครงงาน
|
"name", // ชื่อโครงงาน
|
||||||
|
|
@ -200,7 +202,6 @@ const visibleColumnsHistory = ref<string[]>([
|
||||||
"lastUpdateFullName", // แก้ไขโดย
|
"lastUpdateFullName", // แก้ไขโดย
|
||||||
"lastUpdatedAt", // แก้ไขเมื่อวันที่
|
"lastUpdatedAt", // แก้ไขเมื่อวันที่
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columnsHistory = ref<QTableProps["columns"]>([
|
const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "name",
|
name: "name",
|
||||||
|
|
@ -335,7 +336,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
|
|
@ -451,6 +452,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -47,7 +47,6 @@ const visibleColumns = ref<String[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "year",
|
name: "year",
|
||||||
|
|
@ -230,11 +229,14 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"insignia",
|
"insignia",
|
||||||
|
|
@ -253,7 +255,6 @@ const visibleColumnsHistory = ref<string[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columnsHistory = ref<QTableProps["columns"]>([
|
const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "year",
|
name: "year",
|
||||||
|
|
@ -425,7 +426,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, true, false),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
@ -540,6 +541,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -40,7 +40,6 @@ const visibleColumns = ref<String[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const columns = ref<QTableProps["columns"]>([
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "issueDate",
|
name: "issueDate",
|
||||||
|
|
@ -118,11 +117,14 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"issuer",
|
"issuer",
|
||||||
|
|
@ -210,7 +212,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
@ -323,6 +325,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -170,7 +170,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
@ -306,7 +306,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
@ -325,6 +325,9 @@ const visibleColumnsHistory = ref<string[]>([
|
||||||
"lastUpdateFullName",
|
"lastUpdateFullName",
|
||||||
"lastUpdatedAt",
|
"lastUpdatedAt",
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumns = ref<string[]>([
|
const visibleColumns = ref<string[]>([
|
||||||
"point1Total",
|
"point1Total",
|
||||||
|
|
@ -469,6 +472,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,8 @@ const rowsHistoryData = ref<any[]>([]);
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const mode = ref<boolean>($q.screen.gt.xs);
|
const mode = ref<boolean>($q.screen.gt.xs);
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const { showLoader, hideLoader, messageError, date2Thai,onSearchDataTable } = mixin;
|
const { showLoader, hideLoader, messageError, date2Thai, onSearchDataTable } =
|
||||||
|
mixin;
|
||||||
const modalDevelop = ref<boolean>(false);
|
const modalDevelop = ref<boolean>(false);
|
||||||
const kpiDevelopmentId = ref<string>("");
|
const kpiDevelopmentId = ref<string>("");
|
||||||
|
|
||||||
|
|
@ -47,7 +48,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "no",
|
name: "no",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "ลำดับ",
|
label: "ลำดับ",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "no",
|
field: "no",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
|
@ -57,7 +58,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "name",
|
name: "name",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "ความรู้ / ทักษะ / สมรรถนะที่ต้องได้รับการพัฒนา",
|
label: "ความรู้ / ทักษะ / สมรรถนะที่ต้องได้รับการพัฒนา",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "name",
|
field: "name",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
|
@ -68,7 +69,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "developmentProjects",
|
name: "developmentProjects",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "วิธีการพัฒนา",
|
label: "วิธีการพัฒนา",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "developmentProjects",
|
field: "developmentProjects",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
|
@ -79,7 +80,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "developmentTarget",
|
name: "developmentTarget",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "เป้าหมายการพัฒนา",
|
label: "เป้าหมายการพัฒนา",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "developmentTarget",
|
field: "developmentTarget",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
|
@ -90,7 +91,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "developmentResults",
|
name: "developmentResults",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "วิธีการวัดผลการพัฒนา",
|
label: "วิธีการวัดผลการพัฒนา",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "developmentResults",
|
field: "developmentResults",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
|
@ -101,7 +102,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "developmentReport",
|
name: "developmentReport",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "รายงานผลการพัฒนา",
|
label: "รายงานผลการพัฒนา",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "developmentReport",
|
field: "developmentReport",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
|
@ -112,7 +113,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "lastUpdateFullName",
|
name: "lastUpdateFullName",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "ผู้ดำเนินการ",
|
label: "ผู้ดำเนินการ",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "lastUpdateFullName",
|
field: "lastUpdateFullName",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
|
|
@ -123,11 +124,11 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "lastUpdatedAt",
|
name: "lastUpdatedAt",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "วันที่แก้ไข",
|
label: "วันที่แก้ไข",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
@ -192,7 +193,7 @@ function getHistory() {
|
||||||
function openDialogDevelop(data: any) {
|
function openDialogDevelop(data: any) {
|
||||||
modalDevelop.value = true;
|
modalDevelop.value = true;
|
||||||
kpiDevelopmentId.value = data.kpiDevelopmentId;
|
kpiDevelopmentId.value = data.kpiDevelopmentId;
|
||||||
typeIDP.value = data.type
|
typeIDP.value = data.type;
|
||||||
}
|
}
|
||||||
|
|
||||||
function onSearch() {
|
function onSearch() {
|
||||||
|
|
@ -376,7 +377,11 @@ onMounted(async () => {
|
||||||
</d-table>
|
</d-table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<DialogDevelop v-model:modal="modalDevelop" v-model:id="kpiDevelopmentId" :type="typeIDP"/>
|
<DialogDevelop
|
||||||
|
v-model:modal="modalDevelop"
|
||||||
|
v-model:id="kpiDevelopmentId"
|
||||||
|
:type="typeIDP"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.absolute_button {
|
.absolute_button {
|
||||||
|
|
|
||||||
|
|
@ -77,11 +77,14 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const visibleColumnsHistory = ref<string[]>([
|
const visibleColumnsHistory = ref<string[]>([
|
||||||
"date",
|
"date",
|
||||||
|
|
@ -130,7 +133,7 @@ const columnsHistory = ref<QTableProps["columns"]>([
|
||||||
field: "lastUpdatedAt",
|
field: "lastUpdatedAt",
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
style: "font-size: 14px",
|
style: "font-size: 14px",
|
||||||
format: (v) => date2Thai(v),
|
format: (v) => date2Thai(v, false, true),
|
||||||
sort: (a: string, b: string) =>
|
sort: (a: string, b: string) =>
|
||||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||||
},
|
},
|
||||||
|
|
@ -235,6 +238,7 @@ onMounted(async () => {
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,9 @@ const rows = defineModel<any>("rows");
|
||||||
const rowsData = defineModel<any>("rowsData");
|
const rowsData = defineModel<any>("rowsData");
|
||||||
const columns = defineModel<QTableProps["columns"]>("columns");
|
const columns = defineModel<QTableProps["columns"]>("columns");
|
||||||
const visibleColumns = defineModel<string[]>("visibleColumns");
|
const visibleColumns = defineModel<string[]>("visibleColumns");
|
||||||
|
const pagination = ref({
|
||||||
|
sortBy: "lastUpdatedAt",
|
||||||
|
});
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
getData: Function,
|
getData: Function,
|
||||||
|
|
@ -24,7 +27,7 @@ const props = defineProps({
|
||||||
});
|
});
|
||||||
function close() {
|
function close() {
|
||||||
modal.value = false;
|
modal.value = false;
|
||||||
filter.value = ''
|
filter.value = "";
|
||||||
}
|
}
|
||||||
|
|
||||||
function dateThaiRange(val: [Date, Date]) {
|
function dateThaiRange(val: [Date, Date]) {
|
||||||
|
|
@ -119,6 +122,7 @@ watch(
|
||||||
:rows-per-page-options="[10, 25, 50, 100]"
|
:rows-per-page-options="[10, 25, 50, 100]"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
:virtual-scroll-sticky-size-start="48"
|
:virtual-scroll-sticky-size-start="48"
|
||||||
|
v-model:pagination="pagination"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,7 @@ import Ability from "@/modules/10_registry/01_Information/06_Ability.vue";
|
||||||
|
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div v-if="!$q.screen.gt.xs" class="col-xs-12 col-sm-12 col-md-11">
|
<div v-if="!$q.screen.gt.xs" class="col-xs-12 col-sm-12 col-md-11">
|
||||||
<div class="toptitle text-white col-12 row items-center">
|
<div class="toptitle text-white col-12 row items-center">
|
||||||
|
|
@ -37,6 +38,7 @@ const router = useRouter();
|
||||||
<Ability />
|
<Ability />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.mobileClass {
|
.mobileClass {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
|
|
|
||||||
|
|
@ -69,7 +69,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "topic",
|
name: "topic",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "ชื่อเรื่อง",
|
label: "ชื่อเรื่อง",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "topic",
|
field: "topic",
|
||||||
format: (v) => (v ? v : "-"),
|
format: (v) => (v ? v : "-"),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
|
|
@ -79,7 +79,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "detail",
|
name: "detail",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "รายละเอียด",
|
label: "รายละเอียด",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "detail",
|
field: "detail",
|
||||||
format: (v) => (v ? v : "-"),
|
format: (v) => (v ? v : "-"),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
|
|
@ -98,7 +98,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "status",
|
name: "status",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "สถานะคำร้อง",
|
label: "สถานะคำร้อง",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "status",
|
field: "status",
|
||||||
format: (v) => store.convertStatus(v),
|
format: (v) => store.convertStatus(v),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
|
|
@ -108,7 +108,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
name: "remark",
|
name: "remark",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "หมายเหตุ ",
|
label: "หมายเหตุ ",
|
||||||
sortable: true,
|
sortable: false,
|
||||||
field: "remark",
|
field: "remark",
|
||||||
format: (v) => (v ? v : "-"),
|
format: (v) => (v ? v : "-"),
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue