Commit 7266d10d authored by 程卓's avatar 程卓

徐汇的判断是否为超管,不是则隐藏dashboard部分模块,隐藏投诉信息和处置单列表

parent 27307011
......@@ -3,6 +3,7 @@ import pudong from '@/router/pudongRoutes.json'
import xuhui from '@/router/xuhuiRoutes.json'
import huangpu from '@/router/huangpuRoutes.json'
import yangpu from '@/router/yangpuRoutes.json'
import Store from '@/store/index'
async function GetRoutes(router) {
let env = process.env.NODE_ENV
......@@ -44,11 +45,21 @@ async function GetRoutes(router) {
break
default: // 当前仅可使用pudong / xuhui-sit/uat进行打包
MicRouters = pudong
MicRouters = xuhui
break
}
console.log(MicRouters)
// 徐汇区的子项目要看当前用户是否是超管,否则不展示 处置单和投诉
// console.log(env)
if (env.indexOf('xuhui') != -1) {
let newArr= []
MicRouters.Layout.forEach((item) => {
if (item.name != 'tousu' && item.name != 'Disposal' ) {
newArr.push(item)
}
})
MicRouters.Layout = newArr
}
const micSystemRoutersConfigs = Object.assign({}, MicRouters)
const { routes } = router.options
......
......@@ -62,9 +62,9 @@ case 'huangpu-prod':
default: // 默认环境下(开发环境)
// BASE_URL = 'http://31.0.161.39/apiv2'
// BASE_URL = 'http://211.136.105.193/apiv2'
// BASE_URL = 'http://xuhui.hm.omniview.pro/api/v2'
BASE_URL = 'http://xuhui.hm.omniview.pro/api/v2'
// BASE_URL = 'http://pudong.hm.omniview.pro/api/v2'
BASE_URL = 'http://211.136.105.193/apiv2'
// BASE_URL = 'http://211.136.105.193/apiv2'
// MOCK_URL = 'https://yapi.omniview.pro/mock/278'
break
......
<template>
<div>
<!-- 浦东 -->
<div id="home" class="layoutPadding" v-if="(this.$api.BASE_URL).indexOf('pudong') > -1 || (this.$api.BASE_URL).indexOf('211.136.105.193') > -1">
<div class="topBox-l">
<div class="inner" style="">
......@@ -53,10 +55,9 @@
<RetrofitElevator style="width:32%" />
<ComplaintsTrain moduletitle="应急报修" style="width:36%" />
</div>
</div>
<!-- <div id="home" class="layoutPadding" v-if="(this.$api.BASE_URL).indexOf('xuhui') > -1 || (this.$api.BASE_URL).indexOf('31.0.161.39') > -1"> -->
<div id="home" class="layoutPadding" v-else>
<div id="home" class="layoutPadding" v-if="(this.$api.BASE_URL).indexOf('xuhui') > -1 || (this.$api.BASE_URL).indexOf('31.0.161.39') > -1">
<!-- <div id="home" class="layoutPadding" v-else> -->
<a-row type="flex" class="align-stretch">
<a-col :span="24">
<a-row type="flex" style="height:100%;">
......@@ -166,7 +167,7 @@
</div>
</a-col> -->
</a-row>
<a-row class="align-stretch" style="margin-top:20px;">
<a-row v-if="$store.state.userInfos&&$store.state.userInfos.isAllPerm" class="align-stretch" style="margin-top:20px;">
<a-col :span="8">
<div class="month">
<div class="home-card monthTitle">
......@@ -308,7 +309,7 @@
</div>
</a-col>
</a-row>
<a-row class="align-stretch" style="margin-top:20px;">
<a-row v-if="$store.state.userInfos&&$store.state.userInfos.isAllPerm" class="align-stretch" style="margin-top:20px;">
<a-col :span="8">
<div class="fengxian">
<div class="home-card fengxianTitle">
......@@ -625,6 +626,8 @@
</a-col>
</a-row>
</div>
</div>
</template>
<script>
......@@ -714,19 +717,22 @@ export default {
console.log('徐汇')
this.getList()
this.getConfig()
this.getDisposal()
this.getHouthMonth()
this.getCheckData()
this.getCheckPeople()
this.getSectNum()
this.getReceiptsNum()
this.getRepair()
this.getTousuQuestion('M')
this.getTousuQuestion('Y')
this.getTousuQuestion('S')
this.getTousuDensity('M')
this.getTousuDensity('Y')
this.getTousuDensity('S')
if (this.$store.state.userinfos && this.$store.state.userinfos.isAllPerm) { // 不是全部权限dashboard下方的模块不展示
this.getDisposal()
this.getHouthMonth()
this.getCheckData()
this.getCheckPeople()
this.getSectNum()
this.getReceiptsNum()
this.getRepair()
this.getTousuQuestion('M')
this.getTousuQuestion('Y')
this.getTousuQuestion('S')
this.getTousuDensity('M')
this.getTousuDensity('Y')
this.getTousuDensity('S')
}
}
},
......
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