You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

106 lines
2.2 KiB

<template>
5 years ago
<a-config-provider :locale="zh_CN">
<div id="app">
<head-nav class="head-nav" />
<router-view></router-view>
<friend-ship class="friend" />
<footer-page class="footer" />
<div id="components-back-top-demo-custom">
<a-back-top>
5 years ago
<div class="ant-back-top-inner"></div>
5 years ago
</a-back-top>
</div>
</div>
</a-config-provider>
</template>
<script>
5 years ago
import { mapState, mapActions, mapMutations } from 'vuex';
import zh_CN from 'ant-design-vue/lib/locale-provider/zh_CN';
import HeadNav from './components/HeadNav/HeadNav.vue';
import FooterPage from './components/FooterPage/FooterPage.vue';
import FriendShip from './components/FooterPage/FriendShip.vue';
export default {
5 years ago
name: 'App',
components: { HeadNav, FooterPage, FriendShip },
data() {
return { zh_CN };
},
5 years ago
computed: mapState('user', ['anyringToken']),
5 years ago
updated() {
window.scroll(0, 0);
},
created() {
console.log('process.env ', process.env);
const userId = '1218763410024566784';
const params = { userId };
this.getUserId(params);
if (sessionStorage.getItem('store')) {
this.$store.replaceState(Object.assign({}, this.$store.state, JSON.parse(sessionStorage.getItem('store'))));
}
5 years ago
window.addEventListener('beforeunload', () => {
sessionStorage.setItem('store', JSON.stringify(this.$store.state));
});
},
5 years ago
methods: { ...mapActions('user', ['getUserId']) },
5 years ago
};
</script>
<style>
5 years ago
html,
body,
#app {
min-height: 100%;
}
#app {
background: transparent;
}
body {
5 years ago
background: #f5f5f5 !important;
padding-top: 80px;
}
body::-webkit-scrollbar {
width: 0;
}
.head-nav {
height: 80px;
width: 100%;
top: 0;
background: white;
box-shadow: 0 0 10px #ccc;
position: fixed !important;
z-index: 100;
}
.friend {
height: 64px;
}
.footer {
width: 100%;
background: #0d1f32;
bottom: 0;
}
#components-back-top-demo-custom .ant-back-top {
bottom: 100px;
right: 180px;
}
#components-back-top-demo-custom .ant-back-top-inner {
height: 40px;
5 years ago
width: 40px;
5 years ago
line-height: 40px;
5 years ago
background: url('assets/t-top.png') center no-repeat;
background-size: contain;
}
.BMap_cpyCtrl {
display: none;
}
.anchorBL {
display: none;
}
</style>