|
|
@ -19,6 +19,12 @@ |
|
|
|
<use xlink:href="#icon-sync"></use> |
|
|
|
</svg> |
|
|
|
</el-menu-item> |
|
|
|
|
|
|
|
<el-menu-item v-if="isShowBnt" index="3" @click="goScreen()"> |
|
|
|
<svg class="icon-svg aui-navbar__icon-menu aui-navbar__icon-menu--promotion" aria-hidden="true"> |
|
|
|
<use xlink:href="#icon-earth"></use> |
|
|
|
</svg> |
|
|
|
</el-menu-item> |
|
|
|
</el-menu> |
|
|
|
<el-menu class="aui-navbar__menu" mode="horizontal"> |
|
|
|
<!-- <el-menu-item index="1"> |
|
|
@ -77,12 +83,18 @@ export default { |
|
|
|
data () { |
|
|
|
return { |
|
|
|
i18nMessages: messages, |
|
|
|
updatePassowrdVisible: false |
|
|
|
updatePassowrdVisible: false, |
|
|
|
isShowBnt: true, |
|
|
|
streetId: '', |
|
|
|
communityId: '' |
|
|
|
} |
|
|
|
}, |
|
|
|
components: { |
|
|
|
UpdatePassword |
|
|
|
}, |
|
|
|
created () { |
|
|
|
this.getGuess() |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
// 全屏 |
|
|
|
fullscreenHandle () { |
|
|
@ -118,6 +130,26 @@ export default { |
|
|
|
this.$router.push({ name: 'login' }) |
|
|
|
}).catch(() => { }) |
|
|
|
}).catch(() => { }) |
|
|
|
}, |
|
|
|
getGuess () { |
|
|
|
this.$http.post(`/sys/dept/guess/${this.$store.state.user.deptId}`).then(({ data: res }) => { |
|
|
|
if (res.code !== 0) { |
|
|
|
return this.$message.error(res.msg) |
|
|
|
} |
|
|
|
if (res.data.gridId) { |
|
|
|
this.isShowBnt = false |
|
|
|
} else { |
|
|
|
this.isShowBnt = true |
|
|
|
this.streetId = res.data.streetId ? res.data.streetId : '' |
|
|
|
this.communityId = res.data.communityId ? res.data.communityId : '' |
|
|
|
} |
|
|
|
}).catch(() => { }) |
|
|
|
}, |
|
|
|
goScreen () { |
|
|
|
let url = 'http://localhost:8091/#/home' |
|
|
|
let streetUrl = this.streetId ? `${url}?formPcStreetId=${this.streetId}` : url |
|
|
|
let communityUrl = this.communityId ? `${url}?formPcStreetId=${this.streetId}&formPcCommunityId=${this.communityId}` : url |
|
|
|
window.open(this.communityId ? communityUrl : streetUrl) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|