fetch รายงานเมื่อเปลี่ยนหน่วยงาน ==> รายงานโครงสร้างและกรอบอัตรากำลัง
This commit is contained in:
parent
60a09db3b7
commit
37e254be2e
1 changed files with 12 additions and 1 deletions
|
|
@ -1,5 +1,5 @@
|
|||
<script setup lang="ts">
|
||||
import { ref } from "vue";
|
||||
import { ref, watch } from "vue";
|
||||
import { useQuasar } from "quasar";
|
||||
import axios from "axios";
|
||||
import { VuePDF, usePDF } from "@tato30/vue-pdf";
|
||||
|
|
@ -115,6 +115,17 @@ function backPage() {
|
|||
page.value--;
|
||||
}
|
||||
}
|
||||
|
||||
/** ติดตามการเปลี่ยนแปลงของ orgRootId */
|
||||
watch(
|
||||
() => orgRootId.value,
|
||||
async () => {
|
||||
// เมื่อ orgRootId มีค่าและ title มีค่า เราจะเรียก getReport
|
||||
if (orgRootId.value && title.value) {
|
||||
await getReport(title.value);
|
||||
}
|
||||
}
|
||||
);
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue