diff --git a/src/modules/08_registryEmployee/components/AddEmployee/Main.vue b/src/modules/08_registryEmployee/components/AddEmployee/Main.vue
index 35098cfc7..162446638 100644
--- a/src/modules/08_registryEmployee/components/AddEmployee/Main.vue
+++ b/src/modules/08_registryEmployee/components/AddEmployee/Main.vue
@@ -359,7 +359,7 @@ const clickBack = () => {
- val.length != 13 ||`${'กรุณากรอกเลขประจำตัวประชาชนให้ครบ'}`,]" -->
- filterSelector(inputValue, doneFn, 'prefixOps')" />
-
-
-
{{ year + 543 }}
@@ -394,7 +394,7 @@ const clickBack = () => {
{{ parseInt(value + 543) }}
- {
:model-value="informaData.age" :label="`${'อายุ'}`" />
- filterSelector(inputValue, doneFn, 'genderOps'
)" />
- filterSelector(inputValue, doneFn, 'statusOps'
)" />
-
-
- filterSelector(inputValue, doneFn, 'religionOps'
)" />
- filterSelector(inputValue, doneFn, 'bloodOps'
)" clearable />
-
-
+
@@ -482,7 +482,7 @@ const clickBack = () => {
อัปเดตรูปภาพ
-
+
diff --git a/src/modules/11_discipline/components/2_InvestigateFacts/MainPage.vue b/src/modules/11_discipline/components/2_InvestigateFacts/MainPage.vue
index cb8e5d0e0..8635c2d3c 100644
--- a/src/modules/11_discipline/components/2_InvestigateFacts/MainPage.vue
+++ b/src/modules/11_discipline/components/2_InvestigateFacts/MainPage.vue
@@ -1,6 +1,6 @@
@@ -194,7 +125,7 @@ onMounted(()=>{
{
:display-value="$q.lang.table.columns"
emit-value
map-options
- :options="columns"
+ :options="dataInvestigate.columns"
option-value="name"
options-cover
style="min-width: 150px"
@@ -212,7 +143,7 @@ onMounted(()=>{
{
dense
class="custom-header-table"
v-bind="attrs"
- :visible-columns="visibleColumns"
+ :visible-columns="dataInvestigate.visibleColumns"
:pagination-label="paginationLabel"
v-model:pagination="pagination"
>
-
+
{{ col.label }}
@@ -237,57 +173,29 @@ onMounted(()=>{
-
- {{ props.rowIndex + 1 }}
+
+
+ {{ props.rowIndex + 1 }}
+
+
+ {{ col.value }}
+
-
- {{ props.row.subject }}
-
-
- {{ props.row.interrogated }}
-
-
- {{ props.row.fault }}
-
-
- {{ props.row.status }}
-
-
+
{{ props.row.active }}
-
- ยกเลิกยุติเรื่อง
+
+ ยกเลิกยุติเรื่อง
-
-
-
diff --git a/src/modules/11_discipline/interface/index/Main.ts b/src/modules/11_discipline/interface/index/Main.ts
index d61ea9435..a9c8d518c 100644
--- a/src/modules/11_discipline/interface/index/Main.ts
+++ b/src/modules/11_discipline/interface/index/Main.ts
@@ -5,9 +5,9 @@ interface DataOption {
interface investigatefactsDataRowType {
subject: string;
interrogated: string;
- fault: string;
- status: string;
- active: string;
+ fault: string|undefined;
+ status: string|undefined;
+ active: string|undefined;
}
interface MyObjectRef {
orderType: any;
diff --git a/src/modules/11_discipline/store/InvestigateFactStore.ts b/src/modules/11_discipline/store/InvestigateFactStore.ts
index 99c039f89..9b645d940 100644
--- a/src/modules/11_discipline/store/InvestigateFactStore.ts
+++ b/src/modules/11_discipline/store/InvestigateFactStore.ts
@@ -1,5 +1,6 @@
import { defineStore } from "pinia";
import { ref } from "vue";
+import type { QTableProps } from "quasar";
import type { investigatefactsDataRowType, DataOption } from '@/modules/11_discipline/interface/index/Main'
export const useInvestigateFactStore = defineStore("DisciplineInvestigateFact", () => {
@@ -23,6 +24,66 @@ export const useInvestigateFactStore = defineStore("DisciplineInvestigateFact",
{ id: "002", name: "ไม่ร้ายเเรง" },
{ id: "003", name: "ร้ายเเรง" },
]);
+ const visibleColumns = ref
([
+ "no",
+ "subject",
+ "interrogated",
+ "fault",
+ "status",
+ ]); //ค้นหา คอลัมน์ คอลัมน์ที่แสดง
+
+ // หัวตาราง
+ const columns = ref([
+ {
+ name: "no",
+ align: "center",
+ label: "ลำดับ",
+ sortable: false,
+ field: "no",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ },
+ {
+ name: "subject",
+ align: "left",
+ label: "เรื่อง",
+ sortable: true,
+ field: "subject",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ },
+ {
+ name: "interrogated",
+ align: "left",
+ label: "ผู้ถูกสอบสวน",
+ sortable: true,
+ field: "interrogated",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "fault",
+ align: "left",
+ label: "ลักษณะความผิด",
+ sortable: true,
+ field: "fault",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "status",
+ align: "left",
+ label: "สถานะ",
+ sortable: false,
+ field: "status",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ },
+ ]);
function filterFnOptionsType(val: string, update: any, type: string) {
update(() => {
const needle = val.toLowerCase();
@@ -44,16 +105,17 @@ export const useInvestigateFactStore = defineStore("DisciplineInvestigateFact",
});
}
- async function fecthList(data: investigatefactsDataRowType[]) {
- let datalist: investigatefactsDataRowType[] = data.map((e: any) => ({
- subject: e.subject,
- interrogated: e.interrogated,
- fault: e.fault ?? convertFault(e.fault),
- status: e.status ?? convertSatatus(e.status),
- active: e.active ?? activeStatus(e.active)
-
- }))
- rows.value = datalist
+ function fecthList(data: investigatefactsDataRowType[]) {
+ let datalist: investigatefactsDataRowType[] = data.map((e: investigatefactsDataRowType) => {
+ return {
+ subject: e.subject,
+ interrogated: e.interrogated,
+ fault: e.fault ? convertFault(e.fault):'-',
+ status: e.status ? convertSatatus(e.status):'-',
+ active: e.active ? activeStatus(e.active):'-'
+ };
+ });
+ rows.value = datalist;
}
function convertFault(val: string) {
switch (val) {
@@ -89,5 +151,7 @@ export const useInvestigateFactStore = defineStore("DisciplineInvestigateFact",
faultOp,
daysExtendOp,
investigationOp,
+ visibleColumns,
+ columns
};
})
\ No newline at end of file