updated get tree by system

This commit is contained in:
Warunee Tamkoo 2024-08-20 10:39:17 +07:00
parent af56b950b1
commit ffde0fe79c
27 changed files with 128 additions and 72 deletions

View file

@ -20,6 +20,9 @@ import CardPosition from "@/modules/05_placement/components/PersonalList/CardPos
/** importStore*/
import { useCounterMixin } from "@/stores/mixin";
import { useSelectOrgStore } from "@/modules/05_placement/stores/storeSelect";
import { useRoute } from "vue-router";
const route = useRoute();
/** use*/
const $q = useQuasar();
@ -93,7 +96,7 @@ async function fetchOrganizationActive() {
async function fetchDataTree(id: string) {
showLoader();
await http
.get(config.API.orgByid(id.toString()))
.get(config.API.orgByIdSystem(id, route.meta.Key as string))
.then((res) => {
const data = res.data.result;
if (data) {

View file

@ -21,6 +21,7 @@ import type {
DataPositionNo,
TreeMain,
} from "@/modules/05_placement/interface/response/Receive";
import { useRoute } from "vue-router";
const $q = useQuasar();
const mixin = useCounterMixin(); //
const {
@ -33,6 +34,7 @@ const {
} = mixin; //
const nodeLevel = ref<number>(0);
const route = useRoute();
const isAll = ref<boolean>(false);
const isBlank = ref<boolean>(false);
@ -471,7 +473,7 @@ function getSumPosition(data: SumPosition) {
async function fetchDataTree(id: string) {
showLoader();
await http
.get(config.API.orgByid(id.toString()))
.get(config.API.orgByIdSystem(id, route.meta.Key as string))
.then((res) => {
const data = res.data.result;
nodes.value = data;