แก้ไขประเมินบุคคล
This commit is contained in:
parent
2399c9dcf0
commit
3487ae71bb
6 changed files with 61 additions and 19 deletions
|
|
@ -24,7 +24,9 @@ export default {
|
||||||
evaluationFileListbyId: (volume: string, id: string) =>
|
evaluationFileListbyId: (volume: string, id: string) =>
|
||||||
`${evaluationFile}/${volume}/${id}`,
|
`${evaluationFile}/${volume}/${id}`,
|
||||||
evaluationApproveDoc1: (id: string) => `${evaluation}/doc1/approve/${id}`,
|
evaluationApproveDoc1: (id: string) => `${evaluation}/doc1/approve/${id}`,
|
||||||
|
evaluationNext5To6: (id: string) => `${evaluation}/announce/${id}`,
|
||||||
|
evaluationNextFinish: (id: string) => `${evaluation}/wait-check-doc-v2/${id}`,
|
||||||
|
|
||||||
evaluationHistory: (id: string) => `${evaluation}/step-history/${id}`,
|
evaluationHistory: (id: string) => `${evaluation}/step-history/${id}`,
|
||||||
|
|
||||||
evaluationDateAnnounce: (id: string) => `${evaluation}/check-date/${id}`,
|
evaluationDateAnnounce: (id: string) => `${evaluation}/check-date/${id}`,
|
||||||
|
|
|
||||||
|
|
@ -30,6 +30,7 @@ const config = ref<any>({
|
||||||
API_PROBATION_URI: "https://bma-ehr.frappet.synology.me/api/v1/probation",
|
API_PROBATION_URI: "https://bma-ehr.frappet.synology.me/api/v1/probation",
|
||||||
// API_PROBATION_URI: "http://192.168.1.151:7776/v1",
|
// API_PROBATION_URI: "http://192.168.1.151:7776/v1",
|
||||||
API_REPORT2_URI: "https://bma-ehr.frappet.synology.me/api/v2",
|
API_REPORT2_URI: "https://bma-ehr.frappet.synology.me/api/v2",
|
||||||
|
LINK_EVALUATE_PUBLISH: "https://bma-ehr-publish.frappet.synology.me",
|
||||||
},
|
},
|
||||||
test: {
|
test: {
|
||||||
API_URI: "http://localhost:5010/api/v1",
|
API_URI: "http://localhost:5010/api/v1",
|
||||||
|
|
@ -52,6 +53,7 @@ const config = ref<any>({
|
||||||
API_RETIREMENT_URI: `${window.location.protocol}//${window.location.host}/api/v1`,
|
API_RETIREMENT_URI: `${window.location.protocol}//${window.location.host}/api/v1`,
|
||||||
API_PROBATION_URI: `${window.location.protocol}//${window.location.host}/api/v1/probation`,
|
API_PROBATION_URI: `${window.location.protocol}//${window.location.host}/api/v1/probation`,
|
||||||
API_REPORT2_URI: `${window.location.protocol}//${window.location.host}/api/v2`,
|
API_REPORT2_URI: `${window.location.protocol}//${window.location.host}/api/v2`,
|
||||||
|
LINK_EVALUATE_PUBLISH: `${window.location.protocol}//${window.location.host}`,
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -81,6 +83,7 @@ const API_PROBATION_URI = ref<string>(
|
||||||
config.value[env.value].API_PROBATION_URI
|
config.value[env.value].API_PROBATION_URI
|
||||||
);
|
);
|
||||||
const API_REPORT2_URI = ref<string>(config.value[env.value].API_REPORT2_URI);
|
const API_REPORT2_URI = ref<string>(config.value[env.value].API_REPORT2_URI);
|
||||||
|
const LINK_EVALUATE_PUBLISH = ref<string>(config.value[env.value].LINK_EVALUATE_PUBLISH);
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
env: env.value,
|
env: env.value,
|
||||||
|
|
@ -97,4 +100,5 @@ export default {
|
||||||
API_RETIREMENT_URI: API_RETIREMENT_URI.value,
|
API_RETIREMENT_URI: API_RETIREMENT_URI.value,
|
||||||
API_PROBATION_URI: API_PROBATION_URI.value,
|
API_PROBATION_URI: API_PROBATION_URI.value,
|
||||||
API_REPORT2_URI: API_REPORT2_URI.value,
|
API_REPORT2_URI: API_REPORT2_URI.value,
|
||||||
|
LINK_EVALUATE_PUBLISH: LINK_EVALUATE_PUBLISH.value,
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,9 @@ import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
import { useRouter, useRoute } from "vue-router";
|
import { useRouter, useRoute } from "vue-router";
|
||||||
import genReport from "@/plugins/genreport";
|
import genReport from "@/plugins/genreport";
|
||||||
|
import { useEvaluateDetailStore } from "@/modules/12_evaluatePersonal/store/EvaluateDetail";
|
||||||
|
|
||||||
|
const store = useEvaluateDetailStore();
|
||||||
|
|
||||||
const modalView = ref<boolean>(false);
|
const modalView = ref<boolean>(false);
|
||||||
const fullName = ref<string>(
|
const fullName = ref<string>(
|
||||||
|
|
@ -70,7 +73,19 @@ function deleteFile(name: string) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function save() {
|
function save() {
|
||||||
console.log("save");
|
showLoader();
|
||||||
|
http
|
||||||
|
.put(config.API.evaluationNext5To6(id.value))
|
||||||
|
// .then((res) => {})
|
||||||
|
.catch((e) => {
|
||||||
|
messageError($q, e);
|
||||||
|
})
|
||||||
|
.finally(() => {
|
||||||
|
success($q, "บันทึกแจ้งผลการประกาศคัดเลือกสำเร็จ");
|
||||||
|
store.step = 6;
|
||||||
|
store.currentStep = 6;
|
||||||
|
hideLoader();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function upLoadFile() {
|
function upLoadFile() {
|
||||||
|
|
@ -169,7 +184,7 @@ function getDate() {
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
const data = res.data.result;
|
const data = res.data.result;
|
||||||
AnnouncementStartDate.value = date2Thai(data.dateStartAnnounce);
|
AnnouncementStartDate.value = date2Thai(data.dateStartAnnounce);
|
||||||
const endDate = new Date(data.dateEndAnnounce);
|
const endDate = new Date(data.dateStartAnnounce);
|
||||||
endDate.setDate(endDate.getDate() + 30);
|
endDate.setDate(endDate.getDate() + 30);
|
||||||
AnnouncementEndDate.value = date2Thai(endDate);
|
AnnouncementEndDate.value = date2Thai(endDate);
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -12,8 +12,7 @@ const router = useRouter();
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const id = ref<string>(route.params.id as string);
|
const id = ref<string>(route.params.id as string);
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const AnnouncementStartDate = ref<string | null>();
|
const dateEndPrepareDoc2 = ref<string | null>();
|
||||||
const AnnouncementEndDate = ref<string | null>();
|
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
const { date2Thai, showLoader, hideLoader, messageError, success } = mixin;
|
const { date2Thai, showLoader, hideLoader, messageError, success } = mixin;
|
||||||
const AnnouncementDate = ref<string | null>(date2Thai(new Date()));
|
const AnnouncementDate = ref<string | null>(date2Thai(new Date()));
|
||||||
|
|
@ -44,10 +43,12 @@ function getDate() {
|
||||||
.get(config.API.evaluationDateAnnounce(id.value))
|
.get(config.API.evaluationDateAnnounce(id.value))
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
const data = res.data.result;
|
const data = res.data.result;
|
||||||
AnnouncementStartDate.value = date2Thai(data.dateStartAnnounce);
|
|
||||||
const endDate = new Date(data.dateStartAnnounce);
|
const endDate = new Date(data.dateStartAnnounce);
|
||||||
endDate.setDate(endDate.getDate() + 30);
|
endDate.setDate(endDate.getDate() + 210);
|
||||||
AnnouncementEndDate.value = date2Thai(endDate);
|
dateEndPrepareDoc2.value = date2Thai(endDate);
|
||||||
|
dateEndPrepareDoc2.value = data.dateEndPrepareDoc2
|
||||||
|
? date2Thai(data.dateEndPrepareDoc2)
|
||||||
|
: dateEndPrepareDoc2.value;
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
messageError($q, e);
|
messageError($q, e);
|
||||||
|
|
@ -88,8 +89,7 @@ onMounted(() => {
|
||||||
<q-banner class="text-weight-bold text-red-14 bg-red-2 text-center">
|
<q-banner class="text-weight-bold text-red-14 bg-red-2 text-center">
|
||||||
<div class="text-weight-bold">
|
<div class="text-weight-bold">
|
||||||
<q-icon name="info_outline" color="red-14" size="24px" />
|
<q-icon name="info_outline" color="red-14" size="24px" />
|
||||||
ประกาศเมื่อวันที่ {{ AnnouncementStartDate }} ถึงวันที่
|
วันสุดท้ายของการส่งผลงานคือวันที่ {{ dateEndPrepareDoc2 }}
|
||||||
{{ AnnouncementEndDate }}
|
|
||||||
</div>
|
</div>
|
||||||
</q-banner>
|
</q-banner>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,9 @@ import { useQuasar } from "quasar";
|
||||||
import keycloak from "@/plugins/keycloak";
|
import keycloak from "@/plugins/keycloak";
|
||||||
|
|
||||||
import genReport from "@/plugins/genreport";
|
import genReport from "@/plugins/genreport";
|
||||||
|
import { useEvaluateDetailStore } from "@/modules/12_evaluatePersonal/store/EvaluateDetail";
|
||||||
|
|
||||||
|
const store = useEvaluateDetailStore();
|
||||||
|
|
||||||
const fullName = ref<string>(
|
const fullName = ref<string>(
|
||||||
keycloak.tokenParsed ? keycloak.tokenParsed.name!.toString() : ""
|
keycloak.tokenParsed ? keycloak.tokenParsed.name!.toString() : ""
|
||||||
|
|
@ -160,10 +163,27 @@ function confirmApprove(){
|
||||||
}).catch((e)=>{
|
}).catch((e)=>{
|
||||||
messageError($q,e)
|
messageError($q,e)
|
||||||
}).finally(()=>{
|
}).finally(()=>{
|
||||||
|
nextStep();
|
||||||
modalConfirm.value = false
|
modalConfirm.value = false
|
||||||
hideLoader()
|
hideLoader()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function nextStep(){
|
||||||
|
showLoader();
|
||||||
|
http
|
||||||
|
.put(config.API.evaluationNextFinish(id.value))
|
||||||
|
// .then((res) => {})
|
||||||
|
.catch((e) => {
|
||||||
|
messageError($q, e);
|
||||||
|
})
|
||||||
|
.finally(() => {
|
||||||
|
success($q, "ยืนยันผลการพิจารณาสำเร็จ");
|
||||||
|
store.step = 9;
|
||||||
|
store.currentStep = 9;
|
||||||
|
hideLoader();
|
||||||
|
});
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import { ref } from "vue";
|
||||||
import { useRouter, useRoute } from "vue-router";
|
import { useRouter, useRoute } from "vue-router";
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
import { useQuasar } from "quasar";
|
import { useQuasar } from "quasar";
|
||||||
|
import env from "@/api";
|
||||||
|
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
const mixin = useCounterMixin();
|
const mixin = useCounterMixin();
|
||||||
|
|
@ -10,23 +11,23 @@ const { success } = mixin;
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const id = ref<string>(route.params.id as string);
|
const id = ref<string>(route.params.id as string);
|
||||||
const status = ref<string>("DONE");
|
const status = ref<string>("DONE");
|
||||||
const link = ref<string>('https://bma-ehr-publish.frappet.synology.me')
|
const link = ref<string>(env.LINK_EVALUATE_PUBLISH);
|
||||||
|
|
||||||
function copyLink(){
|
function copyLink() {
|
||||||
const linkById = `${link.value}/${id.value}`
|
const linkById = `${link.value}/${id.value}`;
|
||||||
navigator.clipboard.writeText(linkById);
|
navigator.clipboard.writeText(linkById);
|
||||||
success($q,'คัดลอกสำเร็จ')
|
success($q, "คัดลอกสำเร็จ");
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-12 text-center">
|
<div class="col-12 text-center">
|
||||||
<div>
|
<!-- <div> -->
|
||||||
<p class="text-weight-bold" style="font-size: 18px;">Public URL</p>
|
<p class="text-weight-bold q-mb-none">Public URL</p>
|
||||||
<a :href="link" target="_blank">{{ link }}</a>
|
<!-- <a :href="link + '/' + id" target="_blank">{{ `${link}/${id}` }}</a> -->
|
||||||
</div>
|
<!-- </div> -->
|
||||||
|
|
||||||
<q-btn
|
<q-btn
|
||||||
class="q-mt-md"
|
class="q-mt-md"
|
||||||
outline
|
outline
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue