ดูข้อมูลในทะเบียนประวัติ ปรับ UI
This commit is contained in:
parent
24a93f0024
commit
6a7d3e15c5
4 changed files with 119 additions and 36 deletions
|
|
@ -15,6 +15,7 @@ import { useDisciplineMainStore } from "@/modules/11_discipline/store/main";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
|
|
||||||
|
import PopupPersonal from "@/components/Dialogs/PopupPersonal.vue";
|
||||||
import DialogAddPersonal from "@/components/Dialogs/AddPersonal.vue";
|
import DialogAddPersonal from "@/components/Dialogs/AddPersonal.vue";
|
||||||
|
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
|
|
@ -24,6 +25,8 @@ const channelOptions = ref<DataOption[]>([]);
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const mainStore = useDisciplineMainStore();
|
const mainStore = useDisciplineMainStore();
|
||||||
const complainstStore = useComplainstDataStore();
|
const complainstStore = useComplainstDataStore();
|
||||||
|
const modalPersonal = ref<boolean>(false);
|
||||||
|
const personId = ref<string>("");
|
||||||
|
|
||||||
/**ชั่งฟังเพิ่มข้อมูล ลง ตาราง */
|
/**ชั่งฟังเพิ่มข้อมูล ลง ตาราง */
|
||||||
const modal = ref<boolean>(false);
|
const modal = ref<boolean>(false);
|
||||||
|
|
@ -159,7 +162,7 @@ function validateForm() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (hasError.every((result) => result === true)) {
|
if (hasError.every((result) => result === true)) {
|
||||||
countNum.value = 1
|
countNum.value = 1;
|
||||||
onSubmit();
|
onSubmit();
|
||||||
} else {
|
} else {
|
||||||
console.log("ไม่ผ่าน ");
|
console.log("ไม่ผ่าน ");
|
||||||
|
|
@ -247,7 +250,7 @@ watch(props.data, async () => {
|
||||||
formData.status = props.data.status;
|
formData.status = props.data.status;
|
||||||
formData.result = props.data.result;
|
formData.result = props.data.result;
|
||||||
formData.persons = mainStore.rowsAdd;
|
formData.persons = mainStore.rowsAdd;
|
||||||
}else if (countNum.value === 2){
|
} else if (countNum.value === 2) {
|
||||||
fileList.value = props.data.disciplineComplaintDocs;
|
fileList.value = props.data.disciplineComplaintDocs;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -273,7 +276,7 @@ function upLoadFileDoc() {
|
||||||
.put(config.API.complaintFileUpload(formData.id), Data)
|
.put(config.API.complaintFileUpload(formData.id), Data)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
success($q, "อัพโหลดไฟล์สำเร็จ");
|
success($q, "อัพโหลดไฟล์สำเร็จ");
|
||||||
countNum.value = 2
|
countNum.value = 2;
|
||||||
props.getData();
|
props.getData();
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
|
|
@ -339,6 +342,15 @@ function inputEdit(val: boolean) {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function onclickViewinfo(id: string) {
|
||||||
|
modalPersonal.value = true;
|
||||||
|
personId.value = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
function updatemodalPersonal(modal: boolean) {
|
||||||
|
modalPersonal.value = modal;
|
||||||
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
mainStore.rowsAdd = [];
|
mainStore.rowsAdd = [];
|
||||||
getListChannel();
|
getListChannel();
|
||||||
|
|
@ -521,15 +533,16 @@ onMounted(() => {
|
||||||
<template v-slot:body="props">
|
<template v-slot:body="props">
|
||||||
<q-tr :props="props" class="cursor-pointer">
|
<q-tr :props="props" class="cursor-pointer">
|
||||||
<td>
|
<td>
|
||||||
<router-link
|
<q-btn
|
||||||
target="_blank"
|
dense
|
||||||
:to="`/registry/${props.row.personId}`"
|
flat
|
||||||
><q-icon name="info" color="info" size="sm"
|
round
|
||||||
><q-tooltip
|
color="info"
|
||||||
>ดูข้อมูลในทะเบียนประวัติ</q-tooltip
|
icon="info"
|
||||||
>
|
@click="onclickViewinfo(props.row.personId)"
|
||||||
</q-icon></router-link
|
|
||||||
>
|
>
|
||||||
|
<q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
</td>
|
</td>
|
||||||
<q-td
|
<q-td
|
||||||
v-for="col in props.cols"
|
v-for="col in props.cols"
|
||||||
|
|
@ -979,6 +992,12 @@ onMounted(() => {
|
||||||
:selected-data="mainStore.rowsAdd"
|
:selected-data="mainStore.rowsAdd"
|
||||||
@returnData="handleSave"
|
@returnData="handleSave"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
<PopupPersonal
|
||||||
|
:modal="modalPersonal"
|
||||||
|
:id="personId"
|
||||||
|
@update:modal="updatemodalPersonal"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,7 @@ import { useDisciplineMainStore } from "@/modules/11_discipline/store/main";
|
||||||
|
|
||||||
import CalandarDialog from "@/modules/11_discipline/components/2_InvestigateFacts/CalandarDialog.vue";
|
import CalandarDialog from "@/modules/11_discipline/components/2_InvestigateFacts/CalandarDialog.vue";
|
||||||
import DialogDuty from "@/modules/11_discipline/components/DialogDuty.vue";
|
import DialogDuty from "@/modules/11_discipline/components/DialogDuty.vue";
|
||||||
|
import PopupPersonal from "@/components/Dialogs/PopupPersonal.vue";
|
||||||
|
|
||||||
import type {
|
import type {
|
||||||
FormData,
|
FormData,
|
||||||
|
|
@ -24,6 +25,9 @@ import type { ArrayPersonAdd } from "@/modules/11_discipline/interface/response/
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
|
|
||||||
|
const modalPersonal = ref<boolean>(false);
|
||||||
|
const personId = ref<string>("");
|
||||||
|
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
|
|
@ -617,6 +621,15 @@ async function saveDuty(id: string, duty: string, resolution: string) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function onclickViewinfo(id: string) {
|
||||||
|
modalPersonal.value = true;
|
||||||
|
personId.value = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
function updatemodalPersonal(modal: boolean) {
|
||||||
|
modalPersonal.value = modal;
|
||||||
|
}
|
||||||
|
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
mainStore.rowsAdd = [];
|
mainStore.rowsAdd = [];
|
||||||
getOc();
|
getOc();
|
||||||
|
|
@ -771,15 +784,16 @@ onMounted(async () => {
|
||||||
<template v-slot:body="props">
|
<template v-slot:body="props">
|
||||||
<q-tr :props="props" class="cursor-pointer">
|
<q-tr :props="props" class="cursor-pointer">
|
||||||
<td>
|
<td>
|
||||||
<router-link
|
<q-btn
|
||||||
target="_blank"
|
dense
|
||||||
:to="`/registry/${props.row.personId}`"
|
flat
|
||||||
><q-icon name="info" color="info" size="sm"
|
round
|
||||||
><q-tooltip
|
color="info"
|
||||||
>ดูข้อมูลในทะเบียนประวัติ</q-tooltip
|
icon="info"
|
||||||
>
|
@click="onclickViewinfo(props.row.personId)"
|
||||||
</q-icon></router-link
|
>
|
||||||
>
|
<q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
</td>
|
</td>
|
||||||
<q-td
|
<q-td
|
||||||
v-for="col in props.cols"
|
v-for="col in props.cols"
|
||||||
|
|
@ -1564,6 +1578,13 @@ onMounted(async () => {
|
||||||
:checked-val="false"
|
:checked-val="false"
|
||||||
:fetch-data="fetchData"
|
:fetch-data="fetchData"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
<PopupPersonal
|
||||||
|
:modal="modalPersonal"
|
||||||
|
:id="personId"
|
||||||
|
@update:modal="updatemodalPersonal"
|
||||||
|
/>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scope>
|
<style scope>
|
||||||
|
|
|
||||||
|
|
@ -35,6 +35,10 @@ import { useComplainstDataStore } from "@/modules/11_discipline/store/Complaints
|
||||||
import { useInvestigateDisStore } from "@/modules/11_discipline/store/InvestigateDisStore";
|
import { useInvestigateDisStore } from "@/modules/11_discipline/store/InvestigateDisStore";
|
||||||
import { useDisciplineMainStore } from "@/modules/11_discipline/store/main";
|
import { useDisciplineMainStore } from "@/modules/11_discipline/store/main";
|
||||||
import DialogDuty from "@/modules/11_discipline/components/DialogDuty.vue";
|
import DialogDuty from "@/modules/11_discipline/components/DialogDuty.vue";
|
||||||
|
import PopupPersonal from "@/components/Dialogs/PopupPersonal.vue";
|
||||||
|
|
||||||
|
const modalPersonal = ref<boolean>(false);
|
||||||
|
const personId = ref<string>("");
|
||||||
|
|
||||||
const calendarModal = ref<boolean>(false);
|
const calendarModal = ref<boolean>(false);
|
||||||
const calendarModalclose = () => (calendarModal.value = !calendarModal.value);
|
const calendarModalclose = () => (calendarModal.value = !calendarModal.value);
|
||||||
|
|
@ -613,6 +617,15 @@ async function saveDuty(id: string, duty: string, resolution: string) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function onclickViewinfo(id: string) {
|
||||||
|
modalPersonal.value = true;
|
||||||
|
personId.value = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
function updatemodalPersonal(modal: boolean) {
|
||||||
|
modalPersonal.value = modal;
|
||||||
|
}
|
||||||
|
|
||||||
/** Hook */
|
/** Hook */
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
mainStore.rowsAdd = [];
|
mainStore.rowsAdd = [];
|
||||||
|
|
@ -808,15 +821,16 @@ onMounted(async () => {
|
||||||
<template v-slot:body="props">
|
<template v-slot:body="props">
|
||||||
<q-tr :props="props" class="cursor-pointer">
|
<q-tr :props="props" class="cursor-pointer">
|
||||||
<td>
|
<td>
|
||||||
<router-link
|
<q-btn
|
||||||
target="_blank"
|
dense
|
||||||
:to="`/registry/${props.row.personId}`"
|
flat
|
||||||
><q-icon name="info" color="info" size="sm"
|
round
|
||||||
><q-tooltip
|
color="info"
|
||||||
>ดูข้อมูลในทะเบียนประวัติ</q-tooltip
|
icon="info"
|
||||||
>
|
@click="onclickViewinfo(props.row.personId)"
|
||||||
</q-icon></router-link
|
>
|
||||||
>
|
<q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
</td>
|
</td>
|
||||||
<q-td
|
<q-td
|
||||||
v-for="col in props.cols"
|
v-for="col in props.cols"
|
||||||
|
|
@ -1811,6 +1825,12 @@ onMounted(async () => {
|
||||||
:checked-val="false"
|
:checked-val="false"
|
||||||
:fetch-data="fetchDataList"
|
:fetch-data="fetchDataList"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
<PopupPersonal
|
||||||
|
:modal="modalPersonal"
|
||||||
|
:id="personId"
|
||||||
|
@update:modal="updatemodalPersonal"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,7 @@ import { useInvestigateDisStore } from "@/modules/11_discipline/store/Investigat
|
||||||
import { useDisciplineResultStore } from "@/modules/11_discipline/store/ResultStore";
|
import { useDisciplineResultStore } from "@/modules/11_discipline/store/ResultStore";
|
||||||
import { useDisciplineMainStore } from "@/modules/11_discipline/store/main";
|
import { useDisciplineMainStore } from "@/modules/11_discipline/store/main";
|
||||||
import DialogHistory from "@/modules/11_discipline/components/4_Result/DialogHistory.vue";
|
import DialogHistory from "@/modules/11_discipline/components/4_Result/DialogHistory.vue";
|
||||||
|
import PopupPersonal from "@/components/Dialogs/PopupPersonal.vue";
|
||||||
|
|
||||||
import type {
|
import type {
|
||||||
FormData,
|
FormData,
|
||||||
|
|
@ -19,6 +20,9 @@ import type {
|
||||||
} from "@/modules/11_discipline/interface/request/result";
|
} from "@/modules/11_discipline/interface/request/result";
|
||||||
import DialogHeader from "@/components/DialogHeader.vue";
|
import DialogHeader from "@/components/DialogHeader.vue";
|
||||||
|
|
||||||
|
const modalPersonal = ref<boolean>(false);
|
||||||
|
const personId = ref<string>("");
|
||||||
|
|
||||||
const countNum = ref<number>(1);
|
const countNum = ref<number>(1);
|
||||||
const mainStore = useDisciplineMainStore();
|
const mainStore = useDisciplineMainStore();
|
||||||
const modalPerson = ref<boolean>(false);
|
const modalPerson = ref<boolean>(false);
|
||||||
|
|
@ -250,6 +254,16 @@ function closeDetail() {
|
||||||
modalHistory.value = false;
|
modalHistory.value = false;
|
||||||
personalId.value = "";
|
personalId.value = "";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function onclickViewinfo(id: string) {
|
||||||
|
modalPersonal.value = true;
|
||||||
|
personId.value = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
function updatemodalPersonal(modal: boolean) {
|
||||||
|
modalPersonal.value = modal;
|
||||||
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<div class="row q-col-gutter-sm">
|
<div class="row q-col-gutter-sm">
|
||||||
|
|
@ -363,13 +377,16 @@ function closeDetail() {
|
||||||
<template v-slot:body="props">
|
<template v-slot:body="props">
|
||||||
<q-tr :props="props" class="cursor-pointer">
|
<q-tr :props="props" class="cursor-pointer">
|
||||||
<td>
|
<td>
|
||||||
<router-link
|
<q-btn
|
||||||
target="_blank"
|
dense
|
||||||
:to="`/registry/${props.row.personId}`"
|
flat
|
||||||
><q-icon name="info" color="info" size="sm"
|
round
|
||||||
><q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
color="info"
|
||||||
</q-icon></router-link
|
icon="info"
|
||||||
>
|
@click="onclickViewinfo(props.row.personId)"
|
||||||
|
>
|
||||||
|
<q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
</td>
|
</td>
|
||||||
<q-td
|
<q-td
|
||||||
v-for="col in props.cols"
|
v-for="col in props.cols"
|
||||||
|
|
@ -586,6 +603,12 @@ function closeDetail() {
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<PopupPersonal
|
||||||
|
:modal="modalPersonal"
|
||||||
|
:id="personId"
|
||||||
|
@update:modal="updatemodalPersonal"
|
||||||
|
/>
|
||||||
|
|
||||||
<DialogHistory
|
<DialogHistory
|
||||||
:modal="modalHistory"
|
:modal="modalHistory"
|
||||||
:close="closeDetail"
|
:close="closeDetail"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue