mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-10 03:16:44 +08:00
路径图超时加载一分钟
This commit is contained in:
@@ -83,3 +83,6 @@ http.interceptors.response.use(
|
||||
);
|
||||
|
||||
export default http;
|
||||
export function setHttpTimeout(newTimeout) {
|
||||
http.defaults.timeout = newTimeout;
|
||||
}
|
||||
|
||||
@@ -47,9 +47,17 @@
|
||||
:tabBarStyle="{ marginLeft: '10px' }"
|
||||
>
|
||||
<a-tab-pane key="1" tab="概览">
|
||||
<div class="split"></div>
|
||||
<div class="split"></div>
|
||||
<!-- 概览(无数据) -->
|
||||
<div v-if="!hasTask">
|
||||
<div v-if="reuse" class="reuse">
|
||||
<div class="onerow">
|
||||
<div class="taskmain">关卡概览</div>
|
||||
</div>
|
||||
<div>
|
||||
<a-button class="reuse_btn" type="primary" @click="totaskaaa">重新加载</a-button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="onerow">
|
||||
<div class="taskmain">快速创建路径图详情</div>
|
||||
</div>
|
||||
@@ -1486,6 +1494,7 @@ import TaskImpStu from "../../components/drawers/TaskFaceIn";
|
||||
import { checkPer,fixDoublePer } from "@/utils/utils";
|
||||
import {getCookieForName} from "@/api/method";
|
||||
import qrCode from "@/utils/qrCode";
|
||||
import { setHttpTimeout } from '@/api/config';
|
||||
export default {
|
||||
name: "LevelAdd",
|
||||
components: {
|
||||
@@ -1514,6 +1523,13 @@ export default {
|
||||
AddOpenCourse
|
||||
},
|
||||
setup() {
|
||||
const totaskaaa = ()=>{
|
||||
setHttpTimeout(1000*60);
|
||||
state.addLoading = true;
|
||||
getOverview();
|
||||
myGetRouterDetail();
|
||||
reget();
|
||||
}
|
||||
const getTaskListAll = () =>{
|
||||
state.addLoading = true;
|
||||
getOverview();
|
||||
@@ -1623,6 +1639,7 @@ export default {
|
||||
const headers = { token: getCookieForName("token") };
|
||||
// const store = useStore();
|
||||
const state = reactive({
|
||||
reuse:false,
|
||||
createId: null,
|
||||
permissions: "",
|
||||
hasTask: false,
|
||||
@@ -2456,6 +2473,7 @@ export default {
|
||||
state.addLoading = false;
|
||||
message.error("概览获取失败");
|
||||
console.log("获取失败" + err);
|
||||
state.reuse = true
|
||||
});
|
||||
};
|
||||
|
||||
@@ -3169,7 +3187,8 @@ export default {
|
||||
coursePlanRef,
|
||||
openCourse,
|
||||
exportScore,
|
||||
getTaskListAll
|
||||
getTaskListAll,
|
||||
totaskaaa
|
||||
};
|
||||
},
|
||||
};
|
||||
@@ -4558,7 +4577,24 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.reuse{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
margin-bottom: 50px;
|
||||
.reuse_btn{
|
||||
width: 102px;
|
||||
height: 42px;
|
||||
text-align: center;
|
||||
line-height: 34px;
|
||||
border-radius: 6px;
|
||||
color: #ffffff;
|
||||
font-size: 16px;
|
||||
background: #4ea6ff;
|
||||
margin-right: 38px;
|
||||
margin-top: 15px;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
.taskbox {
|
||||
width: 412px;
|
||||
height: 160px;
|
||||
|
||||
Reference in New Issue
Block a user