fixing report probation
This commit is contained in:
parent
af8937c29f
commit
ef6b015113
5 changed files with 23 additions and 24 deletions
|
|
@ -5,6 +5,8 @@ import { useCounterMixin } from "@/stores/mixin";
|
||||||
import { useRoute, useRouter } from "vue-router";
|
import { useRoute, useRouter } from "vue-router";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
import { useProbationDataStore } from "@/modules/05_placement/storeProbation";
|
||||||
|
const probationStore = useProbationDataStore();
|
||||||
|
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const myForm = ref<any>(null);
|
const myForm = ref<any>(null);
|
||||||
|
|
@ -39,7 +41,7 @@ const reson52 = ref<string>("");
|
||||||
const chairman_dated = ref<Date>();
|
const chairman_dated = ref<Date>();
|
||||||
const director1_dated = ref<any>("");
|
const director1_dated = ref<any>("");
|
||||||
const director2_dated = ref<any>("");
|
const director2_dated = ref<any>("");
|
||||||
const fullname = ref<string>("");
|
// const fullname = ref<string>("");
|
||||||
const director_id = ref<any>(null);
|
const director_id = ref<any>(null);
|
||||||
const director_id2 = ref<any>(null);
|
const director_id2 = ref<any>(null);
|
||||||
const director_id3 = ref<any>(null);
|
const director_id3 = ref<any>(null);
|
||||||
|
|
@ -158,7 +160,10 @@ async function clickdownloadFile(type: string) {
|
||||||
responseType: "blob",
|
responseType: "blob",
|
||||||
})
|
})
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
downloadFile(res, `แบบรายงานการประเมินฯ_${fullname.value}.${type}`);
|
downloadFile(
|
||||||
|
res,
|
||||||
|
`แบบรายงานการประเมินฯ_${probationStore.person.name}.${type}`
|
||||||
|
);
|
||||||
})
|
})
|
||||||
.catch(async (e) => {
|
.catch(async (e) => {
|
||||||
messageError($q, JSON.parse(await e.response.data.text()));
|
messageError($q, JSON.parse(await e.response.data.text()));
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ const mixin = useCounterMixin();
|
||||||
const { showLoader, hideLoader, messageError } = mixin;
|
const { showLoader, hideLoader, messageError } = mixin;
|
||||||
const assignId = ref<string>(route.params.form.toString());
|
const assignId = ref<string>(route.params.form.toString());
|
||||||
const personalId = ref<string>(route.params.personalId.toString());
|
const personalId = ref<string>(route.params.personalId.toString());
|
||||||
const fullname = ref<string>("");
|
// const fullname = ref<string>("");
|
||||||
const tab = ref<string>("save1");
|
const tab = ref<string>("save1");
|
||||||
const dataArrayNumber = ref<number>();
|
const dataArrayNumber = ref<number>();
|
||||||
const dataRole = ref<string>("mentor");
|
const dataRole = ref<string>("mentor");
|
||||||
|
|
@ -43,9 +43,9 @@ async function fecthAssign(id: string) {
|
||||||
.get(config.API.formevaluate(id))
|
.get(config.API.formevaluate(id))
|
||||||
.then(async (res: any) => {
|
.then(async (res: any) => {
|
||||||
await fecthdataAssign(res.data.data);
|
await fecthdataAssign(res.data.data);
|
||||||
fullname.value = res.data.data.experimentee
|
// fullname.value = res.data.data.experimentee
|
||||||
? res.data.data.experimentee.name
|
// ? res.data.data.experimentee.name
|
||||||
: "";
|
// : "";
|
||||||
dataArrayNumber.value = 1;
|
dataArrayNumber.value = 1;
|
||||||
})
|
})
|
||||||
.catch((e: any) => {
|
.catch((e: any) => {
|
||||||
|
|
@ -91,7 +91,7 @@ async function FileDownload(type: string) {
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
downloadFile(
|
downloadFile(
|
||||||
res,
|
res,
|
||||||
`แบบบันทึกผล(ผู้ดูเเล)_${fullname.value}_ครั้งที่${numTab.no}.${type}`
|
`แบบบันทึกผล(ผู้ดูเเล)_${probationStore.person.name}_ครั้งที่${numTab.no}.${type}`
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
.catch(async (e) => {
|
.catch(async (e) => {
|
||||||
|
|
@ -110,7 +110,7 @@ async function FileDownload(type: string) {
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
downloadFile(
|
downloadFile(
|
||||||
res,
|
res,
|
||||||
`แบบบันทึกผล(ผู้บังคับบัญชา)_${fullname.value}_ครั้งที่${numTab.no}.${type}`
|
`แบบบันทึกผล(ผู้บังคับบัญชา)_${probationStore.person.name}_ครั้งที่${numTab.no}.${type}`
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
.catch(async (e) => {
|
.catch(async (e) => {
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ const mixin = useCounterMixin();
|
||||||
const { showLoader, hideLoader, messageError } = mixin;
|
const { showLoader, hideLoader, messageError } = mixin;
|
||||||
const assignId = ref<string>(route.params.form.toString());
|
const assignId = ref<string>(route.params.form.toString());
|
||||||
const personalId = ref<string>(route.params.personalId.toString());
|
const personalId = ref<string>(route.params.personalId.toString());
|
||||||
const fullname = ref<string>("");
|
// const fullname = ref<string>("");
|
||||||
const tab = ref<string>("save1");
|
const tab = ref<string>("save1");
|
||||||
const dataArrayNumber = ref<number>();
|
const dataArrayNumber = ref<number>();
|
||||||
const dataRole = ref<string>("mentor");
|
const dataRole = ref<string>("mentor");
|
||||||
|
|
@ -48,9 +48,7 @@ async function fecthAssign(id: string) {
|
||||||
.get(config.API.formevaluateCommander(id))
|
.get(config.API.formevaluateCommander(id))
|
||||||
.then(async (res: any) => {
|
.then(async (res: any) => {
|
||||||
await fecthdataAssign(res.data.data);
|
await fecthdataAssign(res.data.data);
|
||||||
fullname.value = res.data.data.experimentee
|
// fullname.value = res.data.person ? res.data.person.name : "";
|
||||||
? res.data.data.experimentee.name
|
|
||||||
: "";
|
|
||||||
dataArrayNumber.value = 1;
|
dataArrayNumber.value = 1;
|
||||||
})
|
})
|
||||||
.catch((e: any) => {
|
.catch((e: any) => {
|
||||||
|
|
@ -99,7 +97,7 @@ async function FileDownload(type: string) {
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
downloadFile(
|
downloadFile(
|
||||||
res,
|
res,
|
||||||
`แบบบันทึกผล(ผู้บังคับบัญชา)_${fullname.value}_ครั้งที่${numTab.no}.${type}`
|
`แบบบันทึกผล(ผู้บังคับบัญชา)_${probationStore.person.name}_ครั้งที่${numTab.no}.${type}`
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
.catch(async (e) => {
|
.catch(async (e) => {
|
||||||
|
|
@ -118,7 +116,7 @@ async function FileDownload(type: string) {
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
downloadFile(
|
downloadFile(
|
||||||
res,
|
res,
|
||||||
`แบบบันทึกผล(ผู้บังคับบัญชา)_${fullname.value}_ครั้งที่${numTab.no}.${type}`
|
`แบบบันทึกผล(ผู้บังคับบัญชา)_${probationStore.person.name}_ครั้งที่${numTab.no}.${type}`
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
.catch(async (e) => {
|
.catch(async (e) => {
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ const probationStore = useProbationDataStore();
|
||||||
const { fecthdataAssign } = probationStore;
|
const { fecthdataAssign } = probationStore;
|
||||||
const assignId = ref<string>(route.params.form.toString());
|
const assignId = ref<string>(route.params.form.toString());
|
||||||
const personalId = ref<string>(route.params.personalId.toString());
|
const personalId = ref<string>(route.params.personalId.toString());
|
||||||
const fullname = ref<string>("");
|
// const fullname = ref<string>("");
|
||||||
const tab = ref<string>("save1");
|
const tab = ref<string>("save1");
|
||||||
const tabs = ref<any>([]);
|
const tabs = ref<any>([]);
|
||||||
const dataArrayNumber = ref<number>(1);
|
const dataArrayNumber = ref<number>(1);
|
||||||
|
|
@ -60,9 +60,7 @@ async function fecthAssign(id: string) {
|
||||||
await fecthdataAssign(res.data.data);
|
await fecthdataAssign(res.data.data);
|
||||||
evaluate.value = probationStore.evaluate;
|
evaluate.value = probationStore.evaluate;
|
||||||
tabs.value = evaluate.value;
|
tabs.value = evaluate.value;
|
||||||
fullname.value = res.data.data.experimentee
|
// fullname.value = res.data.data.person ? res.data.data.person.name : "";
|
||||||
? res.data.data.experimentee.name
|
|
||||||
: "";
|
|
||||||
dataArrayNumber.value = 1;
|
dataArrayNumber.value = 1;
|
||||||
})
|
})
|
||||||
.catch((e: any) => {
|
.catch((e: any) => {
|
||||||
|
|
@ -98,7 +96,7 @@ async function FileDownload(type: string) {
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
downloadFile(
|
downloadFile(
|
||||||
res,
|
res,
|
||||||
`แบบประเมินผล(ผู้บังคับบัญชา)_${fullname.value}_ครั้งที่${numTab.no}.${type}`
|
`แบบประเมินผล(ผู้บังคับบัญชา)_${probationStore.person.name}_ครั้งที่${numTab.no}.${type}`
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
.catch(async (e) => {
|
.catch(async (e) => {
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ const { showLoader, hideLoader, messageError, success } = mixin;
|
||||||
const assignId = ref<string>(route.params.form.toString());
|
const assignId = ref<string>(route.params.form.toString());
|
||||||
const personalId = ref<string>(route.params.personalId.toString());
|
const personalId = ref<string>(route.params.personalId.toString());
|
||||||
|
|
||||||
const fullname = ref<string>("");
|
// const fullname = ref<string>("");
|
||||||
const tab = ref<string>("save1");
|
const tab = ref<string>("save1");
|
||||||
const tabs = ref<any>([]);
|
const tabs = ref<any>([]);
|
||||||
const dataArrayNumber = ref<number>(1);
|
const dataArrayNumber = ref<number>(1);
|
||||||
|
|
@ -47,9 +47,7 @@ const fecthAssign = async (id: string) => {
|
||||||
.then(async (res: any) => {
|
.then(async (res: any) => {
|
||||||
await fecthdataAssign(res.data.data);
|
await fecthdataAssign(res.data.data);
|
||||||
evaluate.value = probationStore.evaluate;
|
evaluate.value = probationStore.evaluate;
|
||||||
fullname.value = res.data.data.experimentee
|
// fullname.value = res.data.data.person ? res.data.data.person.name : "";
|
||||||
? res.data.data.experimentee.name
|
|
||||||
: "";
|
|
||||||
tabs.value = evaluate.value;
|
tabs.value = evaluate.value;
|
||||||
dataArrayNumber.value = 1;
|
dataArrayNumber.value = 1;
|
||||||
})
|
})
|
||||||
|
|
@ -80,7 +78,7 @@ const FileDownload = async (type: string) => {
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
downloadFile(
|
downloadFile(
|
||||||
res,
|
res,
|
||||||
`แบบประเมินผล(คณะกรรมการ)_${fullname.value}_ครั้งที่${numTab.no}.${type}`
|
`แบบประเมินผล(คณะกรรมการ)_${probationStore.person.name}_ครั้งที่${numTab.no}.${type}`
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
.catch(async (e) => {
|
.catch(async (e) => {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue