Commit baa64377 authored by 罗超's avatar 罗超

2

parent 85634937
<template>
<div class="page-body">
<!-- <iframe ref="mainIframe" :src="url" class="coffee" frameborder="0"></iframe> -->
</div>
</template>
<script>
export default {
meta: {
title: "商品管理"
},
data() {
return {
url: `http://127.0.0.1:8080/#/`
//url:'http://mall.oytour.com/#/'
}
},
mounted() {
// let userinfo = JSON.parse(localStorage.getItem('loginUserInfo')).data
// let obj={
// token:userinfo.MallToken,
// Id:userinfo.Id,
// GroupId:userinfo.Group_Id,
// TenantId:userinfo.JHTenantId,
// }
// let jsonData=JSON.stringify(obj)
// const mapFrame = this.$refs.mainIframe
// if (mapFrame.attachEvent) { // 兼容浏览器判断
// mapFrame.attachEvent('onload', function () {
// const iframeWin = mapFrame.contentWindow
// iframeWin.postMessage(jsonData, '*')
// })
// } else {
// mapFrame.onload = function () {
// const iframeWin = mapFrame.contentWindow
// iframeWin.postMessage(jsonData, '*')
// }
// }
}
}
</script>
<style>
.coffee {
width: 100%;
height: calc(100vh - 120px);
}
</style>
<template> <template>
<div class="page-body"> <div class="page-body">
<iframe :src="url" class="coffee" frameborder="0"></iframe> <iframe ref="mainIframe" :src="url" class="coffee" frameborder="0"></iframe>
</div> </div>
</template> </template>
<script> <script>
export default { export default {
meta: { meta: {
title: "商品管理" title: "商品管理"
}, },
data() { data() {
return { return {
url:`http://127.0.0.1:8080/#/coffeeManage/index?token=''` url: `http://127.0.0.1:8080/#/coffeeManage/index`
} //url:'http://mall.oytour.com/#/coffeeManage/index'
}
}, },
mounted(){ mounted() {
let userinfo=JSON.parse(localStorage.getItem('loginUserInfo')).data let userinfo = JSON.parse(localStorage.getItem('loginUserInfo')).data
this.url="http://127.0.0.1:8080/#/coffeeManage/index?token="+userinfo.MallToken let obj={
token:userinfo.MallToken,
Id:userinfo.Id,
GroupId:userinfo.Group_Id,
TenantId:userinfo.JHTenantId,
}
let jsonData=JSON.stringify(obj)
const mapFrame = this.$refs.mainIframe
if (mapFrame.attachEvent) { // 兼容浏览器判断
mapFrame.attachEvent('onload', function () {
const iframeWin = mapFrame.contentWindow
iframeWin.postMessage(jsonData, '*')
})
} else {
mapFrame.onload = function () {
const iframeWin = mapFrame.contentWindow
iframeWin.postMessage(jsonData, '*')
}
}
} }
} }
</script> </script>
<style> <style>
.coffee{ .coffee {
width: 100%; width: 100%;
height: calc(100vh - 120px); height: calc(100vh - 120px);
} }
</style>
\ No newline at end of file </style>
<template>
<div class="page-body">
<iframe ref="mainIframe" :src="url" class="coffee" frameborder="0"></iframe>
</div>
</template>
<script>
export default {
meta: {
title: "商品管理"
},
data() {
return {
url: `http://127.0.0.1:8080/#/coffeeManage/order`
//url:'http://mall.oytour.com/#/coffeeManage/order'
}
},
mounted() {
let userinfo = JSON.parse(localStorage.getItem('loginUserInfo')).data
let obj={
token:userinfo.MallToken,
Id:userinfo.Id,
GroupId:userinfo.Group_Id,
TenantId:userinfo.JHTenantId,
}
let jsonData=JSON.stringify(obj)
const mapFrame = this.$refs.mainIframe
if (mapFrame.attachEvent) { // 兼容浏览器判断
mapFrame.attachEvent('onload', function () {
const iframeWin = mapFrame.contentWindow
iframeWin.postMessage(jsonData, '*')
})
} else {
mapFrame.onload = function () {
const iframeWin = mapFrame.contentWindow
iframeWin.postMessage(jsonData, '*')
}
}
}
}
</script>
<style>
.coffee {
width: 100%;
height: calc(100vh - 120px);
}
</style>
...@@ -1517,6 +1517,16 @@ const routes = [{ ...@@ -1517,6 +1517,16 @@ const routes = [{
component: () => component: () =>
import("pages/stuMan/coffeeManage/coffeeOrderList") import("pages/stuMan/coffeeManage/coffeeOrderList")
}, },
{
path: "/stuMan/coffeeManage/order",//学管 订单列表
component: () =>
import("pages/stuMan/coffeeManage/order")
},
{
path: "/stuMan/coffeeManage/afterOrder",//学管 售后订单列表
component: () =>
import("pages/stuMan/coffeeManage/afterOrder")
},
{ {
path: "/stuMan/activeList",//学管 活动列表 path: "/stuMan/activeList",//学管 活动列表
component: () => component: () =>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment