Merge branch 'develop' into devTee
This commit is contained in:
commit
5b89adca00
16 changed files with 117 additions and 197 deletions
|
|
@ -86,4 +86,7 @@ export default {
|
||||||
`${salary}/sub-file/${name}/${group}/${id}/${subId}`,
|
`${salary}/sub-file/${name}/${group}/${id}/${subId}`,
|
||||||
salaryUploadFile: (name: string, group: string, id: string, subId: string) =>
|
salaryUploadFile: (name: string, group: string, id: string, subId: string) =>
|
||||||
`${salary}/sub-file/${name}/${group}/${id}/${subId}`,
|
`${salary}/sub-file/${name}/${group}/${id}/${subId}`,
|
||||||
|
|
||||||
|
//รายชื่อออกคำสั่ง
|
||||||
|
orgPosSalaryReport: `${salary}/report/command/`,
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
{
|
{
|
||||||
name: "actFullName",
|
name: "actFullName",
|
||||||
align: "left",
|
align: "left",
|
||||||
label: "รักษาการ",
|
label: "รักษาการแทน",
|
||||||
field: "actFullName",
|
field: "actFullName",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
headerStyle: "font-size: 14px",
|
headerStyle: "font-size: 14px",
|
||||||
|
|
|
||||||
|
|
@ -448,7 +448,7 @@ watch(
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
v-if="prop.node.isDeputy == true && prop.node.orgLevel == 0"
|
v-if="prop.node.isDeputy == true && prop.node.orgLevel == 0"
|
||||||
class="text-red"
|
class="text-info"
|
||||||
>
|
>
|
||||||
{{ prop.node.orgTreeName }}
|
{{ prop.node.orgTreeName }}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -200,126 +200,5 @@ watch(
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- same address ? -->
|
|
||||||
<div class="col-xs-12 q-gutter-sm items-center flex q-my-sm">
|
|
||||||
<label class="text-medium"
|
|
||||||
>ที่อยู่ปัจจุบันตรงกับที่อยู่ตามทะเบียนบ้าน</label
|
|
||||||
>
|
|
||||||
<q-radio
|
|
||||||
dense
|
|
||||||
val="1"
|
|
||||||
label="ใช่"
|
|
||||||
checked-icon="task_alt"
|
|
||||||
class="inputgreen"
|
|
||||||
v-model="presentAddress"
|
|
||||||
unchecked-icon="panorama_fish_eye"
|
|
||||||
/>
|
|
||||||
<q-radio
|
|
||||||
dense
|
|
||||||
val="0"
|
|
||||||
label="ไม่"
|
|
||||||
checked-icon="task_alt"
|
|
||||||
class="inputgreen"
|
|
||||||
v-model="presentAddress"
|
|
||||||
unchecked-icon="panorama_fish_eye"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<!-- current address -->
|
|
||||||
<div v-if="presentAddress === '0'">
|
|
||||||
<div class="col-12 q-pb-xs">
|
|
||||||
<q-input
|
|
||||||
dense
|
|
||||||
outlined
|
|
||||||
lazy-rules
|
|
||||||
hide-bottom-space
|
|
||||||
class="inputgreen"
|
|
||||||
v-model="formDataAddress.currentAddress"
|
|
||||||
:label="dataLabel.currentAddress"
|
|
||||||
:rules="[(val:string) => !!val || `${'กรุณากรอก ที่อยู่ปัจจุบัน'}`]"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div class="row col-12 q-col-gutter-x-xs q-col-gutter-y-xs">
|
|
||||||
<div class="col-xs-6 col-sm-6 col-md-3">
|
|
||||||
<q-select
|
|
||||||
dense
|
|
||||||
outlined
|
|
||||||
use-input
|
|
||||||
lazy-rules
|
|
||||||
emit-value
|
|
||||||
map-options
|
|
||||||
hide-bottom-space
|
|
||||||
option-value="id"
|
|
||||||
option-label="name"
|
|
||||||
input-debounce="0"
|
|
||||||
class="inputgreen"
|
|
||||||
v-model="formDataAddress.currentProvinceId"
|
|
||||||
:options="storeLinkCenter.OpsAddress.provinceOps"
|
|
||||||
:label="dataLabel.currentProvince"
|
|
||||||
:rules="[(val:string) => !!val || `${'กรุณาเลือก จังหวัด'}`]"
|
|
||||||
@update:model-value="(value:string) => selectProvince(value, '2')"
|
|
||||||
@filter="(inputValue:string,
|
|
||||||
doneFn:Function) => storeLinkCenter.filterSelector(inputValue, doneFn,'provinceOps'
|
|
||||||
) "
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div class="col-xs-6 col-sm-6 col-md-3">
|
|
||||||
<q-select
|
|
||||||
dense
|
|
||||||
outlined
|
|
||||||
use-input
|
|
||||||
lazy-rules
|
|
||||||
emit-value
|
|
||||||
map-options
|
|
||||||
hide-bottom-space
|
|
||||||
option-value="id"
|
|
||||||
option-label="name"
|
|
||||||
input-debounce="0"
|
|
||||||
class="inputgreen"
|
|
||||||
v-model="formDataAddress.currentDistrictId"
|
|
||||||
:options="storeLinkCenter.OpsAddress.districtCOps"
|
|
||||||
:label="dataLabel.currentDistrict"
|
|
||||||
:rules="[(val:string) => !!val || `${'กรุณาเลือก เขต / อำเภอ'}`]"
|
|
||||||
@update:model-value="(value:string) => selectDistrict(value, '2')"
|
|
||||||
@filter="(inputValue:string,
|
|
||||||
doneFn:Function) => storeLinkCenter.filterSelector(inputValue, doneFn,'districtCOps'
|
|
||||||
) "
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div class="col-xs-6 col-sm-6 col-md-3">
|
|
||||||
<q-select
|
|
||||||
dense
|
|
||||||
outlined
|
|
||||||
use-input
|
|
||||||
lazy-rules
|
|
||||||
emit-value
|
|
||||||
map-options
|
|
||||||
hide-bottom-space
|
|
||||||
option-value="id"
|
|
||||||
option-label="name"
|
|
||||||
input-debounce="0"
|
|
||||||
class="inputgreen"
|
|
||||||
v-model="formDataAddress.currentSubDistrictId"
|
|
||||||
:options="storeLinkCenter.OpsAddress.subdistrictCOps"
|
|
||||||
:label="dataLabel.currentSubDistrict"
|
|
||||||
:rules="[(val:string) => !!val || `${'กรุณาเลือก แขวง / ตำบล'}`]"
|
|
||||||
@update:model-value="(value:string) => selectSubDistrict(value, '2')"
|
|
||||||
@filter="(inputValue:string,
|
|
||||||
doneFn:Function) => storeLinkCenter.filterSelector(inputValue, doneFn,'subdistrictCOps'
|
|
||||||
) "
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div class="col-xs-6 col-sm-6 col-md-3">
|
|
||||||
<q-input
|
|
||||||
dense
|
|
||||||
readonly
|
|
||||||
outlined
|
|
||||||
lazy-rules
|
|
||||||
hide-bottom-space
|
|
||||||
v-model="formDataAddress.currentZipCode"
|
|
||||||
:label="dataLabel.registrationZipCode"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
|
|
@ -955,7 +955,7 @@ onMounted(async () => {
|
||||||
>
|
>
|
||||||
</q-item>
|
</q-item>
|
||||||
|
|
||||||
<q-item
|
<!-- <q-item
|
||||||
v-if="
|
v-if="
|
||||||
props.row.bmaOfficer !== 'บุคคลภายนอก' &&
|
props.row.bmaOfficer !== 'บุคคลภายนอก' &&
|
||||||
roleAdmin &&
|
roleAdmin &&
|
||||||
|
|
@ -981,7 +981,7 @@ onMounted(async () => {
|
||||||
/>
|
/>
|
||||||
</q-item-section>
|
</q-item-section>
|
||||||
<q-item-section>เลือกหน่วยงานที่รับเลื่อน</q-item-section>
|
<q-item-section>เลือกหน่วยงานที่รับเลื่อน</q-item-section>
|
||||||
</q-item>
|
</q-item> -->
|
||||||
|
|
||||||
<q-item
|
<q-item
|
||||||
v-if="
|
v-if="
|
||||||
|
|
|
||||||
|
|
@ -93,7 +93,7 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
|
|
||||||
const modalCommand = ref<boolean>(false);
|
const modalCommand = ref<boolean>(false);
|
||||||
|
|
||||||
/** popup ยืนยันส่งัว */
|
/** popup ยืนยันส่งไปออกคำสั่ง */
|
||||||
function saveOrder() {
|
function saveOrder() {
|
||||||
dialogConfirm(
|
dialogConfirm(
|
||||||
$q,
|
$q,
|
||||||
|
|
@ -122,7 +122,7 @@ function convertText(val: string) {
|
||||||
case "PENDING":
|
case "PENDING":
|
||||||
return "รอดำเนินการ";
|
return "รอดำเนินการ";
|
||||||
case "REPORT":
|
case "REPORT":
|
||||||
return "ส่งไปเเต่งตั้ง";
|
return "ส่งไปออกคำสั่ง";
|
||||||
case "DONE":
|
case "DONE":
|
||||||
return "เสร็จสิ้น";
|
return "เสร็จสิ้น";
|
||||||
default:
|
default:
|
||||||
|
|
@ -136,6 +136,7 @@ watchEffect(() => {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<q-dialog v-model="props.modal">
|
<q-dialog v-model="props.modal">
|
||||||
<q-card style="width: 1200px; max-width: 80vw">
|
<q-card style="width: 1200px; max-width: 80vw">
|
||||||
|
|
@ -190,7 +191,7 @@ watchEffect(() => {
|
||||||
:filter="filterKeyword"
|
:filter="filterKeyword"
|
||||||
row-key="id"
|
row-key="id"
|
||||||
:visible-columns="visibleColumns"
|
:visible-columns="visibleColumns"
|
||||||
selection="multiple"
|
selection="single"
|
||||||
v-model:selected="selected"
|
v-model:selected="selected"
|
||||||
>
|
>
|
||||||
<template v-slot:header-selection="scope">
|
<template v-slot:header-selection="scope">
|
||||||
|
|
@ -243,7 +244,6 @@ watchEffect(() => {
|
||||||
</q-card-actions>
|
</q-card-actions>
|
||||||
</q-card>
|
</q-card>
|
||||||
</q-dialog>
|
</q-dialog>
|
||||||
|
|
||||||
<DialogCreateCommand
|
<DialogCreateCommand
|
||||||
v-model:modal="modalCommand"
|
v-model:modal="modalCommand"
|
||||||
:command-type-code="'C-PM-10'"
|
:command-type-code="'C-PM-10'"
|
||||||
|
|
|
||||||
|
|
@ -134,7 +134,7 @@ function convertText(val: string) {
|
||||||
case "PENDING":
|
case "PENDING":
|
||||||
return "รอดำเนินการ";
|
return "รอดำเนินการ";
|
||||||
case "REPORT":
|
case "REPORT":
|
||||||
return "ส่งไปเเต่งตั้ง";
|
return "ส่งไปออกคำสั่ง";
|
||||||
case "DONE":
|
case "DONE":
|
||||||
return "เสร็จสิ้น";
|
return "เสร็จสิ้น";
|
||||||
default:
|
default:
|
||||||
|
|
|
||||||
|
|
@ -1,38 +1,31 @@
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { reactive, computed, watch } from "vue";
|
import { reactive, computed, watch, ref } from "vue";
|
||||||
import { useQuasar } from "quasar";
|
import { useQuasar } from "quasar";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
|
||||||
import type { FormData } from "@/modules/11_discipline/interface/request/Director";
|
import type { FormData } from "@/modules/11_discipline/interface/request/director";
|
||||||
|
|
||||||
/**
|
/** importComponents*/
|
||||||
* importComponents
|
|
||||||
*/
|
|
||||||
import DialogHeader from "@/components/DialogHeader.vue";
|
import DialogHeader from "@/components/DialogHeader.vue";
|
||||||
import Form from "@/modules/12_evaluatePersonal/components/Director/Form.vue";
|
import Form from "@/modules/12_evaluatePersonal/components/Director/Form.vue";
|
||||||
|
|
||||||
/**
|
/** importStore*/
|
||||||
* importStore
|
|
||||||
*/
|
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
|
|
||||||
/**
|
/** use*/
|
||||||
* use
|
|
||||||
*/
|
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const { messageError, showLoader, hideLoader, dialogConfirm, success } =
|
const { messageError, showLoader, hideLoader, dialogConfirm, success } =
|
||||||
useCounterMixin();
|
useCounterMixin();
|
||||||
|
|
||||||
/**
|
/** props*/
|
||||||
* props
|
|
||||||
*/
|
|
||||||
const modal = defineModel<boolean>("modal", { required: true });
|
const modal = defineModel<boolean>("modal", { required: true });
|
||||||
const directorId = defineModel<string>("directorId", { required: true });
|
const directorId = defineModel<string>("directorId", { required: true });
|
||||||
const actionType = defineModel<string>("actionType", { required: true });
|
const actionType = defineModel<string>("actionType", { required: true });
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
fetchDataList: { type: Function, required: true },
|
fetchDataList: { type: Function, required: true },
|
||||||
});
|
});
|
||||||
|
const isLoad = ref<boolean>(false);
|
||||||
|
|
||||||
// ชื่อ Dialog
|
// ชื่อ Dialog
|
||||||
const title = computed(() =>
|
const title = computed(() =>
|
||||||
|
|
@ -55,12 +48,13 @@ const dataDettail = reactive<FormData>({
|
||||||
/**
|
/**
|
||||||
* function fetch ช้อมูลชื่อกรรมการ
|
* function fetch ช้อมูลชื่อกรรมการ
|
||||||
*/
|
*/
|
||||||
function fetchData() {
|
async function fetchData() {
|
||||||
|
isLoad.value = false;
|
||||||
showLoader();
|
showLoader();
|
||||||
http
|
await http
|
||||||
.get(config.API.evaluateDirectorById(directorId.value))
|
.get(config.API.evaluateDirectorById(directorId.value))
|
||||||
.then((res) => {
|
.then(async (res) => {
|
||||||
const data = res.data.result;
|
const data = await res.data.result;
|
||||||
dataDettail.personalId = data.Id;
|
dataDettail.personalId = data.Id;
|
||||||
dataDettail.prefix = data.prefix;
|
dataDettail.prefix = data.prefix;
|
||||||
dataDettail.firstname = data.firstName;
|
dataDettail.firstname = data.firstName;
|
||||||
|
|
@ -71,7 +65,10 @@ function fetchData() {
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
messageError($q, e);
|
messageError($q, e);
|
||||||
|
})
|
||||||
|
.finally(() => {
|
||||||
hideLoader();
|
hideLoader();
|
||||||
|
isLoad.value = true;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -114,8 +111,8 @@ function onCloseDialog() {
|
||||||
|
|
||||||
watch(
|
watch(
|
||||||
() => modal.value,
|
() => modal.value,
|
||||||
() => {
|
async () => {
|
||||||
modal.value && fetchData();
|
modal.value && (await fetchData());
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -125,6 +122,7 @@ watch(
|
||||||
<q-card style="width: 450px">
|
<q-card style="width: 450px">
|
||||||
<DialogHeader :tittle="title" :close="onCloseDialog" />
|
<DialogHeader :tittle="title" :close="onCloseDialog" />
|
||||||
<Form
|
<Form
|
||||||
|
v-if="isLoad"
|
||||||
:on-submit="onSubmit"
|
:on-submit="onSubmit"
|
||||||
:data="dataDettail"
|
:data="dataDettail"
|
||||||
:action-type="actionType"
|
:action-type="actionType"
|
||||||
|
|
|
||||||
|
|
@ -260,13 +260,9 @@ function inputEdit(val: boolean) {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(async () => {
|
||||||
if (props.data) {
|
if (props.data) {
|
||||||
showLoader();
|
await fetchForm(props.data);
|
||||||
setTimeout(async () => {
|
|
||||||
await fetchForm(props.data);
|
|
||||||
hideLoader();
|
|
||||||
}, 1000);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,7 @@ const pagination = ref({
|
||||||
* function fetch ข้อมูลรายการชื่อกรรมการ
|
* function fetch ข้อมูลรายการชื่อกรรมการ
|
||||||
*/
|
*/
|
||||||
async function getList() {
|
async function getList() {
|
||||||
|
dataStore.rows = [];
|
||||||
showLoader();
|
showLoader();
|
||||||
await http
|
await http
|
||||||
.get(config.API.evaluateDirectorMain())
|
.get(config.API.evaluateDirectorMain())
|
||||||
|
|
|
||||||
|
|
@ -54,6 +54,7 @@ function onSubmit(formData: FormData) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div class="col-xs-12 col-sm-12 col-md-12">
|
<div class="col-xs-12 col-sm-12 col-md-12">
|
||||||
<div class="toptitle col-12 row items-center">
|
<div class="toptitle col-12 row items-center">
|
||||||
|
|
|
||||||
|
|
@ -1,29 +1,21 @@
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, onMounted, reactive, computed } from "vue";
|
import { ref, onMounted, reactive, computed, onBeforeMount } from "vue";
|
||||||
import { useQuasar } from "quasar";
|
import { useQuasar } from "quasar";
|
||||||
import { useRoute } from "vue-router";
|
import { useRoute } from "vue-router";
|
||||||
import router from "@/router";
|
import router from "@/router";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
|
||||||
/**
|
/** importTyep*/
|
||||||
* importTyep
|
|
||||||
*/
|
|
||||||
import type { FormData } from "@/modules/12_evaluatePersonal/interface/index/meeting";
|
import type { FormData } from "@/modules/12_evaluatePersonal/interface/index/meeting";
|
||||||
|
|
||||||
/**
|
/** importComponents*/
|
||||||
* importComponents
|
|
||||||
*/
|
|
||||||
import Form from "@/modules/12_evaluatePersonal/components/Meeting/Form.vue";
|
import Form from "@/modules/12_evaluatePersonal/components/Meeting/Form.vue";
|
||||||
|
|
||||||
/**
|
/** importStore*/
|
||||||
* importStore
|
|
||||||
*/
|
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
|
|
||||||
/**
|
/** use*/
|
||||||
* use
|
|
||||||
*/
|
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const {
|
const {
|
||||||
|
|
@ -55,12 +47,13 @@ const data = reactive({
|
||||||
file: [],
|
file: [],
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
const isLoad = ref<boolean>(false);
|
||||||
* function fetch ข้อมูลการประชุม
|
|
||||||
*/
|
/** function fetch ข้อมูลการประชุม*/
|
||||||
function fetchData() {
|
async function fetchData() {
|
||||||
|
isLoad.value = false;
|
||||||
showLoader();
|
showLoader();
|
||||||
http
|
await http
|
||||||
.get(config.API.meetingById(personalId.value))
|
.get(config.API.meetingById(personalId.value))
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
const dataApi = await res.data.result;
|
const dataApi = await res.data.result;
|
||||||
|
|
@ -74,11 +67,10 @@ function fetchData() {
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
messageError($q, e);
|
messageError($q, e);
|
||||||
|
hideLoader();
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setTimeout(() => {
|
isLoad.value = true;
|
||||||
hideLoader();
|
|
||||||
}, 2000);
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -115,10 +107,11 @@ function onSubmit(formData: FormData) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(async () => {
|
||||||
fetchData();
|
await fetchData();
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div class="col-xs-12 col-sm-12 col-md-11">
|
<div class="col-xs-12 col-sm-12 col-md-11">
|
||||||
<div class="toptitle col-12 row items-center">
|
<div class="toptitle col-12 row items-center">
|
||||||
|
|
@ -135,6 +128,6 @@ onMounted(() => {
|
||||||
{{ title }}
|
{{ title }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<Form :on-submit="onSubmit" :data="data" />
|
<Form v-if="isLoad" :on-submit="onSubmit" :data="data" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
|
|
@ -35,6 +35,7 @@ const roundFilter = ref<any>(); //รอบการขึ้นเงินเ
|
||||||
const agencyFilter = ref<string>(""); //หน่วยงาน
|
const agencyFilter = ref<string>(""); //หน่วยงาน
|
||||||
const snapFilter = ref<string>(""); //รอบ
|
const snapFilter = ref<string>(""); //รอบ
|
||||||
const periodLatest = ref<DataPeriodLatest>();
|
const periodLatest = ref<DataPeriodLatest>();
|
||||||
|
const salaryPeriodId = ref<string>("");
|
||||||
|
|
||||||
//ตัวเลือก
|
//ตัวเลือก
|
||||||
const roundOptions = ref<DataOptionShort[]>([]); //ตัวเลือกรอบการขึ้นเงินเดือน
|
const roundOptions = ref<DataOptionShort[]>([]); //ตัวเลือกรอบการขึ้นเงินเดือน
|
||||||
|
|
@ -70,6 +71,7 @@ async function getRound() {
|
||||||
roundOptions.value = [];
|
roundOptions.value = [];
|
||||||
roundFilter.value = [];
|
roundFilter.value = [];
|
||||||
const data = res.data.result.data;
|
const data = res.data.result.data;
|
||||||
|
|
||||||
if (data.length !== 0) {
|
if (data.length !== 0) {
|
||||||
isDisable.value = true;
|
isDisable.value = true;
|
||||||
lastPage.value = Math.ceil(res.data.result.total / pageSize.value);
|
lastPage.value = Math.ceil(res.data.result.total / pageSize.value);
|
||||||
|
|
@ -94,6 +96,7 @@ async function getRound() {
|
||||||
store.roundMainCode = roundFilter.value.shortCode;
|
store.roundMainCode = roundFilter.value.shortCode;
|
||||||
store.roundYear = roundFilter.value.year;
|
store.roundYear = roundFilter.value.year;
|
||||||
store.isClosedRound = roundFilter.value.isClose;
|
store.isClosedRound = roundFilter.value.isClose;
|
||||||
|
salaryPeriodId.value = roundFilter.value.id;
|
||||||
|
|
||||||
await Promise.all([
|
await Promise.all([
|
||||||
getSnap(roundFilter.value.shortCode),
|
getSnap(roundFilter.value.shortCode),
|
||||||
|
|
@ -199,6 +202,7 @@ async function getAgencyPosition(id: string) {
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
const data = await res.data.result;
|
const data = await res.data.result;
|
||||||
store.rootId = data.rootId;
|
store.rootId = data.rootId;
|
||||||
|
|
||||||
const position = agencyOptions.value?.find(
|
const position = agencyOptions.value?.find(
|
||||||
(e: DataOption) => e.id === data.rootId
|
(e: DataOption) => e.id === data.rootId
|
||||||
);
|
);
|
||||||
|
|
@ -242,6 +246,7 @@ async function fetchSalalyPeriod(
|
||||||
.post(config.API.salaryListPeriodLatest, body)
|
.post(config.API.salaryListPeriodLatest, body)
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
const data = await res.data.result;
|
const data = await res.data.result;
|
||||||
|
console.log(data);
|
||||||
|
|
||||||
if (roundFilter.value.shortCode !== "SPECIAL") {
|
if (roundFilter.value.shortCode !== "SPECIAL") {
|
||||||
if (Object.values(data).includes(null)) {
|
if (Object.values(data).includes(null)) {
|
||||||
|
|
@ -274,6 +279,7 @@ async function fetchSalalyPeriod(
|
||||||
async function onChangeRound() {
|
async function onChangeRound() {
|
||||||
// เก็บสถานะการปิดรอบในตัวแปร isClosedRound เพื่อใช้ในการเช็ค
|
// เก็บสถานะการปิดรอบในตัวแปร isClosedRound เพื่อใช้ในการเช็ค
|
||||||
store.isClosedRound = roundFilter.value.isClose;
|
store.isClosedRound = roundFilter.value.isClose;
|
||||||
|
salaryPeriodId.value = roundFilter.value.id;
|
||||||
if (roundFilter.value.shortCode === "SPECIAL") {
|
if (roundFilter.value.shortCode === "SPECIAL") {
|
||||||
store.tabGroup = "group1";
|
store.tabGroup = "group1";
|
||||||
}
|
}
|
||||||
|
|
@ -357,8 +363,21 @@ function filterSelector(val: string, update: Function, refData: string) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
async function fetchCheckisOfficer() {
|
||||||
getRound();
|
http
|
||||||
|
.get(config.API.workflowKeycloakSystem(`SALARY_OFFICER`))
|
||||||
|
.then((res) => {
|
||||||
|
const data = res.data.result;
|
||||||
|
isOfficer.value = data.isOfficer;
|
||||||
|
isStaff.value = data.isStaff;
|
||||||
|
})
|
||||||
|
.catch((e) => {
|
||||||
|
messageError($q, e);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(async () => {
|
||||||
|
await Promise.all([getRound(), fetchCheckisOfficer()]);
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -542,6 +561,7 @@ onMounted(() => {
|
||||||
v-model:is-staff="isStaff"
|
v-model:is-staff="isStaff"
|
||||||
system-name="SALARY"
|
system-name="SALARY"
|
||||||
:command-type-code-array="['C-PM-33', 'C-PM-34', 'C-PM-35']"
|
:command-type-code-array="['C-PM-33', 'C-PM-34', 'C-PM-35']"
|
||||||
|
:salary-period-id="salaryPeriodId"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -35,6 +35,7 @@ const roundFilter = ref<any>(); //รอบการขึ้นเงินเ
|
||||||
const agencyFilter = ref<string>(""); //หน่วยงาน
|
const agencyFilter = ref<string>(""); //หน่วยงาน
|
||||||
const snapFilter = ref<string>(""); //รอบ
|
const snapFilter = ref<string>(""); //รอบ
|
||||||
const periodLatest = ref<DataPeriodLatest>();
|
const periodLatest = ref<DataPeriodLatest>();
|
||||||
|
const salaryPeriodId = ref<string>("");
|
||||||
|
|
||||||
//ตัวเลือก
|
//ตัวเลือก
|
||||||
const roundOptions = ref<DataOptionShort[]>([]); //ตัวเลือกรอบการขึ้นเงินเดือน
|
const roundOptions = ref<DataOptionShort[]>([]); //ตัวเลือกรอบการขึ้นเงินเดือน
|
||||||
|
|
@ -92,7 +93,7 @@ async function getRound() {
|
||||||
roundFilter.value = await (roundOptions.value
|
roundFilter.value = await (roundOptions.value
|
||||||
? roundOptions.value[0]
|
? roundOptions.value[0]
|
||||||
: "");
|
: "");
|
||||||
|
salaryPeriodId.value = roundFilter.value.id;
|
||||||
store.roundMainCode = roundFilter.value.shortCode;
|
store.roundMainCode = roundFilter.value.shortCode;
|
||||||
store.isClosedRound = roundFilter.value.isClose;
|
store.isClosedRound = roundFilter.value.isClose;
|
||||||
|
|
||||||
|
|
@ -262,6 +263,7 @@ async function fetchSalalyPeriod(
|
||||||
async function onChangeRound() {
|
async function onChangeRound() {
|
||||||
// เก็บสถานะการปิดรอบในตัวแปร isClosedRound เพื่อใช้ในการเช็ค
|
// เก็บสถานะการปิดรอบในตัวแปร isClosedRound เพื่อใช้ในการเช็ค
|
||||||
store.isClosedRound = roundFilter.value.isClose;
|
store.isClosedRound = roundFilter.value.isClose;
|
||||||
|
salaryPeriodId.value = roundFilter.value.id;
|
||||||
await getSnap(roundFilter.value.shortCode);
|
await getSnap(roundFilter.value.shortCode);
|
||||||
await getAgency(roundFilter.value.revisionId);
|
await getAgency(roundFilter.value.revisionId);
|
||||||
await getAgencyPosition(roundFilter.value.revisionId);
|
await getAgencyPosition(roundFilter.value.revisionId);
|
||||||
|
|
@ -359,8 +361,21 @@ function filterSelector(val: string, update: Function, refData: string) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
async function fetchCheckisOfficer() {
|
||||||
getRound();
|
http
|
||||||
|
.get(config.API.workflowKeycloakSystem(`SALARY_EMP`))
|
||||||
|
.then((res) => {
|
||||||
|
const data = res.data.result;
|
||||||
|
isOfficer.value = data.isOfficer;
|
||||||
|
isStaff.value = data.isStaff;
|
||||||
|
})
|
||||||
|
.catch((e) => {
|
||||||
|
messageError($q, e);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(async() => {
|
||||||
|
await Promise.all([getRound(), fetchCheckisOfficer()]);
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -538,6 +553,7 @@ onMounted(() => {
|
||||||
v-model:is-staff="isStaff"
|
v-model:is-staff="isStaff"
|
||||||
system-name="SALARY_EMP"
|
system-name="SALARY_EMP"
|
||||||
:command-type-code-array="['C-PM-36', 'C-PM-37']"
|
:command-type-code-array="['C-PM-36', 'C-PM-37']"
|
||||||
|
:salary-period-id="salaryPeriodId"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -291,9 +291,8 @@ onMounted(() => {
|
||||||
<q-space />
|
<q-space />
|
||||||
<q-btn
|
<q-btn
|
||||||
class="q-px-sm"
|
class="q-px-sm"
|
||||||
v-if="storeActing.isOfficer === true || storeActing.isStaff === true"
|
v-if="storeActing.isOfficer === true"
|
||||||
dense
|
dense
|
||||||
:disable="storeActing.isStaff == true && storeActing.rootId == ''"
|
|
||||||
flat
|
flat
|
||||||
round
|
round
|
||||||
color="add"
|
color="add"
|
||||||
|
|
|
||||||
|
|
@ -40,6 +40,7 @@ const props = defineProps({
|
||||||
commandTypeCodeArray: { type: Array, defult: [] }, // ไอดีประเภทคำสั่ง
|
commandTypeCodeArray: { type: Array, defult: [] }, // ไอดีประเภทคำสั่ง
|
||||||
systemName: String, // ไอดีประเภทคำสั่ง
|
systemName: String, // ไอดีประเภทคำสั่ง
|
||||||
orgPublishDate: { type: Date || undefined, defult: undefined },
|
orgPublishDate: { type: Date || undefined, defult: undefined },
|
||||||
|
salaryPeriodId: { type: String, defult: "" }, // รอบเงินเดือน
|
||||||
});
|
});
|
||||||
|
|
||||||
const commandOp = ref<ListCommand[]>([]); // ประเภทคำสั่ง
|
const commandOp = ref<ListCommand[]>([]); // ประเภทคำสั่ง
|
||||||
|
|
@ -49,6 +50,8 @@ const commandYear = ref<number>(new Date().getFullYear());
|
||||||
const commandAffectDate = ref<Date | null>(null); //วันที่ลงนาม
|
const commandAffectDate = ref<Date | null>(null); //วันที่ลงนาม
|
||||||
const commandExcecuteDate = ref<Date | null>(null); //วันที่คำสั่งมีผล
|
const commandExcecuteDate = ref<Date | null>(null); //วันที่คำสั่งมีผล
|
||||||
|
|
||||||
|
const commandCode = ref<string>("");
|
||||||
|
|
||||||
const group = ref<string>("GROUP1.1"); //กลุ่ม
|
const group = ref<string>("GROUP1.1"); //กลุ่ม
|
||||||
const isCheckOrgPublishDate = ref<boolean>(false); //เช็คค่าของวันที่คำสั่งมีผล
|
const isCheckOrgPublishDate = ref<boolean>(false); //เช็คค่าของวันที่คำสั่งมีผล
|
||||||
const groupDataOp = ref<DataOption[]>([
|
const groupDataOp = ref<DataOption[]>([
|
||||||
|
|
@ -204,11 +207,20 @@ function filterOption(val: string, update: Function) {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ฟังก์ชันเลือกกลุ่ม
|
* ฟังก์ชันเลือกประเภทคำสั่งและเลือกกลุ่ม
|
||||||
* @param val กลุ่มที่ต้องการค้นหา
|
|
||||||
*/
|
*/
|
||||||
function updateGroup() {
|
function updateValue() {
|
||||||
getPerson();
|
if (props.systemName === "SALARY" || props.systemName === "SALARY_EMP") {
|
||||||
|
const code = commandOp.value.find(
|
||||||
|
(e: any) => e.id === commandType.value
|
||||||
|
)?.code;
|
||||||
|
if (code && props.salaryPeriodId) {
|
||||||
|
commandCode.value = code;
|
||||||
|
getPerson();
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
getPerson();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** ดึงข้อมูลคน */
|
/** ดึงข้อมูลคน */
|
||||||
|
|
@ -221,10 +233,9 @@ function getPerson() {
|
||||||
const pathAPI =
|
const pathAPI =
|
||||||
props.systemName === "ORGANIZATION"
|
props.systemName === "ORGANIZATION"
|
||||||
? config.API.orgPosReport
|
? config.API.orgPosReport
|
||||||
: props.systemName === "SALARY"
|
: props.systemName === "SALARY" || props.systemName === "SALARY_EMP"
|
||||||
? config.API.orgPosReport
|
? config.API.orgPosSalaryReport +
|
||||||
: props.systemName === "SALARY_EMP"
|
`${commandCode.value}/${props.salaryPeriodId}`
|
||||||
? config.API.orgPosReport
|
|
||||||
: props.systemName === "ACTING"
|
: props.systemName === "ACTING"
|
||||||
? config.API.orgPosReport
|
? config.API.orgPosReport
|
||||||
: "";
|
: "";
|
||||||
|
|
@ -259,7 +270,9 @@ watch(modal, async () => {
|
||||||
(item) => item.id !== "GROUP1.1"
|
(item) => item.id !== "GROUP1.1"
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
getPerson();
|
if (props.systemName !== "SALARY" && props.systemName !== "SALARY_EMP") {
|
||||||
|
getPerson();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -295,6 +308,7 @@ watch(modal, async () => {
|
||||||
? 'inputgreen'
|
? 'inputgreen'
|
||||||
: ''
|
: ''
|
||||||
"
|
"
|
||||||
|
@update:model-value="updateValue"
|
||||||
>
|
>
|
||||||
<template v-slot:no-option>
|
<template v-slot:no-option>
|
||||||
<q-item>
|
<q-item>
|
||||||
|
|
@ -466,7 +480,7 @@ watch(modal, async () => {
|
||||||
map-options
|
map-options
|
||||||
use-input
|
use-input
|
||||||
outlined
|
outlined
|
||||||
@update:model-value="updateGroup"
|
@update:model-value="updateValue"
|
||||||
@filter="(inputValue:any,doneFn:Function) => filterOption(inputValue, doneFn) "
|
@filter="(inputValue:any,doneFn:Function) => filterOption(inputValue, doneFn) "
|
||||||
>
|
>
|
||||||
<template v-slot:no-option>
|
<template v-slot:no-option>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue