ประกาศเกษียณอายุราชการ สิทธิ์
This commit is contained in:
parent
080ac1cbb3
commit
dd5c3a42f6
4 changed files with 76 additions and 59 deletions
|
|
@ -16,6 +16,7 @@ const personId = ref<string>("");
|
||||||
/** Use */
|
/** Use */
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
|
const checkRoutePermisson = ref<boolean>(route.name == "retirementidDetail");
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const {
|
const {
|
||||||
|
|
@ -455,6 +456,7 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
:profile-id="profileId"
|
:profile-id="profileId"
|
||||||
:UpdateListId="UpdateListId"
|
:UpdateListId="UpdateListId"
|
||||||
v-if="
|
v-if="
|
||||||
|
!checkRoutePermisson &&
|
||||||
statusReport === false &&
|
statusReport === false &&
|
||||||
(typeReport == 'ADD' || typeReport == '' || typeReport == null) &&
|
(typeReport == 'ADD' || typeReport == '' || typeReport == null) &&
|
||||||
statusUpload !== true
|
statusUpload !== true
|
||||||
|
|
@ -471,7 +473,7 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
(modalUpload = true), (signDate = null), (fileUpload = null)
|
(modalUpload = true), (signDate = null), (fileUpload = null)
|
||||||
"
|
"
|
||||||
target="_blank"
|
target="_blank"
|
||||||
v-if="statusUpload !== true"
|
v-if="statusUpload !== true && !checkRoutePermisson"
|
||||||
>
|
>
|
||||||
<q-item-section avatar
|
<q-item-section avatar
|
||||||
><q-icon color="blue" name="attach_file"
|
><q-icon color="blue" name="attach_file"
|
||||||
|
|
@ -479,6 +481,7 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
<q-item-section>อัปโหลดไฟล์ </q-item-section>
|
<q-item-section>อัปโหลดไฟล์ </q-item-section>
|
||||||
</q-item>
|
</q-item>
|
||||||
<q-item
|
<q-item
|
||||||
|
v-if="!checkRoutePermisson"
|
||||||
clickable
|
clickable
|
||||||
v-close-popup
|
v-close-popup
|
||||||
type="a"
|
type="a"
|
||||||
|
|
@ -490,7 +493,7 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
/></q-item-section>
|
/></q-item-section>
|
||||||
<q-item-section>แก้ไข มติ อ.ก.ก. </q-item-section>
|
<q-item-section>แก้ไข มติ อ.ก.ก. </q-item-section>
|
||||||
</q-item>
|
</q-item>
|
||||||
<q-separator />
|
<q-separator v-if="!checkRoutePermisson" />
|
||||||
<q-item
|
<q-item
|
||||||
clickable
|
clickable
|
||||||
v-close-popup
|
v-close-popup
|
||||||
|
|
@ -591,26 +594,6 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
<q-th auto-width />
|
<q-th auto-width />
|
||||||
<q-th
|
|
||||||
auto-width
|
|
||||||
v-if="
|
|
||||||
(typeReport === 'EDIT' ||
|
|
||||||
typeReport === null ||
|
|
||||||
typeReport === '') &&
|
|
||||||
statusReport === false &&
|
|
||||||
statusUpload !== true
|
|
||||||
"
|
|
||||||
/>
|
|
||||||
<q-th
|
|
||||||
auto-width
|
|
||||||
v-if="
|
|
||||||
(typeReport === 'REMOVE' ||
|
|
||||||
typeReport === null ||
|
|
||||||
typeReport === '') &&
|
|
||||||
statusReport === false &&
|
|
||||||
statusUpload !== true
|
|
||||||
"
|
|
||||||
/>
|
|
||||||
<q-th v-for="col in props.cols" :key="col.name" :props="props">
|
<q-th v-for="col in props.cols" :key="col.name" :props="props">
|
||||||
<div class="text-grey-7 text-weight-medium">
|
<div class="text-grey-7 text-weight-medium">
|
||||||
<span class="row">{{ col.title }}</span>
|
<span class="row">{{ col.title }}</span>
|
||||||
|
|
@ -619,19 +602,20 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
}}</span>
|
}}</span>
|
||||||
</div>
|
</div>
|
||||||
</q-th>
|
</q-th>
|
||||||
|
|
||||||
</q-tr>
|
</q-tr>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:body="props">
|
<template v-slot:body="props">
|
||||||
<q-tr
|
<q-tr
|
||||||
:props="props"
|
:props="props"
|
||||||
class="cursor-pointer"
|
|
||||||
:style="props.row.profileId === profileId && 'color: #26a69a;'"
|
:style="props.row.profileId === profileId && 'color: #26a69a;'"
|
||||||
@click.stop="onclickViewinfo(props.row.profileId)"
|
|
||||||
>
|
>
|
||||||
<q-td auto-width>
|
<q-td auto-width>
|
||||||
|
<q-btn flat round dense icon="mdi-eye" color="info" @click.stop="onclickViewinfo(props.row.profileId)">
|
||||||
|
<q-tooltip>ดูข้อมูลในทะเบียนประวัติ</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
<q-btn
|
<q-btn
|
||||||
v-if="
|
v-if="!checkRoutePermisson&&
|
||||||
(props.row.remove === 'EDIT' ||
|
(props.row.remove === 'EDIT' ||
|
||||||
props.row.remove === 'REMOVE') &&
|
props.row.remove === 'REMOVE') &&
|
||||||
statusUpload
|
statusUpload
|
||||||
|
|
@ -649,18 +633,15 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
"
|
"
|
||||||
><q-tooltip>ข้อมูล</q-tooltip></q-btn
|
><q-tooltip>ข้อมูล</q-tooltip></q-btn
|
||||||
>
|
>
|
||||||
</q-td>
|
|
||||||
<q-td
|
|
||||||
auto-width
|
|
||||||
v-if="
|
|
||||||
(typeReport === 'EDIT' ||
|
|
||||||
typeReport === null ||
|
|
||||||
typeReport === '') &&
|
|
||||||
statusReport === false &&
|
|
||||||
statusUpload !== true
|
|
||||||
"
|
|
||||||
>
|
|
||||||
<q-btn
|
<q-btn
|
||||||
|
v-if="
|
||||||
|
!checkRoutePermisson &&
|
||||||
|
(typeReport === 'EDIT' ||
|
||||||
|
typeReport === null ||
|
||||||
|
typeReport === '') &&
|
||||||
|
statusReport === false &&
|
||||||
|
statusUpload !== true
|
||||||
|
"
|
||||||
flat
|
flat
|
||||||
round
|
round
|
||||||
color="primary"
|
color="primary"
|
||||||
|
|
@ -675,21 +656,18 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
>
|
>
|
||||||
<q-tooltip>กรอกเหตุผล</q-tooltip>
|
<q-tooltip>กรอกเหตุผล</q-tooltip>
|
||||||
</q-btn>
|
</q-btn>
|
||||||
</q-td>
|
|
||||||
<q-td
|
|
||||||
auto-width
|
|
||||||
v-if="
|
|
||||||
(typeReport === 'REMOVE' ||
|
|
||||||
typeReport === null ||
|
|
||||||
typeReport === '') &&
|
|
||||||
statusReport === false &&
|
|
||||||
statusUpload !== true
|
|
||||||
"
|
|
||||||
>
|
|
||||||
<q-btn
|
<q-btn
|
||||||
|
v-if="
|
||||||
|
!checkRoutePermisson &&
|
||||||
|
(typeReport === 'REMOVE' ||
|
||||||
|
typeReport === null ||
|
||||||
|
typeReport === '') &&
|
||||||
|
statusReport === false &&
|
||||||
|
statusUpload !== true
|
||||||
|
"
|
||||||
flat
|
flat
|
||||||
round
|
round
|
||||||
class="text-red-14"
|
color="red"
|
||||||
:icon="props.row.remove === 'REMOVE' ? 'info' : 'mdi-delete'"
|
:icon="props.row.remove === 'REMOVE' ? 'info' : 'mdi-delete'"
|
||||||
dense
|
dense
|
||||||
@click.stop="
|
@click.stop="
|
||||||
|
|
@ -727,8 +705,6 @@ function updatemodalPersonal(modal: boolean) {
|
||||||
<q-td class="table_ellipsis" key="organization" :props="props">{{
|
<q-td class="table_ellipsis" key="organization" :props="props">{{
|
||||||
props.row.organization ? props.row.organization : "-"
|
props.row.organization ? props.row.organization : "-"
|
||||||
}}</q-td>
|
}}</q-td>
|
||||||
|
|
||||||
|
|
||||||
</q-tr>
|
</q-tr>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:pagination="scope">
|
<template v-slot:pagination="scope">
|
||||||
|
|
|
||||||
|
|
@ -109,7 +109,7 @@ const cerateRetirement = async (data: object) => {
|
||||||
@click="clickAdd"
|
@click="clickAdd"
|
||||||
:disable="checkjson"
|
:disable="checkjson"
|
||||||
>
|
>
|
||||||
<q-tooltip>เพิ่ม</q-tooltip>
|
<q-tooltip>เพิ่มข้อมูล</q-tooltip>
|
||||||
</q-btn>
|
</q-btn>
|
||||||
<q-dialog v-model="modal" persistent>
|
<q-dialog v-model="modal" persistent>
|
||||||
<q-card style="width: 450px; max-width: 80vw">
|
<q-card style="width: 450px; max-width: 80vw">
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,8 @@
|
||||||
const Main = () => import("@/modules/06_retirement/views/Main.vue");
|
const Main = () => import("@/modules/06_retirement/views/Main.vue");
|
||||||
const Listretirement = () =>
|
const Listretirement = () =>
|
||||||
import("@/modules/06_retirement/components/ListRetirement/TableList.vue");
|
import("@/modules/06_retirement/components/ListRetirement/TableList.vue");
|
||||||
|
const ListretirementDetail = () =>
|
||||||
|
import("@/modules/06_retirement/components/ListRetirement/TableList.vue");
|
||||||
// const resignOrder = () =>
|
// const resignOrder = () =>
|
||||||
// import("@/modules/06_retirement/components/resign/ResignOrder.vue");
|
// import("@/modules/06_retirement/components/resign/ResignOrder.vue");
|
||||||
const resign = () =>
|
const resign = () =>
|
||||||
|
|
@ -60,6 +62,16 @@ export default [
|
||||||
Role: "STAFF",
|
Role: "STAFF",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: "/retirement-detail/:retirementId",
|
||||||
|
name: "retirementidDetail",
|
||||||
|
component: ListretirementDetail,
|
||||||
|
meta: {
|
||||||
|
Auth: true,
|
||||||
|
Key: "SYS_RETIREMENT",
|
||||||
|
Role: "STAFF",
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
path: "/retirement/listretire/:id/:type",
|
path: "/retirement/listretire/:id/:type",
|
||||||
name: "retirement/list/id/type",
|
name: "retirement/list/id/type",
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,8 @@ import type { resMain } from "@/modules/06_retirement/interface/response/Main";
|
||||||
import { storeToRefs } from "pinia";
|
import { storeToRefs } from "pinia";
|
||||||
import popupAdd from "../components/ListRetirement/popupAdd.vue";
|
import popupAdd from "../components/ListRetirement/popupAdd.vue";
|
||||||
|
|
||||||
|
import { checkPermission } from "@/utils/permissions";
|
||||||
|
|
||||||
const useStoreRetire = useDataStoreRetirement();
|
const useStoreRetire = useDataStoreRetirement();
|
||||||
const { clickTab } = useStoreRetire;
|
const { clickTab } = useStoreRetire;
|
||||||
const { tab, type } = storeToRefs(useDataStoreRetirement());
|
const { tab, type } = storeToRefs(useDataStoreRetirement());
|
||||||
|
|
@ -195,6 +197,9 @@ const paginationLabel = (start: string, end: string, total: string) => {
|
||||||
const nextPage = (prop: any) => {
|
const nextPage = (prop: any) => {
|
||||||
router.push(`/retirement/${prop.id}`);
|
router.push(`/retirement/${prop.id}`);
|
||||||
};
|
};
|
||||||
|
const nextPageDetail = (prop: any) => {
|
||||||
|
router.push(`/retirement-detail/${prop.id}`);
|
||||||
|
};
|
||||||
|
|
||||||
watch(type, () => {
|
watch(type, () => {
|
||||||
fetchRetirement(type.value, currentYear);
|
fetchRetirement(type.value, currentYear);
|
||||||
|
|
@ -278,7 +283,7 @@ const typeReportChangeName = (val: string) => {
|
||||||
</q-select>
|
</q-select>
|
||||||
|
|
||||||
<!-- use-input -->
|
<!-- use-input -->
|
||||||
<div>
|
<div v-if="checkPermission($route)?.attrIsCreate">
|
||||||
<popupAdd
|
<popupAdd
|
||||||
:type="useStoreRetire.type"
|
:type="useStoreRetire.type"
|
||||||
:year="fiscalyear"
|
:year="fiscalyear"
|
||||||
|
|
@ -345,6 +350,7 @@ const typeReportChangeName = (val: string) => {
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
<q-th auto-width> </q-th>
|
||||||
<q-th
|
<q-th
|
||||||
v-for="col in props.cols"
|
v-for="col in props.cols"
|
||||||
:key="col.name"
|
:key="col.name"
|
||||||
|
|
@ -355,11 +361,34 @@ const typeReportChangeName = (val: string) => {
|
||||||
</q-tr>
|
</q-tr>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:body="props">
|
<template v-slot:body="props">
|
||||||
<q-tr
|
<q-tr :props="props">
|
||||||
:props="props"
|
<q-td auto-width>
|
||||||
class="cursor-pointer"
|
<q-btn
|
||||||
@click="nextPage(props.row)"
|
v-if="checkPermission($route)?.attrIsGet"
|
||||||
>
|
flat
|
||||||
|
round
|
||||||
|
dense
|
||||||
|
icon="mdi-eye"
|
||||||
|
color="info"
|
||||||
|
@click="nextPageDetail(props.row)"
|
||||||
|
>
|
||||||
|
<q-tooltip>รายละเอียด</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
|
<q-btn
|
||||||
|
v-if="
|
||||||
|
checkPermission($route)?.attrIsGet &&
|
||||||
|
checkPermission($route)?.attrIsUpdate
|
||||||
|
"
|
||||||
|
flat
|
||||||
|
round
|
||||||
|
dense
|
||||||
|
icon="edit"
|
||||||
|
color="edit"
|
||||||
|
@click="nextPage(props.row)"
|
||||||
|
>
|
||||||
|
<q-tooltip>แก้ไขข้อมูล</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
|
</q-td>
|
||||||
<q-td key="no" :props="props">
|
<q-td key="no" :props="props">
|
||||||
{{ props.rowIndex + 1 }}
|
{{ props.rowIndex + 1 }}
|
||||||
</q-td>
|
</q-td>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue