สิทธิ์ สรุปผลการพิจารณาความผิดทางวินัย
This commit is contained in:
parent
47ce1ce70d
commit
f853c76401
8 changed files with 91 additions and 27 deletions
|
|
@ -1045,7 +1045,7 @@ function filterOptionFnAgency(val: string, update: Function) {
|
|||
dense
|
||||
color="red"
|
||||
class="q-ml-sm"
|
||||
icon="mdi-delete-outline"
|
||||
icon="mdi-delete"
|
||||
@click="deleteFile(data.id)"
|
||||
><q-tooltip>ลบไฟล์</q-tooltip></q-btn
|
||||
>
|
||||
|
|
|
|||
|
|
@ -901,7 +901,7 @@ onMounted(async () => {
|
|||
col.label
|
||||
}}</span>
|
||||
</q-th>
|
||||
<q-th auto-width></q-th>
|
||||
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:body="props">
|
||||
|
|
@ -912,7 +912,7 @@ onMounted(async () => {
|
|||
flat
|
||||
round
|
||||
color="info"
|
||||
icon="info"
|
||||
icon="mdi-eye"
|
||||
@click="onclickViewinfo(props.row.personId)"
|
||||
>
|
||||
<q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
||||
|
|
@ -1530,9 +1530,9 @@ onMounted(async () => {
|
|||
dense
|
||||
flat
|
||||
round
|
||||
color="blue"
|
||||
color="edit"
|
||||
@click="openEditDirector(props.row)"
|
||||
icon="mdi-pencil-outline"
|
||||
icon="edit"
|
||||
>
|
||||
<q-tooltip>แก้ไข</q-tooltip>
|
||||
</q-btn>
|
||||
|
|
@ -1544,7 +1544,7 @@ onMounted(async () => {
|
|||
round
|
||||
color="red"
|
||||
@click="deleteDirector(props.row.id)"
|
||||
icon="mdi-delete-outline"
|
||||
icon="mdi-delete"
|
||||
>
|
||||
<q-tooltip>ลบข้อมูล</q-tooltip>
|
||||
</q-btn>
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ const modal = ref<boolean>(false);
|
|||
const dataResult = ref<DataListRow[]>([]);
|
||||
const filterKeyword = ref<string>("");
|
||||
const dataDisciplinary = ref<object>([]);
|
||||
|
||||
const checkRoutePermisson = ref<boolean>(route.name == "disciplineResultDetail");
|
||||
const dataInvestigatefacts = reactive<FormInvestigateFact>({
|
||||
id: "",
|
||||
idComplaint: "",
|
||||
|
|
@ -285,9 +285,9 @@ onMounted(async () => {
|
|||
class="q-mr-sm"
|
||||
@click="$router.push(`/discipline-result`)"
|
||||
/>
|
||||
<div class="q-ma-none">แก้ไขผลการพิจารณาทางวินัย</div>
|
||||
<div class="q-ma-none">{{checkRoutePermisson ? 'รายละเอียดผลการพิจารณาทางวินัย':'แก้ไขผลการพิจารณาทางวินัย'}}</div>
|
||||
<q-space />
|
||||
<div class="q-gutter-x-sm">
|
||||
<div class="q-gutter-x-sm" v-if="!checkRoutePermisson">
|
||||
<q-btn
|
||||
v-if="status === 'DONE'"
|
||||
label="ส่งไปออกคำสั่ง"
|
||||
|
|
|
|||
|
|
@ -37,7 +37,9 @@ const {
|
|||
} = mixin;
|
||||
const router = useRouter();
|
||||
const route = useRoute();
|
||||
|
||||
const checkRoutePermisson = ref<boolean>(
|
||||
route.name == "disciplineResultDetail"
|
||||
);
|
||||
const $q = useQuasar();
|
||||
const id = ref<string>(route.params.id as string);
|
||||
const isSave = ref<boolean>(false); // มีการแก้ไขรอบันทึก
|
||||
|
|
@ -382,24 +384,33 @@ function updatemodalPersonal(modal: boolean) {
|
|||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:body="props">
|
||||
<q-tr :props="props" class="cursor-pointer">
|
||||
<q-tr :props="props">
|
||||
<td>
|
||||
<q-btn
|
||||
dense
|
||||
flat
|
||||
round
|
||||
color="info"
|
||||
icon="info"
|
||||
icon="mdi-eye"
|
||||
@click="onclickViewinfo(props.row.personId)"
|
||||
>
|
||||
<q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
||||
</q-btn>
|
||||
<q-btn
|
||||
dense
|
||||
flat
|
||||
round
|
||||
color="deep-purple"
|
||||
icon="mdi-history"
|
||||
@click="openDetial(props.row.personId)"
|
||||
>
|
||||
<q-tooltip>ประวัติ</q-tooltip>
|
||||
</q-btn>
|
||||
</td>
|
||||
<q-td
|
||||
v-for="col in props.cols"
|
||||
:key="col.name"
|
||||
:props="props"
|
||||
@click="openDetial(props.row.personId)"
|
||||
>
|
||||
<div v-if="col.name == 'no'">
|
||||
{{ props.rowIndex + 1 }}
|
||||
|
|
@ -430,6 +441,7 @@ function updatemodalPersonal(modal: boolean) {
|
|||
</div>
|
||||
<div class="col-12">
|
||||
<q-input
|
||||
:readonly="checkRoutePermisson"
|
||||
:class="inputEdit(isReadonly)"
|
||||
type="textarea"
|
||||
dense
|
||||
|
|
@ -444,6 +456,7 @@ function updatemodalPersonal(modal: boolean) {
|
|||
</div>
|
||||
<div class="col-3">
|
||||
<q-input
|
||||
:readonly="checkRoutePermisson"
|
||||
v-model="formData.disciplineType"
|
||||
dense
|
||||
:class="inputEdit(isReadonly)"
|
||||
|
|
@ -453,6 +466,7 @@ function updatemodalPersonal(modal: boolean) {
|
|||
</div>
|
||||
<div class="col-3">
|
||||
<q-input
|
||||
:readonly="checkRoutePermisson"
|
||||
v-model="formData.titleType"
|
||||
dense
|
||||
outlined
|
||||
|
|
@ -462,6 +476,7 @@ function updatemodalPersonal(modal: boolean) {
|
|||
</div>
|
||||
<div class="col-4">
|
||||
<q-input
|
||||
:readonly="checkRoutePermisson"
|
||||
v-model="formData.oc"
|
||||
dense
|
||||
outlined
|
||||
|
|
@ -476,6 +491,7 @@ function updatemodalPersonal(modal: boolean) {
|
|||
class="col-2"
|
||||
:locale="'th'"
|
||||
autoApply
|
||||
:readonly="checkRoutePermisson"
|
||||
year-picker
|
||||
:enableTimePicker="false"
|
||||
>
|
||||
|
|
@ -487,6 +503,7 @@ function updatemodalPersonal(modal: boolean) {
|
|||
<q-input
|
||||
dense
|
||||
:class="inputEdit(isReadonly)"
|
||||
:readonly="checkRoutePermisson"
|
||||
outlined
|
||||
:model-value="
|
||||
formData.year === 0 ? null : Number(formData.year) + 543
|
||||
|
|
@ -501,7 +518,10 @@ function updatemodalPersonal(modal: boolean) {
|
|||
>
|
||||
</q-icon>
|
||||
</template>
|
||||
<template v-if="formData.year" v-slot:append>
|
||||
<template
|
||||
v-if="!checkRoutePermisson && formData.year"
|
||||
v-slot:append
|
||||
>
|
||||
<q-icon
|
||||
name="cancel"
|
||||
@click.stop.prevent="formData.year = 0"
|
||||
|
|
@ -524,7 +544,10 @@ function updatemodalPersonal(modal: boolean) {
|
|||
อัปโหลดไฟล์เอกสารหลักฐาน
|
||||
</div>
|
||||
<div class="col-12"><q-separator /></div>
|
||||
<div class="row col-12 q-col-gutter-y-sm q-pa-sm">
|
||||
<div
|
||||
class="row col-12 q-col-gutter-y-sm q-pa-sm"
|
||||
v-if="!checkRoutePermisson"
|
||||
>
|
||||
<div class="col-12 row">
|
||||
<q-file
|
||||
for="inputFiles"
|
||||
|
|
@ -581,6 +604,7 @@ function updatemodalPersonal(modal: boolean) {
|
|||
><q-tooltip>ดาวน์โหลดไฟล์</q-tooltip></q-btn
|
||||
>
|
||||
<q-btn
|
||||
v-if="!checkRoutePermisson"
|
||||
size="12px"
|
||||
flat
|
||||
round
|
||||
|
|
@ -600,8 +624,8 @@ function updatemodalPersonal(modal: boolean) {
|
|||
</q-card>
|
||||
</div>
|
||||
|
||||
<div class="col-12"><q-separator /></div>
|
||||
<div class="row col-12 q-pa-sm">
|
||||
<div class="col-12" v-if="!checkRoutePermisson"><q-separator /></div>
|
||||
<div class="row col-12 q-pa-sm" v-if="!checkRoutePermisson">
|
||||
<q-space />
|
||||
<q-btn
|
||||
for="ButtonOnSubmit"
|
||||
|
|
|
|||
|
|
@ -64,6 +64,13 @@ async function updateQueryString(p: number, pS: number, key: string) {
|
|||
function openEdit(id: string) {
|
||||
router.push(`/discipline-result/${id}`);
|
||||
}
|
||||
/**
|
||||
* ไปหน้าแก้ไข
|
||||
* @param id ไอดีเฉพาะ รายบุคคล
|
||||
*/
|
||||
function openDetail(id: string) {
|
||||
router.push(`/discipline-result-detail/${id}`);
|
||||
}
|
||||
|
||||
function filterStatus(statusReturn: string) {
|
||||
status.value = statusReturn;
|
||||
|
|
@ -102,6 +109,7 @@ onMounted(async () => {
|
|||
:totalList="totalList"
|
||||
@update:queryString="updateQueryString"
|
||||
v-model:open-edit="openEdit"
|
||||
v-model:open-detail="openDetail"
|
||||
:filterStatus="filterStatus"
|
||||
>
|
||||
</Table>
|
||||
|
|
|
|||
|
|
@ -2,6 +2,8 @@
|
|||
import { ref, useAttrs, watch } from "vue";
|
||||
import { useDisciplineResultStore } from "@/modules/11_discipline/store/ResultStore";
|
||||
|
||||
import { checkPermission } from "@/utils/permissions";
|
||||
|
||||
const store = useDisciplineResultStore();
|
||||
const table = ref<any>(null);
|
||||
const filterRef = ref<any>(null);
|
||||
|
|
@ -33,6 +35,10 @@ const props = defineProps({
|
|||
type: Function,
|
||||
default: () => console.log("not function"),
|
||||
},
|
||||
openDetail: {
|
||||
type: Function,
|
||||
default: () => console.log("not function"),
|
||||
},
|
||||
filterStatus: {
|
||||
type: Function,
|
||||
default: () => console.log("not function"),
|
||||
|
|
@ -155,7 +161,11 @@ function filterOptionFn(val: string, update: Function) {
|
|||
<template v-if="statusFilter !== 'ALL'" v-slot:append>
|
||||
<q-icon
|
||||
name="cancel"
|
||||
@click.stop.prevent="(option = store.statusOptions),(statusFilter = 'ALL'), dataUpdate()"
|
||||
@click.stop.prevent="
|
||||
(option = store.statusOptions),
|
||||
(statusFilter = 'ALL'),
|
||||
dataUpdate()
|
||||
"
|
||||
class="cursor-pointer"
|
||||
/>
|
||||
</template>
|
||||
|
|
@ -213,6 +223,7 @@ function filterOptionFn(val: string, update: Function) {
|
|||
>
|
||||
<template v-slot:header="props">
|
||||
<q-tr :props="props">
|
||||
<q-th auto-width></q-th>
|
||||
<q-th v-for="col in props.cols" :key="col.name" :props="props">
|
||||
<span class="text-weight-medium" v-html="col.label" />
|
||||
</q-th>
|
||||
|
|
@ -220,12 +231,23 @@ function filterOptionFn(val: string, update: Function) {
|
|||
</template>
|
||||
<template v-slot:body="props">
|
||||
<q-tr :props="props" class="cursor-pointer">
|
||||
<q-td
|
||||
v-for="col in props.cols"
|
||||
:key="col.name"
|
||||
:props="props"
|
||||
@click="openEdit(props.row.id)"
|
||||
>
|
||||
<q-td auto-width>
|
||||
<q-btn flat round dense icon="mdi-eye" color="info" @click="openDetail(props.row.id)" v-if="checkPermission($route)?.attrIsGet">
|
||||
<q-tooltip>รายละเอียด</q-tooltip>
|
||||
</q-btn>
|
||||
<q-btn
|
||||
v-if="checkPermission($route)?.attrIsUpdate && checkPermission($route)?.attrIsGet"
|
||||
flat
|
||||
round
|
||||
dense
|
||||
icon="edit"
|
||||
color="edit"
|
||||
@click="openEdit(props.row.id)"
|
||||
>
|
||||
<q-tooltip>แก้ไขข้อมูล</q-tooltip>
|
||||
</q-btn>
|
||||
</q-td>
|
||||
<q-td v-for="col in props.cols" :key="col.name" :props="props">
|
||||
<div v-if="col.name == 'no'">
|
||||
{{
|
||||
(currentPage - 1) * Number(pagination.rowsPerPage) +
|
||||
|
|
|
|||
|
|
@ -184,7 +184,6 @@ function downloadFile(link: string) {
|
|||
dense
|
||||
flat
|
||||
round
|
||||
size="12px"
|
||||
color="blue"
|
||||
icon="mdi-download-outline"
|
||||
@click="downloadFile(f.pathName)"
|
||||
|
|
@ -198,9 +197,8 @@ function downloadFile(link: string) {
|
|||
dense
|
||||
flat
|
||||
round
|
||||
size="12px"
|
||||
color="red"
|
||||
icon="mdi-delete-outline"
|
||||
icon="mdi-delete"
|
||||
@click="popupRemove(f.id)"
|
||||
><q-tooltip>ลบเอกสาร</q-tooltip></q-btn
|
||||
>
|
||||
|
|
|
|||
|
|
@ -66,6 +66,8 @@ const resultMainPage = () =>
|
|||
import("@/modules/11_discipline/components/4_Result/MainPage.vue");
|
||||
const resultEditPage = () =>
|
||||
import("@/modules/11_discipline/components/4_Result/EditPage.vue");
|
||||
const resultDetailPage = () =>
|
||||
import("@/modules/11_discipline/components/4_Result/EditPage.vue");
|
||||
|
||||
// รายชื่อผู้ถูกพักราชการ
|
||||
const listSuspendMainPage = () =>
|
||||
|
|
@ -227,6 +229,16 @@ export default [
|
|||
Role: "STAFF",
|
||||
},
|
||||
},
|
||||
{
|
||||
path: "/discipline-result-detail/:id",
|
||||
name: "disciplineResultDetail",
|
||||
component: resultDetailPage,
|
||||
meta: {
|
||||
Auth: true,
|
||||
Key: "SYS_DISCIPLINE_RESULT",
|
||||
Role: "STAFF",
|
||||
},
|
||||
},
|
||||
// {
|
||||
// path: "/discipline/report",
|
||||
// name: "disciplineReport",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue