App.vue 1.02 KB
<script>
	import store from '@/store';

	export default {
		//设置全局变量,解绑时从这里取
		globalData: {
			openId: ''
		},
		onLaunch(e) {
			// #ifdef APP-PLUS
			uni.reLaunch({
				url: '/pages/index/splash'
			})
			// #endif
		},
		onUnload(){
			uni.setStorageSync('getConfiguration', {
				isConfiguration: false
			});
		},
		methods:{
			// 判断是否是第三方登录没有绑定账号不请求数据
			getBindNot(){
				// #ifndef H5
				const userInfo = uni.getStorageSync('userInfo');
				// #endif
				// #ifdef H5
				const userInfo = JSON.parse(sessionStorage.getItem('userInfo') || localStorage.getItem('userInfo'));
				// #endif
				return userInfo.isThirdLogin
			}
		}
	};
</script>

<style lang="scss">
	@import '@/uni_modules/uview-ui/index.scss';
	@import './style/iconfont.scss';
	@import './style/common.scss';

	page {
		background: #ffffff;
	}

	::-webkit-scrollbar {
		display: none;
		width: 0 !important;
		height: 0 !important;
		-webkit-appearance: none;
		background: transparent;
	}
</style>