fix:add function calculateFiscalYear
This commit is contained in:
parent
70be19b5c4
commit
7877f26ac6
47 changed files with 131 additions and 68 deletions
|
|
@ -8,6 +8,7 @@ import http from "@/plugins/http";
|
|||
import { useRouter } from "vue-router";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useRoute } from "vue-router";
|
||||
import { calculateFiscalYear } from "@/utils/function";
|
||||
|
||||
import type {
|
||||
DataOption,
|
||||
|
|
@ -47,7 +48,7 @@ const typeOps = ref<typeOp[]>([
|
|||
]);
|
||||
|
||||
const modalDialog = defineModel<boolean>("modal", { required: true });
|
||||
const yearDialog = ref<number | any>(new Date().getFullYear());
|
||||
const yearDialog = ref<number | any>(calculateFiscalYear(new Date())); //ปีงบประมาณ
|
||||
const roundDialgOp = ref<DataOption[]>([]);
|
||||
const isRoundClose = ref<boolean>(false);
|
||||
|
||||
|
|
@ -144,7 +145,7 @@ const columnsRespondent = ref<QTableProps["columns"]>([
|
|||
function onCloseDialog() {
|
||||
modalDialog.value = false;
|
||||
formRound.kpiPeriodId = { id: "", name: "", isClosed: false };
|
||||
yearDialog.value = new Date().getFullYear();
|
||||
yearDialog.value = calculateFiscalYear(new Date());
|
||||
rows.value = [];
|
||||
formRound.evaluatorId = "";
|
||||
formRound.commanderId = "";
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import config from "@/app.config";
|
|||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useKpiDataStore } from "@/modules/14_KPI/store";
|
||||
import { checkPermission } from "@/utils/permissions";
|
||||
import { calculateFiscalYear } from "@/utils/function";
|
||||
|
||||
/** importType*/
|
||||
import type { QTableProps } from "quasar";
|
||||
|
|
@ -133,7 +134,7 @@ const pagination = ref({
|
|||
});
|
||||
|
||||
/** ตัวแปร*/
|
||||
const year = ref<number | null>(new Date().getFullYear()); //ปีงบประมาณ
|
||||
const year = ref<number | null>(calculateFiscalYear(new Date())); //ปีงบประมาณ
|
||||
const roundOp = ref<DataOption[]>([]); // รายการรอบการประเมิน
|
||||
|
||||
/** function fetch รายการแผนพัฒนาการปฏิบัติราชการรายบุคคลย้อนหลัง*/
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import config from "@/app.config";
|
|||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useKpiDataStore } from "@/modules/14_KPI/store";
|
||||
import { checkPermission } from "@/utils/permissions";
|
||||
import { calculateFiscalYear } from "@/utils/function";
|
||||
|
||||
/** importType*/
|
||||
import type { QTableProps } from "quasar";
|
||||
|
|
@ -167,7 +168,7 @@ const pagination = ref({
|
|||
});
|
||||
|
||||
/** ตัวแปร*/
|
||||
const year = ref<number | null>(new Date().getFullYear()); //ปีงบประมาณ
|
||||
const year = ref<number | null>(calculateFiscalYear(new Date())); //ปีงบประมาณ
|
||||
const roundOp = ref<DataOption[]>([]); // รายการรอบการประเมิน
|
||||
const resultOp = ref<DataOption[]>(store.resultsOptions);
|
||||
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ import { useCounterMixin } from "@/stores/mixin";
|
|||
import { checkPermission } from "@/utils/permissions";
|
||||
import http from "@/plugins/http";
|
||||
import config from "@/app.config";
|
||||
import { calculateFiscalYear } from "@/utils/function";
|
||||
|
||||
/** importType*/
|
||||
import type {
|
||||
|
|
@ -102,7 +103,7 @@ const visibleColumns = ref<string[]>([
|
|||
const formQuery = reactive<FormQueryRound>({
|
||||
page: 1, //หน้า
|
||||
pageSize: 10, //จำนวนหน้า
|
||||
year: new Date().getFullYear(), //ปีงประมาณ
|
||||
year: calculateFiscalYear(new Date()), //ปีงประมาณ
|
||||
keyword: "",
|
||||
});
|
||||
const modalDialog = ref<boolean>(false); //modal เพิ่มรอบการประเมินผลการปฏิบัติหน้าที่ราชการ
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ import { useRouter } from "vue-router";
|
|||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useKpiDataStore } from "@/modules/14_KPI/store";
|
||||
import { checkPermission } from "@/utils/permissions";
|
||||
import { calculateFiscalYear } from "@/utils/function";
|
||||
import config from "@/app.config";
|
||||
import http from "@/plugins/http";
|
||||
|
||||
|
|
@ -22,7 +23,7 @@ const router = useRouter();
|
|||
const store = useKpiDataStore();
|
||||
const { showLoader, hideLoader, messageError, date2Thai } = useCounterMixin();
|
||||
|
||||
const year = ref<number | null>(new Date().getFullYear()); //ปีงบประมาณ
|
||||
const year = ref<number | null>(calculateFiscalYear(new Date())); //ปีงบประมาณ
|
||||
const formQuery = reactive({
|
||||
page: 1, //หน้า
|
||||
pageSize: 10, //จำนวนแถวต่อหน้า
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import http from "@/plugins/http";
|
|||
import axios from "axios";
|
||||
import genReport from "@/plugins/genreport";
|
||||
import LoadView from "@/components/LoadView.vue";
|
||||
import { calculateFiscalYear } from "@/utils/function";
|
||||
/**
|
||||
* importType
|
||||
*/
|
||||
|
|
@ -45,7 +46,7 @@ const route = useRoute();
|
|||
*/
|
||||
const fullNameShow = ref<string>("");
|
||||
const isLoadPDF = ref<boolean>(false);
|
||||
const year = ref<number | null>(new Date().getFullYear());
|
||||
const year = ref<number | null>(calculateFiscalYear(new Date())); //ปีงบประมาณ
|
||||
const round = ref<string>("");
|
||||
const organization = ref<string>("");
|
||||
const roundOp = ref<DataOption[]>([]);
|
||||
|
|
@ -487,7 +488,7 @@ watch(
|
|||
|
||||
function clearFilter() {
|
||||
organization.value = "";
|
||||
year.value = new Date().getFullYear();
|
||||
year.value = calculateFiscalYear(new Date());
|
||||
typeReport.value = "KPI1";
|
||||
pdfSrc.value = undefined;
|
||||
dataDownload.value = undefined;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue