mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-11 11:56:44 +08:00
增加新的跳转的页面
This commit is contained in:
@@ -39,6 +39,13 @@ export const constantRoutes = [{
|
|||||||
name: 'index',
|
name: 'index',
|
||||||
meta: { title: '首页', icon: 'dashboard', noCache: true, affix: false },
|
meta: { title: '首页', icon: 'dashboard', noCache: true, affix: false },
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: '/forward',
|
||||||
|
hidden: true,
|
||||||
|
component: (resolve) => require(['@/views/Forward'], resolve),
|
||||||
|
name: 'forward',
|
||||||
|
meta: { title: '详细信息', icon: 'dashboard', noCache: true, affix: false },
|
||||||
|
},
|
||||||
{
|
{
|
||||||
path: '/course',
|
path: '/course',
|
||||||
hidden: true,
|
hidden: true,
|
||||||
|
|||||||
41
src/views/Forward.vue
Normal file
41
src/views/Forward.vue
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
<template>
|
||||||
|
<div class="box">
|
||||||
|
<portal-header :hideSearch="true"></portal-header>
|
||||||
|
<iframe :src="url" style="width: 100%;height: 100%;margin-top: 30px;" frameborder="0"></iframe>
|
||||||
|
<portal-footer></portal-footer>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import portalHeader from "@/components/PortalHeader.vue";
|
||||||
|
import portalFooter from "@/components/PortalFooter.vue";
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
portalHeader,
|
||||||
|
portalFooter
|
||||||
|
},
|
||||||
|
data(){
|
||||||
|
return {
|
||||||
|
url: "",
|
||||||
|
boeUrl:process.env.VUE_APP_BOE_WEB_URL
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
let params = this.$route.query.params;// 跳转的参数 encodeURIComponent 之后的
|
||||||
|
let to = this.$route.query.to;//跳转的地址,以 /开头的地址
|
||||||
|
let urlPre=window.location.protocol+'//'+window.location.host;
|
||||||
|
this.url=urlPre+to
|
||||||
|
if(params){
|
||||||
|
this.url=this.url+'?'+params;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods:{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style lang="scss" >
|
||||||
|
.box{
|
||||||
|
// width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user