isLeave
This commit is contained in:
parent
979ecb381f
commit
9d3601f23f
32 changed files with 262 additions and 79 deletions
|
|
@ -9,6 +9,7 @@ import {
|
|||
checkPermissionList,
|
||||
} from "@/utils/permissions";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useRegistryNewDataStore } from "@/modules/04_registryPerson/store";
|
||||
import http from "@/plugins/http";
|
||||
import config from "@/app.config";
|
||||
import axios from "axios";
|
||||
|
|
@ -37,6 +38,7 @@ import TabMain from "@/modules/04_registryPerson/components/detail/TabMain.vue";
|
|||
const $q = useQuasar();
|
||||
const router = useRouter();
|
||||
const route = useRoute();
|
||||
const storeRegistry = useRegistryNewDataStore();
|
||||
const {
|
||||
dialogRemove,
|
||||
dialogConfirm,
|
||||
|
|
@ -269,6 +271,7 @@ async function fetchDataPersonal() {
|
|||
.get(config.API.registryNewByProfileId(profileId.value, empType.value))
|
||||
.then(async (res) => {
|
||||
formDetail.value = res.data.result;
|
||||
storeRegistry.isLeave = res.data.result.isLeave;
|
||||
|
||||
if (res.data.result.leaveReason) {
|
||||
// เหตุผลพ้นจากราชการต่อท้ายชื่อ
|
||||
|
|
@ -686,6 +689,7 @@ onMounted(async () => {
|
|||
<!-- list menu ของข้าราชการฯ -->
|
||||
<q-btn-dropdown
|
||||
v-if="
|
||||
!storeRegistry.isLeave &&
|
||||
empType === '' &&
|
||||
checkPermissionList([
|
||||
'SYS_TEMPDUTY',
|
||||
|
|
@ -733,6 +737,7 @@ onMounted(async () => {
|
|||
<!-- list menu ของลูกจ้างประจำ -->
|
||||
<q-btn-dropdown
|
||||
v-if="
|
||||
!storeRegistry.isLeave &&
|
||||
empType === '-employee' &&
|
||||
checkPermissionList(['SYS_PROMOTION_EMP', 'SYS_PASSAWAY'])
|
||||
"
|
||||
|
|
@ -828,7 +833,7 @@ onMounted(async () => {
|
|||
<q-img :src="profilePicture" />
|
||||
</q-avatar>
|
||||
<q-btn
|
||||
v-if="checkPermission($route)?.attrIsUpdate"
|
||||
v-if="!storeRegistry.isLeave && checkPermission($route)?.attrIsUpdate"
|
||||
round
|
||||
text-color="edit"
|
||||
icon="mdi-pencil"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue