delete const $q = useQuasar(); .ts
This commit is contained in:
parent
1927870302
commit
60bda24d1d
5 changed files with 17 additions and 78 deletions
|
|
@ -17,7 +17,6 @@ import { getToken, tokenParsed } from "@/plugins/auth";
|
|||
|
||||
export const useSupportStore = defineStore("supportServiceStore", () => {
|
||||
const { showLoader, hideLoader, messageError } = useCounterMixin();
|
||||
const $q = useQuasar();
|
||||
const openChat = ref<boolean>(false);
|
||||
const icon = ref<string>("mdi-account-check");
|
||||
|
||||
|
|
@ -114,7 +113,7 @@ export const useSupportStore = defineStore("supportServiceStore", () => {
|
|||
const res = await http
|
||||
.get(config.API.supportMessageStatus(issueId))
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
|
|
@ -129,7 +128,7 @@ export const useSupportStore = defineStore("supportServiceStore", () => {
|
|||
const res = await http
|
||||
.get(config.API.supportMessage(issueId))
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
|
|
@ -149,7 +148,7 @@ export const useSupportStore = defineStore("supportServiceStore", () => {
|
|||
const res = await http
|
||||
.get(config.API.supportIssueUserId(userId.value))
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
|
|
@ -166,7 +165,7 @@ export const useSupportStore = defineStore("supportServiceStore", () => {
|
|||
const res = await http
|
||||
.get(config.API.supportIssueCategory)
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
|
|
@ -188,7 +187,7 @@ export const useSupportStore = defineStore("supportServiceStore", () => {
|
|||
const res = await http
|
||||
.post(config.API.supportNewIssue, requestBody)
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
|
|
@ -203,7 +202,7 @@ export const useSupportStore = defineStore("supportServiceStore", () => {
|
|||
const res = await http
|
||||
.get(config.API.supportSearchIssue(searchData))
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
});
|
||||
if (res && res.data) {
|
||||
issue.value = res.data;
|
||||
|
|
|
|||
|
|
@ -1,15 +1,13 @@
|
|||
import http from "@/plugins/http";
|
||||
import config from "@/app.config";
|
||||
import { useQuasar } from "quasar";
|
||||
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useEvaluateStore } from "@/modules/06_evaluate/store";
|
||||
|
||||
const store = useEvaluateStore();
|
||||
const mixin = useCounterMixin();
|
||||
const $q = useQuasar();
|
||||
|
||||
const { showLoader, hideLoader, messageError } = mixin;
|
||||
const { showLoader, hideLoader } = mixin;
|
||||
|
||||
/** function เช็คการยื่นข้อประเมิน*/
|
||||
async function fetchCheckStatus() {
|
||||
|
|
@ -26,7 +24,7 @@ async function fetchCheckStatus() {
|
|||
fetchCheckStep(store?.evaluateId);
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
|
|
@ -65,7 +63,7 @@ async function fetchCheckStep(id: string) {
|
|||
store.step = step;
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
store.showLoadStatus = true;
|
||||
|
|
@ -143,7 +141,7 @@ async function saveEvaluation(formSpec: any, detail: any) {
|
|||
fetchCheckStatus();
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
fetchCheckStep(store?.evaluateId);
|
||||
|
|
@ -155,10 +153,9 @@ async function nextPrapare(type: string, body: any) {
|
|||
showLoader();
|
||||
await http
|
||||
.put(config.API.evaluationPreparedoc(store.evaluateId, type), body)
|
||||
.then((res) => {
|
||||
})
|
||||
.then((res) => {})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
|
|
@ -170,10 +167,9 @@ async function nextCheckDoc(type: string) {
|
|||
showLoader();
|
||||
await http
|
||||
.put(config.API.evaluationCheckdoc(store.evaluateId, type))
|
||||
.then((res) => {
|
||||
})
|
||||
.then((res) => {})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
|
|
|
|||
|
|
@ -1,17 +1,9 @@
|
|||
import { defineStore } from "pinia";
|
||||
import { ref, reactive, watch } from "vue";
|
||||
import { ref, reactive } from "vue";
|
||||
import type { DataOptions } from "./interface/index/Main";
|
||||
import type { FormQuery } from "@/modules/08_KPI/interface/request/index";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import http from "@/plugins/http";
|
||||
import config from "@/app.config";
|
||||
import { useQuasar } from "quasar";
|
||||
|
||||
export const useKpiDataStore = defineStore("KPIDate", () => {
|
||||
const $q = useQuasar();
|
||||
const mixin = useCounterMixin();
|
||||
const { showLoader, hideLoader, messageError } = mixin;
|
||||
|
||||
const mainRowData = ref<any>();
|
||||
const isUpdate = ref<boolean>(false);
|
||||
const tabMainevaluator = ref<string>("1");
|
||||
|
|
@ -432,47 +424,6 @@ export const useKpiDataStore = defineStore("KPIDate", () => {
|
|||
const devProbationScore = ref<number>(10); // สรุปผลการประเมินพฤติกรรมการปฏิบัติราชการ (สมรรถนะ+การพัฒนาตนเอง) (คะแนนเต็ม competencyDevScore คะแนน)
|
||||
const competencyDevProbationScore = ref<number>(50); // สรุปผลการประเมินพฤติกรรมการปฏิบัติราชการ (สมรรถนะ+การพัฒนาตนเอง) (คะแนนเต็ม competencyDevScore คะแนน)
|
||||
|
||||
// function getDataWork() {
|
||||
// showLoader();
|
||||
// http
|
||||
// .get(config.API.orgPosition + `/${dataProfile.value.profileId}`)
|
||||
// .then((res) => {
|
||||
// const data = res.data.result.isProbation;
|
||||
// work.value = data;
|
||||
// if (data) {
|
||||
// indicatorScore.value = 50;
|
||||
// competencyScore.value = 40;
|
||||
// excusiveCompetencyScore.value = 40;
|
||||
// competencyDevScore.value = 10;
|
||||
// } else {
|
||||
// indicatorScore.value = 70;
|
||||
// competencyScore.value = 20;
|
||||
// excusiveCompetencyScore.value = 20;
|
||||
// competencyDevScore.value = 30;
|
||||
// }
|
||||
// })
|
||||
// .catch((e) => {
|
||||
// messageError($q, e);
|
||||
// })
|
||||
// .finally(() => {
|
||||
// hideLoader();
|
||||
// });
|
||||
// }
|
||||
|
||||
// watch(
|
||||
// () => tabMain.value,
|
||||
// () => {
|
||||
// if (tabMain.value == "3" && tabOpen.value == 3) {
|
||||
// getDataWork();
|
||||
// } else {
|
||||
// indicatorScore.value = 70;
|
||||
// competencyScore.value = 20;
|
||||
// excusiveCompetencyScore.value = 20;
|
||||
// competencyDevScore.value = 30;
|
||||
// }
|
||||
// }
|
||||
// );
|
||||
|
||||
return {
|
||||
tabMain,
|
||||
dataProfile,
|
||||
|
|
@ -526,6 +477,6 @@ export const useKpiDataStore = defineStore("KPIDate", () => {
|
|||
mainRowData,
|
||||
resultsOptions,
|
||||
statusOptions,
|
||||
roleText
|
||||
roleText,
|
||||
};
|
||||
});
|
||||
|
|
|
|||
|
|
@ -1,13 +1,7 @@
|
|||
import { defineStore } from "pinia";
|
||||
import { useQuasar } from "quasar";
|
||||
|
||||
import http from "@/plugins/http";
|
||||
import config from "@/app.config";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
|
||||
const $q = useQuasar();
|
||||
const mixin = useCounterMixin();
|
||||
const { messageError } = mixin;
|
||||
|
||||
export const useRegistryDataStore = defineStore("RegistryDataStoreMain", () => {
|
||||
async function getPathUploadFlie(
|
||||
|
|
@ -27,7 +21,7 @@ export const useRegistryDataStore = defineStore("RegistryDataStoreMain", () => {
|
|||
);
|
||||
return res.data;
|
||||
} catch (err) {
|
||||
messageError($q, err);
|
||||
console.log(err);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ import { useCounterMixin } from "@/stores/mixin";
|
|||
|
||||
import type { DataOption } from "@/modules/10_registry/interface/index/Main";
|
||||
|
||||
const $q = useQuasar();
|
||||
const mixin = useCounterMixin();
|
||||
const {} = mixin;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue