ประเมินบุคคล

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2023-12-27 12:08:36 +07:00
parent aa23748eb2
commit e33d5eed1b
13 changed files with 757 additions and 164 deletions

View file

@ -1,5 +1,6 @@
<script setup lang="ts">
import { ref, onMounted } from "vue";
import { useRoute } from "vue-router";
import http from "@/plugins/http";
import config from "@/app.config";
import { useQuasar } from "quasar";
@ -11,13 +12,16 @@ import { useEvaluateStore } from "@/modules/06_evaluate/store";
const $q = useQuasar();
const store = useEvaluateStore();
const mixin = useCounterMixin();
const route = useRoute();
const { showLoader, hideLoader, messageError } = mixin;
const props = defineProps({
evaluateId: {
type: String,
},
});
const evaluateId = ref<string>(route.params.id.toString());
// const props = defineProps({
// evaluateId: {
// type: String,
// },
// });
const emit = defineEmits(["update:file"]);
const selectedItem = ref(1);
@ -37,9 +41,9 @@ function handleItemClick(itemNumber: number) {
}
async function fetchDocument(fileName: string) {
// showLoader();
props.evaluateId &&
evaluateId.value &&
(await http
.get(config.API.loadFileDocument("เล่ม 1", props.evaluateId, fileName))
.get(config.API.loadFileDocument("เล่ม 1", evaluateId.value, fileName))
.then((res) => {
downloadFile(res.data.downloadUrl);
})