提交 ec39870a authored 作者: 王鹏飞's avatar 王鹏飞

update

上级 6c561acb
...@@ -22,7 +22,8 @@ module.exports = { ...@@ -22,7 +22,8 @@ module.exports = {
}, },
ProvidePlugin: {}, ProvidePlugin: {},
others: { others: {
baseUrl: 'https://learn-api.ezijing.com', loginUrl: 'https://login.ezijing.com/auth/login/index',
loginUrl: 'https://login.ezijing.com/auth/login/index' pcPreviewUrl: 'https://shop2.ezijing.com',
h5PreviewUrl: 'https://h5-shop2.ezijing.com'
} }
} }
...@@ -14,7 +14,8 @@ module.exports = { ...@@ -14,7 +14,8 @@ module.exports = {
}, },
ProvidePlugin: {}, ProvidePlugin: {},
others: { others: {
baseUrl: 'https://learn-api.ezijing.com', loginUrl: 'https://login.ezijing.com/auth/login/index',
loginUrl: 'https://login.ezijing.com/auth/login/index' pcPreviewUrl: 'https://shop.ezijing.com',
h5PreviewUrl: 'https://h5-shop.ezijing.com'
} }
} }
...@@ -14,7 +14,8 @@ module.exports = { ...@@ -14,7 +14,8 @@ module.exports = {
}, },
ProvidePlugin: {}, ProvidePlugin: {},
others: { others: {
baseUrl: 'https://learn-api2.ezijing.com', loginUrl: 'https://login.ezijing.com/auth/login/index',
loginUrl: 'https://login2.ezijing.com/auth/login/index' pcPreviewUrl: 'https://shop2.ezijing.com',
h5PreviewUrl: 'https://h5-shop2.ezijing.com'
} }
} }
...@@ -176,7 +176,7 @@ export default { ...@@ -176,7 +176,7 @@ export default {
}, },
// 推广 // 推广
handlePromote(row) { handlePromote(row) {
this.shareUrl = `https://h5-shop.ezijing.com/buy?shop_id=${row.shop_id}&id=${row.spu_id}` this.shareUrl = `${webConf.others.h5PreviewUrl}/buy?shop_id=${row.shop_id}&id=${row.spu_id}`
this.shareDialogVisible = true this.shareDialogVisible = true
}, },
// 复制 // 复制
......
...@@ -98,7 +98,7 @@ export default { ...@@ -98,7 +98,7 @@ export default {
}, },
// 推广 // 推广
handlePromote(row) { handlePromote(row) {
this.shareUrl = `https://h5-shop.ezijing.com/shop?shop_id=${row.shop_id}&group_id=${row.group_id}` this.shareUrl = `${webConf.others.h5PreviewUrl}/shop?shop_id=${row.shop_id}&group_id=${row.group_id}`
this.shareDialogVisible = true this.shareDialogVisible = true
} }
}, },
......
...@@ -2,7 +2,9 @@ ...@@ -2,7 +2,9 @@
<div class="preview"> <div class="preview">
<div class="preview-hd"> <div class="preview-hd">
<div class="preview-hd-inner"> <div class="preview-hd-inner">
<div class="preview-hd-left">预览:<span class="active">手机版</span><span>PC版</span></div> <div class="preview-hd-left">
预览:<span class="active">手机版</span><span><a :href="pcPreviewUrl" target="_blank">PC版</a></span>
</div>
<div class="preview-hd-right"> <div class="preview-hd-right">
<el-button size="small" type="primary" plain @click="handleEdit">编辑本商品</el-button> <el-button size="small" type="primary" plain @click="handleEdit">编辑本商品</el-button>
<el-button size="small" type="primary" plain @click="handleAdd">发布新商品</el-button> <el-button size="small" type="primary" plain @click="handleAdd">发布新商品</el-button>
...@@ -10,7 +12,9 @@ ...@@ -10,7 +12,9 @@
</div> </div>
</div> </div>
</div> </div>
<div class="preview-bd"></div> <div class="preview-bd">
<iframe :src="h5PreviewUrl" frameborder="0" width="100%" height="100%"></iframe>
</div>
</div> </div>
</template> </template>
...@@ -22,6 +26,12 @@ export default { ...@@ -22,6 +26,12 @@ export default {
}, },
goodsId() { goodsId() {
return this.$route.query.id return this.$route.query.id
},
pcPreviewUrl() {
return `${webConf.others.pcPreviewUrl}/buy?shop_id=${this.shopId}&id=${this.goodsId}`
},
h5PreviewUrl() {
return `${webConf.others.h5PreviewUrl}/buy?shop_id=${this.shopId}&id=${this.goodsId}`
} }
}, },
methods: { methods: {
...@@ -39,6 +49,11 @@ export default { ...@@ -39,6 +49,11 @@ export default {
</script> </script>
<style lang="scss"> <style lang="scss">
.preview {
height: 100vh;
display: flex;
flex-direction: column;
}
.preview-hd { .preview-hd {
background-color: #fff; background-color: #fff;
border-bottom: 1px solid #c1c1c1; border-bottom: 1px solid #c1c1c1;
...@@ -59,4 +74,8 @@ export default { ...@@ -59,4 +74,8 @@ export default {
border-bottom: 1px solid #3276fc; border-bottom: 1px solid #3276fc;
} }
} }
.preview-bd {
flex: 1;
overflow: hidden;
}
</style> </style>
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论