<template>
  <view class="leave-page">
    教务处确认
  </view>
</template>

<script setup lang="ts">
import { findQjById } from '@/api/base/jsQjApi';
import { onLoad } from '@dcloudio/uni-app';
import { useDataStore } from "@/store/modules/data";
const { setData } = useDataStore();

const dbFlag = ref(false);

onLoad(async (data: any) => {
  // 从待办过来的，需要从后端获取数据
  if (data && data.from && data.from == "db") {
    dbFlag.value = true;
    const res = await findQjById({ id: data.id });
    nextTick(() => {
      setData(res.result);
    });
  } else {
    dbFlag.value = false;
  }
});
</script>

<style lang="scss" scoped>
.leave-page {
  height: 100vh;
}
</style> 