รายการเลื่อนเงินเดือนข้าราชการ => ปรับ body filter รายชื่อราชการที่เลื่อนเงินเดือ
This commit is contained in:
parent
799cd7ce08
commit
e35edfeed7
4 changed files with 31 additions and 17 deletions
|
|
@ -97,6 +97,8 @@ const formFilter = reactive<DataFilterPerson>({
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
keyword: "",
|
keyword: "",
|
||||||
rootId: "",
|
rootId: "",
|
||||||
|
year: 0,
|
||||||
|
period: "",
|
||||||
});
|
});
|
||||||
const maxPage = ref<number>(1);
|
const maxPage = ref<number>(1);
|
||||||
|
|
||||||
|
|
@ -111,6 +113,8 @@ function closeModal() {
|
||||||
function fetchListPerson() {
|
function fetchListPerson() {
|
||||||
showLoader();
|
showLoader();
|
||||||
formFilter.rootId = store.rootId;
|
formFilter.rootId = store.rootId;
|
||||||
|
formFilter.period = store.roundMainCode;
|
||||||
|
formFilter.year = store.roundYear;
|
||||||
http
|
http
|
||||||
.post(config.API.salaryListPerson, formFilter)
|
.post(config.API.salaryListPerson, formFilter)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
|
|
|
||||||
|
|
@ -10,6 +10,8 @@ interface DataFilterPerson {
|
||||||
pageSize: number;
|
pageSize: number;
|
||||||
keyword: string;
|
keyword: string;
|
||||||
rootId: string;
|
rootId: string;
|
||||||
|
year: number;
|
||||||
|
period: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export type { DataFilter, DataFilterPerson };
|
export type { DataFilter, DataFilterPerson };
|
||||||
|
|
|
||||||
|
|
@ -21,6 +21,7 @@ export const useSalaryListSDataStore = defineStore("salaryListStore", () => {
|
||||||
const groupId = ref<string>("");
|
const groupId = ref<string>("");
|
||||||
const rootId = ref<string>("");
|
const rootId = ref<string>("");
|
||||||
const roundMainCode = ref<string>("");
|
const roundMainCode = ref<string>("");
|
||||||
|
const roundYear = ref<number>(0);
|
||||||
const roundCode = ref<string>("");
|
const roundCode = ref<string>("");
|
||||||
const isClosedRound = ref<boolean>(false); // การปิดรอบ
|
const isClosedRound = ref<boolean>(false); // การปิดรอบ
|
||||||
/** List Menu*/
|
/** List Menu*/
|
||||||
|
|
@ -152,6 +153,7 @@ export const useSalaryListSDataStore = defineStore("salaryListStore", () => {
|
||||||
groupOp,
|
groupOp,
|
||||||
roundMainCode,
|
roundMainCode,
|
||||||
remaining,
|
remaining,
|
||||||
isClosedRound
|
isClosedRound,
|
||||||
|
roundYear,
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import { useQuasar } from "quasar";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import ProcessStep from "@/modules/13_salary/components/SalaryLists/ProcessStep.vue";
|
import ProcessStep from "@/modules/13_salary/components/SalaryLists/ProcessStep.vue";
|
||||||
import PageDashBoard from '@/modules/13_salary/components/SalaryLists/Dashboard.vue'
|
import PageDashBoard from "@/modules/13_salary/components/SalaryLists/Dashboard.vue";
|
||||||
/** importType*/
|
/** importType*/
|
||||||
import type {
|
import type {
|
||||||
DataOption,
|
DataOption,
|
||||||
|
|
@ -63,6 +63,7 @@ function getRound() {
|
||||||
revisionId: x.revisionId,
|
revisionId: x.revisionId,
|
||||||
shortCode: x.period,
|
shortCode: x.period,
|
||||||
isClose: x.isClose,
|
isClose: x.isClose,
|
||||||
|
year: x.year,
|
||||||
name:
|
name:
|
||||||
(x.period === "OCT"
|
(x.period === "OCT"
|
||||||
? "รอบตุลาคม "
|
? "รอบตุลาคม "
|
||||||
|
|
@ -78,6 +79,7 @@ function getRound() {
|
||||||
: "");
|
: "");
|
||||||
|
|
||||||
store.roundMainCode = roundFilter.value.shortCode;
|
store.roundMainCode = roundFilter.value.shortCode;
|
||||||
|
store.roundYear = roundFilter.value.year;
|
||||||
store.isClosedRound = roundFilter.value.isClose;
|
store.isClosedRound = roundFilter.value.isClose;
|
||||||
|
|
||||||
await getSnap(roundFilter.value.shortCode);
|
await getSnap(roundFilter.value.shortCode);
|
||||||
|
|
@ -239,6 +241,7 @@ function fetchSalalyPeriod(rootId: string, periodId: string, snap: string) {
|
||||||
async function onChangeRound() {
|
async function onChangeRound() {
|
||||||
// เก็บสถานะการปิดรอบในตัวแปร isClosedRound เพื่อใช้ในการเช็ค
|
// เก็บสถานะการปิดรอบในตัวแปร isClosedRound เพื่อใช้ในการเช็ค
|
||||||
store.isClosedRound = roundFilter.value.isClose;
|
store.isClosedRound = roundFilter.value.isClose;
|
||||||
|
console.log(roundFilter.value);
|
||||||
|
|
||||||
await getSnap(roundFilter.value.shortCode);
|
await getSnap(roundFilter.value.shortCode);
|
||||||
await getAgency(roundFilter.value.revisionId);
|
await getAgency(roundFilter.value.revisionId);
|
||||||
|
|
@ -251,6 +254,7 @@ async function onChangeRound() {
|
||||||
// );
|
// );
|
||||||
store.tabType = "PENDING";
|
store.tabType = "PENDING";
|
||||||
store.roundMainCode = roundFilter.value.shortCode;
|
store.roundMainCode = roundFilter.value.shortCode;
|
||||||
|
store.roundYear = roundFilter.value.year;
|
||||||
} else {
|
} else {
|
||||||
isLoad.value = false;
|
isLoad.value = false;
|
||||||
}
|
}
|
||||||
|
|
@ -271,7 +275,11 @@ async function onChangeSnap() {
|
||||||
async function onChangeAgency() {
|
async function onChangeAgency() {
|
||||||
store.rootId = agencyFilter.value;
|
store.rootId = agencyFilter.value;
|
||||||
|
|
||||||
if (agencyFilter.value !== 'ALL' && roundFilter.value.id && snapFilter.value) {
|
if (
|
||||||
|
agencyFilter.value !== "ALL" &&
|
||||||
|
roundFilter.value.id &&
|
||||||
|
snapFilter.value
|
||||||
|
) {
|
||||||
await fetchSalalyPeriod(
|
await fetchSalalyPeriod(
|
||||||
agencyFilter.value,
|
agencyFilter.value,
|
||||||
roundFilter.value.id,
|
roundFilter.value.id,
|
||||||
|
|
@ -394,20 +402,18 @@ onMounted(async () => {
|
||||||
<q-separator /> -->
|
<q-separator /> -->
|
||||||
<q-card flat bordered>
|
<q-card flat bordered>
|
||||||
<div v-if="agencyFilter !== 'ALL'">
|
<div v-if="agencyFilter !== 'ALL'">
|
||||||
|
<TabGroup v-if="isLoad" :periodLatest="periodLatest" />
|
||||||
|
<q-card v-else class="q-pa-sm">
|
||||||
<TabGroup v-if="isLoad" :periodLatest="periodLatest" />
|
<div class="q-pa-sm">
|
||||||
<q-card v-else class="q-pa-sm">
|
<q-banner inline-actions rounded class="bg-grey-1 text-center">
|
||||||
<div class="q-pa-sm">
|
ไม่มีข้อมูล
|
||||||
<q-banner inline-actions rounded class="bg-grey-1 text-center">
|
</q-banner>
|
||||||
ไม่มีข้อมูล
|
</div>
|
||||||
</q-banner>
|
</q-card>
|
||||||
</div>
|
</div>
|
||||||
</q-card>
|
<div v-else>
|
||||||
</div>
|
<PageDashBoard />
|
||||||
<div v-else>
|
</div>
|
||||||
<PageDashBoard/>
|
|
||||||
</div>
|
|
||||||
</q-card>
|
</q-card>
|
||||||
|
|
||||||
<q-card
|
<q-card
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue