feat: 碳证中心添加单独页面,配置共性能力平台链接、调整文档联系人方式
This commit is contained in:
parent
02245366b2
commit
a6a16af889
@ -48,7 +48,8 @@
|
||||
|
||||
## 技术联系
|
||||
|
||||
> 联系人: 谢老师
|
||||
> 联系电话: 15601721332
|
||||
> 联系邮箱: pjsl_service@chainable.com.cn
|
||||
- 联系人: 谢老师
|
||||
- 联系电话: 15601721332
|
||||
- 联系邮箱: pjsl_service@chainable.com.cn
|
||||
|
||||
---
|
||||
|
||||
@ -117,6 +117,7 @@ export default {
|
||||
'/qych': 'qych',
|
||||
'/hyzt': 'hyzt',
|
||||
'/login': 'login',
|
||||
'/tzzx': 'tzzx',
|
||||
},
|
||||
|
||||
menuOptions: [
|
||||
|
||||
@ -117,6 +117,10 @@ function mdviewer() {
|
||||
}
|
||||
|
||||
|
||||
// md文档查看器
|
||||
function tzzx() {
|
||||
return import(/* webpackChunkName: "tzzx" */ '@/pages/index/views/tzzx/index.vue');
|
||||
}
|
||||
|
||||
|
||||
export default [
|
||||
@ -329,4 +333,15 @@ export default [
|
||||
disableBack: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'tzzx',
|
||||
path: '/tzzx',
|
||||
component: tzzx,
|
||||
meta: {
|
||||
title: '碳证中心',
|
||||
isShowSideBar: false,
|
||||
hasHome: true,
|
||||
disableBack: true,
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
@ -12,7 +12,7 @@
|
||||
<div :id="item.id" v-for="(item, index) in GXNLPTtabList" :key="index">
|
||||
<div class="anchor-container-title">{{ item.title }}</div>
|
||||
<div class="anchor-container-box">
|
||||
<div class="anchor-container-box-card" v-for="(v, i) in item.cardList" :key="i">
|
||||
<div class="anchor-container-box-card" v-for="(v, i) in item.cardList" :key="i" @click="handleCardClick(v, $event)">
|
||||
<div class="anchor-container-box-img">
|
||||
<img :src="getIconUrl1(v.img, item.mrimg)" alt="" />
|
||||
<img v-if="v.icon" :src="getIconUrl(v.icon)" alt="" class="anchor-container-box-img-img" />
|
||||
@ -54,19 +54,21 @@ export default {
|
||||
cardList: [
|
||||
{
|
||||
img: '',
|
||||
title: '碳足迹计算器',
|
||||
context: '提供企业碳足迹核算、产品碳足迹计算、供应链碳管理等功能',
|
||||
title: '产品碳足迹',
|
||||
context: '管理你的LCA项目,使用数据集采集与LCA计算功能',
|
||||
url: 'https://www.ouyeel.com/lca/',
|
||||
},
|
||||
{
|
||||
img: '',
|
||||
title: 'CBAM',
|
||||
context: '助力企业快速应对欧盟碳关税政策,了解碳成本,完成CBAM报告',
|
||||
url: 'https://www.ouyeel.com/cbam/',
|
||||
},
|
||||
{
|
||||
img: '',
|
||||
title: '企业碳管理平台',
|
||||
context: '全链条碳足迹追踪,支持多级供应商碳数据管理和分析',
|
||||
},
|
||||
{
|
||||
img: '',
|
||||
title: '供应链碳追踪',
|
||||
context: '提供企业碳足迹核算、产品碳足迹计算、供应链碳管理等功能',
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -197,6 +199,13 @@ export default {
|
||||
el.scrollIntoView({ behavior: 'smooth', block: 'start' });
|
||||
}
|
||||
},
|
||||
handleCardClick(v) {
|
||||
if (v.url) {
|
||||
window.open(v.url, '_blank');
|
||||
} else {
|
||||
this.$message.warning('敬请期待');
|
||||
}
|
||||
},
|
||||
getIconUrl(iconName) {
|
||||
// 使用require动态加载图片
|
||||
return require(`../../assets/icon/${iconName}`);
|
||||
|
||||
@ -2,9 +2,9 @@
|
||||
<div>
|
||||
<Nav @gotoIfreamPage="gotoIfreamPage" @gotoPage="gotoPage" />
|
||||
<div ref="contentWrap" class="content-wrap" :style="isHomePage ? { 'height': documentClientHeight + 'px','margin-top':'0px' } : { 'height': documentClientHeight-64 + 'px','margin-top':'64px' }">
|
||||
<iframe v-if="iframeUrl" :src="iframeUrl" width="100%" height="100%" frameborder="0" scrolling="yes">
|
||||
</iframe>
|
||||
<keep-alive v-else>
|
||||
<!-- <iframe v-if="iframeUrl" :src="iframeUrl" width="100%" height="100%" frameborder="0" scrolling="yes">
|
||||
</iframe> -->
|
||||
<keep-alive>
|
||||
<router-view @gotoIfreamPage="gotoIfreamPage" @gotoPage="gotoPage" />
|
||||
</keep-alive>
|
||||
</div>
|
||||
@ -77,7 +77,10 @@ export default {
|
||||
window.location.href = `/view/mhzc/login`;
|
||||
return;
|
||||
}
|
||||
this.iframeUrl = iframeUrl;
|
||||
// this.iframeUrl = iframeUrl;
|
||||
this.$router.push({
|
||||
path: `/tzzx?page=${iframeUrl}`
|
||||
})
|
||||
},
|
||||
|
||||
|
||||
|
||||
68
txw-mhzc-web/src/pages/index/views/tzzx/index.vue
Normal file
68
txw-mhzc-web/src/pages/index/views/tzzx/index.vue
Normal file
@ -0,0 +1,68 @@
|
||||
<template>
|
||||
<div class="tzzx-page">
|
||||
<div v-if="loading" class="loading">加载中...</div>
|
||||
<iframe
|
||||
v-else-if="iframeUrl"
|
||||
:src="iframeUrl"
|
||||
width="100%"
|
||||
height="100%"
|
||||
frameborder="0"
|
||||
scrolling="yes"
|
||||
></iframe>
|
||||
<div v-else class="empty">链接错误</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'tzzx',
|
||||
data() {
|
||||
return {
|
||||
iframeUrl: '',
|
||||
loading: true,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
this.fetchPage();
|
||||
// 监听路由变化
|
||||
this.$watch(
|
||||
() => this.$route.query,
|
||||
() => this.fetchPage()
|
||||
);
|
||||
},
|
||||
beforeRouteUpdate(to, from, next) {
|
||||
this.fetchPage();
|
||||
next();
|
||||
},
|
||||
methods: {
|
||||
fetchPage() {
|
||||
const { page } = this.$route.query;
|
||||
console.log('page:', page);
|
||||
if (page) {
|
||||
this.iframeUrl = page;
|
||||
this.loading = false;
|
||||
} else {
|
||||
this.iframeUrl = '';
|
||||
this.loading = false;
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.tzzx-page {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
.loading,
|
||||
.empty {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
font-size: 16px;
|
||||
color: #999;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@ -287,30 +287,30 @@ module.exports = {
|
||||
// 会误伤 SPA 路由 /view/mhzc/...,刷新时整页请求被转发到后端导致 Proxy error。必须用 ^ 限定为路径前缀。
|
||||
proxy: {
|
||||
'^/sso': {
|
||||
target: 'http://localhost:9300',
|
||||
// target: 'http://localhost:9300',
|
||||
// target: 'http://carbon.liantu.tech',
|
||||
// target: 'http://www.cciw.com.cn',
|
||||
target: 'https://www.cciw.com.cn',
|
||||
// target: 'http://10.23.20.13:94/',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'^/mhzc': {
|
||||
target: 'http://localhost:9300',
|
||||
// target: 'http://localhost:9300',
|
||||
// target: 'http://carbon.liantu.tech',
|
||||
// target: 'http://www.cciw.com.cn',
|
||||
target: 'https://www.cciw.com.cn',
|
||||
// target: 'http://10.23.20.13:94/',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'^/gxzx': {
|
||||
target: 'http://localhost:9300',
|
||||
// target: 'http://localhost:9300',
|
||||
// target: 'http://carbon.liantu.tech',
|
||||
// target: 'http://www.cciw.com.cn',
|
||||
target: 'https://www.cciw.com.cn',
|
||||
// target: 'http://10.23.20.13:94/',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'^/yygl': {
|
||||
// target: 'http://localhost:20010',
|
||||
target: 'http://carbon.liantu.tech',
|
||||
// target: 'http://www.cciw.com.cn',
|
||||
// target: 'http://carbon.liantu.tech',
|
||||
target: 'https://www.cciw.com.cn',
|
||||
// target: 'http://10.23.20.13:94/',
|
||||
changeOrigin: true,
|
||||
},
|
||||
|
||||
Loading…
Reference in New Issue
Block a user