mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/student-h5.git
synced 2025-12-07 09:56:45 +08:00
feat:修改跳转
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="projectdetails">
|
||||
<div class="projectdetails" v-if="data?.projectId">
|
||||
<ReturnHead
|
||||
text="项目详情"
|
||||
:showfile="true"
|
||||
@@ -200,6 +200,13 @@
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
<div v-else>
|
||||
<el-result icon="success" title="您不是此项目学员" sub-title="请联系管理员">
|
||||
<template #extra>
|
||||
<el-button type="primary" @click="toIndex">返回首页</el-button>
|
||||
</template>
|
||||
</el-result>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
@@ -242,16 +249,17 @@ watch(
|
||||
},
|
||||
{ deep: true }
|
||||
);
|
||||
watch(data, () => {
|
||||
console.log("data.value.projectId", data.value);
|
||||
if (data && data.value && !data.value.projectId) {
|
||||
ElMessage.warning("您不是此项目的学员");
|
||||
window.open(
|
||||
import.meta.env.VITE_BOE_BASE_URL + "/mobile/pages/index/index",
|
||||
"_self"
|
||||
);
|
||||
}
|
||||
});
|
||||
// watch(data, () => {
|
||||
// console.log("data.value.projectId", data.value);
|
||||
// if (data && data.value && !data.value.projectId) {
|
||||
// ElMessage.warning("您不是此项目的学员");
|
||||
// console.log("您不是此项目的学员");
|
||||
// // window.open(
|
||||
// // import.meta.env.VITE_BOE_BASE_URL + "/mobile/pages/index/index",
|
||||
// // "_self"
|
||||
// // );
|
||||
// }
|
||||
// });
|
||||
|
||||
function getTaskStatus(d) {
|
||||
if (data.value.status !== 3) {
|
||||
@@ -576,6 +584,9 @@ const queryAllStatus = (data) => {
|
||||
}
|
||||
return true;
|
||||
};
|
||||
function toIndex() {
|
||||
window.location.href = import.meta.env.VITE_BOE_API_URL;
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
|
||||
Reference in New Issue
Block a user