Merge branch 'develop' into devTee
This commit is contained in:
commit
e24449e331
9 changed files with 631 additions and 51 deletions
|
|
@ -158,82 +158,130 @@ async function fetchDetailLeave(paramsId: string) {
|
|||
? data.reasonCommander
|
||||
: "-";
|
||||
formData.reasonOligarch = data.reasonOligarch ? data.reasonOligarch : "-";
|
||||
formData.positionName = data.positionName;
|
||||
formData.positionLevelName = data.positionLevelName;
|
||||
formData.organizationName = data.organizationName;
|
||||
formData.leaveTypeName = data.leaveTypeName;
|
||||
formData.leaveTypeId = data.leaveTypeId;
|
||||
formData.fullName = data.fullName;
|
||||
formData.positionName = data.positionName ? data.positionName : "-";
|
||||
formData.positionLevelName = data.positionLevelName
|
||||
? data.positionLevelName
|
||||
: "-";
|
||||
formData.organizationName = data.organizationName
|
||||
? data.organizationName
|
||||
: "-";
|
||||
formData.leaveTypeName = data.leaveTypeName ? data.leaveTypeName : "-";
|
||||
formData.leaveTypeId = data.leaveTypeId ? data.leaveTypeId : "-";
|
||||
formData.fullName = data.fullName ? data.fullName : "-";
|
||||
formData.dateSendLeave =
|
||||
data.dateSendLeave && date2Thai(data.dateSendLeave);
|
||||
formData.leaveDateStart =
|
||||
data.leaveStartDate && date2Thai(data.leaveStartDate);
|
||||
formData.leaveDateEnd = data.leaveEndDate && date2Thai(data.leaveEndDate);
|
||||
formData.leaveCount = data.leaveCount;
|
||||
formData.leaveCount = data.leaveCount ? data.leaveCount : "0";
|
||||
formData.status = data.status && stores.convertSatatus(data.status);
|
||||
formData.leaveLimit = data.leaveLimit;
|
||||
formData.leaveSummary = data.leaveSummary;
|
||||
formData.leaveRemain = data.leaveRemain;
|
||||
formData.leaveWrote = data.leaveWrote;
|
||||
formData.leaveAddress = data.leaveAddress;
|
||||
formData.leaveNumber = data.leaveNumber;
|
||||
formData.leaveDetail = data.leaveDetail;
|
||||
formData.leaveLimit = data.leaveLimit ? data.leaveLimit : "0";
|
||||
formData.leaveSummary = data.leaveSummary ? data.leaveSummary : "0";
|
||||
formData.leaveRemain = data.leaveRemain ? data.leaveRemain : "0";
|
||||
formData.leaveWrote = data.leaveWrote ? data.leaveWrote : "-";
|
||||
formData.leaveAddress = data.leaveAddress ? data.leaveAddress : "-";
|
||||
formData.leaveNumber = data.leaveNumber ? data.leaveNumber : "-";
|
||||
formData.leaveDetail = data.leaveDetail ? data.leaveDetail : "-";
|
||||
formData.leaveDocument = data.leaveDocument;
|
||||
formData.leaveDraftDocument = data.leaveDraftDocument;
|
||||
formData.leaveLastStart =
|
||||
data.leaveLastStart && date2Thai(data.leaveLastStart);
|
||||
formData.leaveLastEnd =
|
||||
data.leaveLastStart && date2Thai(data.leaveLastEnd);
|
||||
formData.leaveTotal = data.leaveTotal;
|
||||
formData.leaveTotal = data.leaveTotal ? data.leaveTotal : "0";
|
||||
formData.leavebirthDate =
|
||||
data.leavebirthDate && date2Thai(data.leavebirthDate);
|
||||
data.leaveBirthDate && date2Thai(data.leaveBirthDate);
|
||||
formData.leavegovernmentDate =
|
||||
data.leavegovernmentDate && date2Thai(data.leavegovernmentDate);
|
||||
formData.leaveSalary = data.leaveSalary;
|
||||
formData.leaveSalaryText = data.leaveSalaryText;
|
||||
data.leaveGovernmentDate && date2Thai(data.leaveGovernmentDate);
|
||||
formData.leaveSalary = data.leaveSalary ? data.leaveSalary : "-";
|
||||
formData.leaveSalaryText = data.leaveSalaryText ? data.leaveSalaryText : "-";
|
||||
formData.leaveTypeDay =
|
||||
data.leaveTypeDay && stores.convertLeaveDaytype(data.leaveTypeDay);
|
||||
formData.wifeDayName = data.wifeDayName;
|
||||
formData.wifeDayName = data.wifeDayName ? data.wifeDayName : "-";
|
||||
formData.wifeDayDateBorn =
|
||||
data.wifeDayDateBorn && date2Thai(data.wifeDayDateBorn);
|
||||
formData.restDayOldTotal = data.restDayOldTotal;
|
||||
formData.restDayCurrentTotal = data.restDayCurrentTotal;
|
||||
formData.restDayOldTotal = data.restDayOldTotal
|
||||
? data.restDayOldTotal
|
||||
: "0";
|
||||
formData.restDayCurrentTotal = data.restDayCurrentTotal
|
||||
? data.restDayCurrentTotal
|
||||
: "0";
|
||||
formData.ordainDayStatus = data.ordainDayStatus;
|
||||
formData.ordainDayLocationName = data.ordainDayLocationName;
|
||||
formData.ordainDayLocationAddress = data.ordainDayLocationAddress;
|
||||
formData.ordainDayLocationNumber = data.ordainDayLocationNumber;
|
||||
formData.ordainDayLocationName = data.ordainDayLocationName
|
||||
? data.ordainDayLocationName
|
||||
: "-";
|
||||
formData.ordainDayLocationAddress = data.ordainDayLocationAddress
|
||||
? data.ordainDayLocationAddress
|
||||
: "-";
|
||||
formData.ordainDayLocationNumber = data.ordainDayLocationNumber
|
||||
? data.ordainDayLocationNumber
|
||||
: "-";
|
||||
formData.ordainDayOrdination =
|
||||
data.ordainDayOrdination && date2Thai(data.ordainDayOrdination);
|
||||
formData.ordainDayBuddhistLentName = data.ordainDayBuddhistLentName;
|
||||
formData.ordainDayBuddhistLentAddress = data.ordainDayBuddhistLentAddress;
|
||||
formData.ordainDayBuddhistLentName = data.ordainDayBuddhistLentName
|
||||
? data.ordainDayBuddhistLentName
|
||||
: "-";
|
||||
formData.ordainDayBuddhistLentAddress = data.ordainDayBuddhistLentAddress
|
||||
? data.ordainDayBuddhistLentAddress
|
||||
: "-";
|
||||
formData.hajjDayStatus = data.hajjDayStatus;
|
||||
formData.absentDaySummon = data.absentDaySummon;
|
||||
formData.absentDayLocation = data.absentDayLocation;
|
||||
formData.absentDaySummon = data.absentDaySummon
|
||||
? data.absentDaySummon
|
||||
: "-";
|
||||
formData.absentDayLocation = data.absentDayLocation
|
||||
? data.absentDayLocation
|
||||
: "-";
|
||||
formData.absentDayRegistorDate =
|
||||
data.absentDayRegistorDate && date2Thai(data.absentDayRegistorDate);
|
||||
formData.absentDayGetIn = data.absentDayGetIn;
|
||||
formData.absentDayAt = data.absentDayAt;
|
||||
formData.studyDaySubject = data.studyDaySubject;
|
||||
formData.studyDayDegreeLevel = data.studyDayDegreeLevel;
|
||||
formData.studyDayUniversityName = data.studyDayUniversityName;
|
||||
formData.studyDayTrainingSubject = data.studyDayTrainingSubject;
|
||||
formData.studyDayTrainingName = data.studyDayTrainingName;
|
||||
formData.studyDayCountry = data.studyDayCountry;
|
||||
formData.studyDayScholarship = data.studyDayScholarship;
|
||||
formData.coupleDayName = data.coupleDayName;
|
||||
formData.coupleDayPosition = data.coupleDayPosition;
|
||||
formData.coupleDayLevel = data.coupleDayLevel;
|
||||
formData.coupleDayLevelCountry = data.coupleDayLevelCountry;
|
||||
formData.coupleDayCountryHistory = data.coupleDayCountryHistory;
|
||||
formData.coupleDayTotalHistory = data.coupleDayTotalHistory;
|
||||
formData.absentDayGetIn = data.absentDayGetIn ? data.absentDayGetIn : "-";
|
||||
formData.absentDayAt = data.absentDayAt ? data.absentDayAt : "-";
|
||||
formData.studyDaySubject = data.studyDaySubject
|
||||
? data.studyDaySubject
|
||||
: "-";
|
||||
formData.studyDayDegreeLevel = data.studyDayDegreeLevel
|
||||
? data.studyDayDegreeLevel
|
||||
: "-";
|
||||
formData.studyDayUniversityName = data.studyDayUniversityName
|
||||
? data.studyDayUniversityName
|
||||
: "-";
|
||||
formData.studyDayTrainingSubject = data.studyDayTrainingSubject
|
||||
? data.studyDayTrainingSubject
|
||||
: "-";
|
||||
formData.studyDayTrainingName = data.studyDayTrainingName
|
||||
? data.studyDayTrainingName
|
||||
: "-";
|
||||
formData.studyDayCountry = data.studyDayCountry
|
||||
? data.studyDayCountry
|
||||
: "-";
|
||||
formData.studyDayScholarship = data.studyDayScholarship
|
||||
? data.studyDayScholarship
|
||||
: "-";
|
||||
formData.coupleDayName = data.coupleDayName ? data.coupleDayName : "-";
|
||||
formData.coupleDayPosition = data.coupleDayPosition
|
||||
? data.coupleDayPosition
|
||||
: "-";
|
||||
formData.coupleDayLevel = data.coupleDayLevel ? data.coupleDayLevel : "-";
|
||||
formData.coupleDayLevelCountry = data.coupleDayLevelCountry
|
||||
? data.coupleDayLevelCountry
|
||||
: "-";
|
||||
formData.coupleDayCountryHistory = data.coupleDayCountryHistory
|
||||
? data.coupleDayCountryHistory
|
||||
: "-";
|
||||
formData.coupleDayTotalHistory = data.coupleDayTotalHistory
|
||||
? data.coupleDayTotalHistory
|
||||
: "-";
|
||||
formData.coupleDayStartDateHistory =
|
||||
data.coupleDayStartDateHistory &&
|
||||
date2Thai(data.coupleDayStartDateHistory);
|
||||
formData.coupleDayEndDateHistory =
|
||||
data.coupleDayEndDateHistory && date2Thai(data.coupleDayEndDateHistory);
|
||||
formData.coupleDaySumTotalHistory = data.coupleDaySumTotalHistory;
|
||||
formData.coupleDaySumTotalHistory = data.coupleDaySumTotalHistory
|
||||
? data.coupleDaySumTotalHistory
|
||||
: "-";
|
||||
formData.approveStep = data.approveStep;
|
||||
formData.dear = data.dear ? data.dear : "-";
|
||||
console.log(formData);
|
||||
|
||||
await fectOptionType();
|
||||
|
||||
/** ส่งประเภทของการลาไป Function เช็คประเภทการลา*/
|
||||
|
|
|
|||
|
|
@ -78,11 +78,15 @@ export const useSpecialTimeStore = defineStore("LeaveSpecialTime", () => {
|
|||
timeMorning:
|
||||
e.startTimeMorning == null
|
||||
? "-"
|
||||
: e.checkInEdit == true ? e.startTimeMorning + " - " + e.endTimeMorning:'-',
|
||||
: e.checkInEdit == true
|
||||
? e.startTimeMorning + " - " + e.endTimeMorning
|
||||
: "-",
|
||||
timeAfternoon:
|
||||
e.startTimeAfternoon == null
|
||||
? "-"
|
||||
: e.checkOutEdit == true ? e.startTimeAfternoon + " - " + e.endTimeAfternoon:'-',
|
||||
: e.checkOutEdit == true
|
||||
? e.startTimeAfternoon + " - " + e.endTimeAfternoon
|
||||
: "-",
|
||||
startTimeMorning: e.startTimeMorning,
|
||||
endTimeMorning: e.endTimeMorning,
|
||||
startTimeAfternoon: e.startTimeAfternoon,
|
||||
|
|
|
|||
|
|
@ -46,7 +46,6 @@ const complaintEdit = () =>
|
|||
import("@/modules/11_discipline/components/1_Complaint/EditPage.vue");
|
||||
const reportType = () =>
|
||||
import("@/modules/11_discipline/components/5_Report/DetailPage.vue");
|
||||
|
||||
const InvestigateDisciplinaryAdd = () =>
|
||||
import(
|
||||
"@/modules/11_discipline/components/3_InvestigateDisciplinary/AddPage.vue"
|
||||
|
|
@ -68,9 +67,12 @@ const listSuspendMainPage = () =>
|
|||
const suspendEditPage = () =>
|
||||
import("@/modules/11_discipline/components/7_ListSuspend/DetailPage.vue");
|
||||
|
||||
const appealComplain = () => import('@/modules/11_discipline/components/8_AppealComplain/MainPage.vue')
|
||||
const appealComplainAdd = () => import('@/modules/11_discipline/components/8_AppealComplain/AddPage.vue')
|
||||
const appealComplainEdit = () => import('@/modules/11_discipline/components/8_AppealComplain/EditPage.vue')
|
||||
const appealComplain = () =>
|
||||
import("@/modules/11_discipline/components/8_AppealComplain/MainPage.vue");
|
||||
const appealComplainAdd = () =>
|
||||
import("@/modules/11_discipline/components/8_AppealComplain/AddPage.vue");
|
||||
const appealComplainEdit = () =>
|
||||
import("@/modules/11_discipline/components/8_AppealComplain/EditPage.vue");
|
||||
export default [
|
||||
{
|
||||
path: "/discipline/complaints",
|
||||
|
|
|
|||
73
src/modules/12_Evaluate/MainPage.vue
Normal file
73
src/modules/12_Evaluate/MainPage.vue
Normal file
|
|
@ -0,0 +1,73 @@
|
|||
<script setup lang="ts">
|
||||
import { onMounted, ref } from "vue";
|
||||
import { useQuasar } from "quasar";
|
||||
import { useRouter } from "vue-router";
|
||||
import http from "@/plugins/http";
|
||||
import config from "@/app.config";
|
||||
|
||||
import Table from "@/modules/12_Evaluate/components/Table.vue";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useEvalutuonStore } from "@/modules/12_Evaluate/store/Evaluate";
|
||||
import type { Pagination } from "@/modules/03_recruiting/interface/index/Main";
|
||||
|
||||
const $q = useQuasar(); // show dialog
|
||||
const router = useRouter();
|
||||
//search data table
|
||||
const mixin = useCounterMixin();
|
||||
const store = useEvalutuonStore();
|
||||
const { showLoader, hideLoader, messageError } = mixin;
|
||||
|
||||
const initialPagination = ref<Pagination>({
|
||||
rowsPerPage: 0,
|
||||
});
|
||||
|
||||
const page = ref<number>(1);
|
||||
const pageSize = ref<number>(5);
|
||||
const maxPage = ref<number>(1);
|
||||
const filter = ref<string>("");
|
||||
|
||||
/**เมื่อเริ่มโหลดหน้า
|
||||
* ส่งข้อมูลจำลองไปยัง store
|
||||
*/
|
||||
onMounted(async () => {});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="toptitle text-dark col-12 row items-center">
|
||||
รายการคำขอประเมิน
|
||||
</div>
|
||||
<q-card flat bordered class="col-12 q-mt-sm q-pt-sm q-pa-md">
|
||||
<div>
|
||||
<Table
|
||||
style="max-height: 80vh"
|
||||
:rows="store.rows"
|
||||
:columns="store.columns"
|
||||
:visible-columns="store.visibleColumns"
|
||||
v-model:inputfilter="filter"
|
||||
v-model:inputvisible="store.visibleColumns"
|
||||
:pagination="initialPagination"
|
||||
:nornmalData="true"
|
||||
:paging="true"
|
||||
:titleText="''"
|
||||
:page="page"
|
||||
:pageSize="pageSize"
|
||||
:maxPage="maxPage"
|
||||
>
|
||||
<template #columns="props">
|
||||
<q-tr :props="props" class="cursor-pointer">
|
||||
<q-td v-for="col in props.cols" :key="col.name" :props="props">
|
||||
<div v-if="col.name == 'no'">
|
||||
{{ props.rowIndex + 1 }}
|
||||
</div>
|
||||
<div v-else>
|
||||
{{ col.value }}
|
||||
</div>
|
||||
</q-td>
|
||||
</q-tr>
|
||||
</template>
|
||||
</Table>
|
||||
</div>
|
||||
</q-card>
|
||||
</template>
|
||||
|
||||
<style></style>
|
||||
0
src/modules/12_Evaluate/components/DetailPage.vue
Normal file
0
src/modules/12_Evaluate/components/DetailPage.vue
Normal file
228
src/modules/12_Evaluate/components/Table.vue
Normal file
228
src/modules/12_Evaluate/components/Table.vue
Normal file
|
|
@ -0,0 +1,228 @@
|
|||
<script setup lang="ts">
|
||||
import { ref, useAttrs, watch } from "vue";
|
||||
|
||||
const table = ref<any>(null);
|
||||
const filterRef = ref<any>(null);
|
||||
const attrs = ref<any>(useAttrs());
|
||||
const paging = ref<boolean>(true);
|
||||
|
||||
/** รับ props มาจากหน้าหลัก */
|
||||
const props = defineProps({
|
||||
count: Number,
|
||||
pass: Number,
|
||||
notpass: Number,
|
||||
inputfilter: String,
|
||||
name: String,
|
||||
icon: String,
|
||||
inputvisible: Array,
|
||||
editvisible: Boolean,
|
||||
validate: {
|
||||
type: Function,
|
||||
default: () => console.log("not function"),
|
||||
},
|
||||
nornmalData: {
|
||||
type: Boolean,
|
||||
defualt: true,
|
||||
},
|
||||
conclude: {
|
||||
type: Boolean,
|
||||
defualt: false,
|
||||
},
|
||||
page: {
|
||||
type: Number,
|
||||
},
|
||||
pageSize: {
|
||||
type: Number,
|
||||
},
|
||||
maxPage: {
|
||||
type: Number,
|
||||
},
|
||||
});
|
||||
|
||||
const currentPage = ref<number>(1);
|
||||
const filter = ref<string>("");
|
||||
const pagination = ref({
|
||||
descending: false,
|
||||
page: props.page,
|
||||
rowsPerPage: props.pageSize,
|
||||
});
|
||||
|
||||
const emit = defineEmits([
|
||||
"update:inputfilter",
|
||||
"update:inputvisible",
|
||||
"update:editvisible",
|
||||
"update:queryString",
|
||||
]);
|
||||
|
||||
function updateInput(value: string | number | null) {
|
||||
emit("update:inputfilter", value);
|
||||
}
|
||||
|
||||
function updateVisible(value: []) {
|
||||
emit("update:inputvisible", value);
|
||||
}
|
||||
|
||||
function resetFilter() {
|
||||
// reset ค่าที่ค้นหาเมื่อกดปุ่ม X ในกล่องค้นหา
|
||||
emit("update:inputfilter", "");
|
||||
filterRef.value.focus();
|
||||
}
|
||||
|
||||
function updateRowsPerPage(newPagination: any) {
|
||||
pagination.value = newPagination;
|
||||
currentPage.value = 1;
|
||||
}
|
||||
|
||||
function filterFn() {
|
||||
updatePaging(1, Number(pagination.value.rowsPerPage), filter.value);
|
||||
}
|
||||
|
||||
function updatePaging(p: number, pS: number, key: string) {
|
||||
emit("update:queryString", p, pS, key);
|
||||
}
|
||||
|
||||
watch([() => currentPage.value, () => pagination.value.rowsPerPage], () => {
|
||||
emit(
|
||||
"update:queryString",
|
||||
currentPage.value,
|
||||
Number(pagination.value.rowsPerPage),
|
||||
filter.value
|
||||
);
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="q-pb-sm row q-col-gutter-sm">
|
||||
<div class="q-gutter-sm" v-if="nornmalData == true">
|
||||
<!-- <q-btn
|
||||
to="/discipline-result/add"
|
||||
size="12px"
|
||||
flat
|
||||
round
|
||||
color="add"
|
||||
icon="mdi-plus"
|
||||
>
|
||||
<q-tooltip>เพิ่มข้อมูล</q-tooltip>
|
||||
</q-btn> -->
|
||||
</div>
|
||||
<q-space />
|
||||
<!-- ค้นหาข้อความใน table -->
|
||||
<q-input
|
||||
standout
|
||||
dense
|
||||
v-model="filter"
|
||||
ref="filterRef"
|
||||
@keydown.enter.prevent="filterFn"
|
||||
outlined
|
||||
placeholder="ค้นหา"
|
||||
style="max-width: 200px"
|
||||
class="col-xs-12 col-sm-3 col-md-2"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon v-if="filter == ''" name="search" />
|
||||
<q-icon
|
||||
v-if="filter !== ''"
|
||||
name="clear"
|
||||
class="cursor-pointer"
|
||||
@click="resetFilter"
|
||||
/>
|
||||
</template>
|
||||
</q-input>
|
||||
<!-- แสดงคอลัมน์ใน table -->
|
||||
<q-select
|
||||
:model-value="inputvisible"
|
||||
@update:model-value="updateVisible"
|
||||
:display-value="$q.lang.table.columns"
|
||||
multiple
|
||||
outlined
|
||||
dense
|
||||
:options="attrs.columns"
|
||||
options-dense
|
||||
option-value="name"
|
||||
map-options
|
||||
emit-value
|
||||
class="col-xs-12 col-sm-3 col-md-2 gt-xs"
|
||||
>
|
||||
</q-select>
|
||||
</div>
|
||||
<d-table
|
||||
ref="table"
|
||||
flat
|
||||
v-bind="attrs"
|
||||
virtual-scroll
|
||||
:virtual-scroll-sticky-size-start="48"
|
||||
dense
|
||||
:rows-per-page-options="[10, 25, 50, 100]"
|
||||
:pagination="pagination"
|
||||
@update:pagination="updateRowsPerPage"
|
||||
>
|
||||
<template v-slot:header="props">
|
||||
<q-tr :props="props">
|
||||
<q-th v-for="col in props.cols" :key="col.name" :props="props">
|
||||
<span class="text-weight-medium" v-html="col.label" />
|
||||
</q-th>
|
||||
</q-tr>
|
||||
</template>
|
||||
<template #body="props">
|
||||
<slot v-bind="props" name="columns"></slot>
|
||||
</template>
|
||||
<template v-slot:pagination="scope">
|
||||
<q-pagination
|
||||
v-model="currentPage"
|
||||
active-color="primary"
|
||||
color="dark"
|
||||
:max="Number(props.maxPage)"
|
||||
size="sm"
|
||||
boundary-links
|
||||
direction-links
|
||||
></q-pagination>
|
||||
</template>
|
||||
</d-table>
|
||||
</template>
|
||||
|
||||
<style lang="scss">
|
||||
.icon-color {
|
||||
color: #4154b3;
|
||||
}
|
||||
|
||||
.custom-table2 {
|
||||
max-height: 64vh;
|
||||
|
||||
.q-table tr:nth-child(odd) td {
|
||||
background: white;
|
||||
}
|
||||
|
||||
.q-table tr:nth-child(even) td {
|
||||
background: #f8f8f8;
|
||||
}
|
||||
|
||||
.q-table thead tr {
|
||||
background: #ecebeb;
|
||||
}
|
||||
|
||||
.q-table thead tr th {
|
||||
position: sticky;
|
||||
}
|
||||
|
||||
.q-table td:nth-of-type(2) {
|
||||
z-index: 3 !important;
|
||||
}
|
||||
|
||||
.q-table th:nth-of-type(2),
|
||||
.q-table td:nth-of-type(2) {
|
||||
position: sticky;
|
||||
left: 0;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
/* this will be the loading indicator */
|
||||
.q-table thead tr:last-child th {
|
||||
/* height of all previous header rows */
|
||||
top: 48px;
|
||||
}
|
||||
|
||||
.q-table thead tr:first-child th {
|
||||
top: 0;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
86
src/modules/12_Evaluate/interface/index/Main.ts
Normal file
86
src/modules/12_Evaluate/interface/index/Main.ts
Normal file
|
|
@ -0,0 +1,86 @@
|
|||
interface DataOption {
|
||||
id: string;
|
||||
name: string;
|
||||
}
|
||||
interface DataOptionYear {
|
||||
id: number;
|
||||
name: string;
|
||||
}
|
||||
interface DataOptioGroup {
|
||||
id: string;
|
||||
name: string;
|
||||
|
||||
disable: Boolean;
|
||||
}
|
||||
|
||||
interface DataNumberOption {
|
||||
id: number;
|
||||
name: string;
|
||||
}
|
||||
|
||||
interface InvestigatefactsDataRowType {
|
||||
id: string;
|
||||
title: string;
|
||||
respondentType: string;
|
||||
offenseDetails: string;
|
||||
investigationDetail: string;
|
||||
dateInvestigate: string;
|
||||
investigationStatusResult: string;
|
||||
status: string;
|
||||
}
|
||||
|
||||
interface investigateDisDataRowType {
|
||||
id: string; //id รายการ
|
||||
title: string; //เรื่องร้องเรียน
|
||||
interrogated: string; //ผู้ถูกสอบสวน
|
||||
descMistake: string; //ลักษณะความผิด
|
||||
mistakeLevel: string; //ระดับโทษความผิด
|
||||
mistakeCase: string; //กรณีความผิด
|
||||
investigationDate: Date | null; //วันที่สอบสวน
|
||||
status: string | null; //สถานะ
|
||||
isResultConfirmed: Boolean; //ยืนยันผลเเล้ว/ยังไม่ได้ยืนยันผล
|
||||
}
|
||||
|
||||
interface directorType {
|
||||
id: string;
|
||||
directorId?: string;
|
||||
prefix: string;
|
||||
firstName: string;
|
||||
lastName: string;
|
||||
position: string;
|
||||
email: string;
|
||||
phone: string;
|
||||
total?: number;
|
||||
duty?: string;
|
||||
}
|
||||
interface responseType {
|
||||
id: string;
|
||||
directorId?: string;
|
||||
prefix: string;
|
||||
firstName: string;
|
||||
lastName: string;
|
||||
position: string;
|
||||
email: string;
|
||||
phone: string;
|
||||
total?: number;
|
||||
duty?: string;
|
||||
|
||||
}
|
||||
|
||||
interface FileLists {
|
||||
id: string; //id เอกสาร
|
||||
fileName: string; //ชื่่อเอกสาร
|
||||
pathName: string; //link file
|
||||
}
|
||||
|
||||
export type {
|
||||
DataOption,
|
||||
InvestigatefactsDataRowType,
|
||||
investigateDisDataRowType,
|
||||
directorType,
|
||||
DataNumberOption,
|
||||
responseType,
|
||||
FileLists,
|
||||
DataOptioGroup,
|
||||
DataOptionYear,
|
||||
};
|
||||
25
src/modules/12_Evaluate/router.ts
Normal file
25
src/modules/12_Evaluate/router.ts
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
const Evaluate = () => import("@/modules/12_Evaluate/MainPage.vue");
|
||||
const EvaluateDetail = () =>
|
||||
import("@/modules/12_Evaluate/components/DetailPage.vue");
|
||||
export default [
|
||||
{
|
||||
path: "/evaluate",
|
||||
name: "evaluate",
|
||||
component: Evaluate,
|
||||
meta: {
|
||||
Auth: true,
|
||||
Key: [12],
|
||||
Role: "evaluate",
|
||||
},
|
||||
},
|
||||
{
|
||||
path: "/evaluate/detail",
|
||||
name: "evaluateDetail",
|
||||
component: EvaluateDetail,
|
||||
meta: {
|
||||
Auth: true,
|
||||
Key: [12.1],
|
||||
Role: "evaluate",
|
||||
},
|
||||
},
|
||||
];
|
||||
114
src/modules/12_Evaluate/store/Evaluate.ts
Normal file
114
src/modules/12_Evaluate/store/Evaluate.ts
Normal file
|
|
@ -0,0 +1,114 @@
|
|||
import { defineStore } from "pinia";
|
||||
import { ref } from "vue";
|
||||
import type { QTableProps } from "quasar";
|
||||
import type { DataOption } from "@/modules/12_Evaluate/interface/index/Main";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
|
||||
const mixin = useCounterMixin();
|
||||
const { date2Thai } = mixin;
|
||||
export const useEvalutuonStore = defineStore("EvalutuonStore", () => {
|
||||
/** function สถานะ*/
|
||||
function convertStatus(val: string) {
|
||||
switch (val) {
|
||||
// case "NEW":
|
||||
// return "กำลังสรุปผลการพิจารณา";
|
||||
// case "STOP":
|
||||
// return "ยุติเรื่อง";
|
||||
case "DONE":
|
||||
return "กำลังสรุปผลการพิจารณา";
|
||||
case "REPORT":
|
||||
return "ส่งไปออกคำสั่ง";
|
||||
}
|
||||
}
|
||||
|
||||
const visibleColumns = ref<String[]>([
|
||||
"citizanId",
|
||||
"fullName",
|
||||
"position",
|
||||
"level",
|
||||
"positionNumber",
|
||||
"agency",
|
||||
"status",
|
||||
]);
|
||||
const rows = ref<any[]>([]);
|
||||
|
||||
const columns = ref<QTableProps["columns"]>([
|
||||
{
|
||||
name: "citizanId",
|
||||
align: "center",
|
||||
label: "เลขประจำตัวประชาชน",
|
||||
sortable: false,
|
||||
field: "citizanId",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "fullName",
|
||||
align: "left",
|
||||
label: "ชื่อ-นามสกุล",
|
||||
sortable: true,
|
||||
field: "fullName",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "position",
|
||||
align: "left",
|
||||
label: "ตำแหน่ง",
|
||||
sortable: true,
|
||||
field: "position",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
sort: (a: string, b: string) =>
|
||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||
},
|
||||
{
|
||||
name: "level",
|
||||
align: "left",
|
||||
label: "ระดับ",
|
||||
sortable: true,
|
||||
field: "level",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
sort: (a: string, b: string) =>
|
||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||
},
|
||||
{
|
||||
name: "positionNumber",
|
||||
align: "left",
|
||||
label: "ตำแหน่งเลขที่",
|
||||
sortable: true,
|
||||
field: "positionNumber",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
sort: (a: string, b: string) =>
|
||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||
},
|
||||
{
|
||||
name: "agency",
|
||||
align: "left",
|
||||
label: "สังกัด",
|
||||
sortable: true,
|
||||
field: "agency",
|
||||
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: true,
|
||||
field: "status",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
]);
|
||||
|
||||
return {
|
||||
visibleColumns,
|
||||
columns,
|
||||
rows,
|
||||
};
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue