zhouwx
2024-06-14 137910cf4fc73a3a2787a3a02718f1e1f637c368
src/views/safetyReview/projectManage/components/confirmEnd.vue
@@ -48,7 +48,7 @@
import Cookies from "js-cookie";
import { getToken } from "@/utils/auth";
import confirmEndDialog from './confirmEndDialog.vue'
import {delProject, getAccessoryFile} from "@/api/projectManage/project";
import {delProject, getAccessoryFile, getProjectStatus} from "@/api/projectManage/project";
import {delRecitification, doConfirm, getRecognitionList} from "@/api/projectManage/riskAnalysis";
import axios from "axios";
import { useRoute } from 'vue-router'
@@ -65,6 +65,7 @@
  recitificationList: [],
})
const isEnd = ref(false)
const total = ref(0);
const isAmin = ref(false)
const formRef = ref();
@@ -76,8 +77,22 @@
  if(props.projectId){
    state.formData.projectId = props.projectId;
    getList(state.formData.projectId);
    getStatus(state.formData.projectId);
  }
  isEnd.value = Cookies.get('end')
  projectType.value = route.query.type;
});
const getStatus = async (projectId) => {
  const res = await getProjectStatus(projectId);
  if(res.code == 200){
    if(res.data === 14){
      isEnd.value = true
    }
  }
}
const getList = async (val) => {
@@ -91,7 +106,7 @@
}
const projectType = ref('')
const isEnd = ref(false)
const riskOpen = async (type,val) => {
  // await  getList(val);
  projectType.value = route.query.type;