index.vue 2.24 KB
Newer Older
zhangpeng committed
1
<template>
zhangpeng committed
2 3
	<view class="content">
	</view>
zhangpeng committed
4 5 6
</template>

<script>
张成 committed
7 8 9 10 11 12 13 14 15 16 17
import config from '../../static/config/index.js'
import Order from '../../request/order/index'
import User from '@/request/user'
import Menu from '@/request/menu'
export default {
	data() {
		return {
			id: ''
		}
	},
	onLoad(options) {
张成 committed
18 19 20 21 22 23 24 25
					uni.reLaunch({url: '/pages/menu/menu'})
		// this.id = '';
		// this.$store.commit('setOrderId', '');
		// if (options.q) {
		// 	let url = decodeURIComponent(options.q);
		// 	this.id = url.split('/')[url.split('/').length - 1];
		// 	this.$store.commit('setOrderId', this.id);
		// }
26
		//    this.id=1;
张成 committed
27
	},
张成 committed
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66
	// async onShow() {
	// 	//  let routes = getCurrentPages(); // 获取当前打开过的页面路由数组
	// 	// let curRoute = routes[routes.length - 1].route //获取当前页面路由
	// 	//   let curParam = routes[routes.length - 1].options;
	// 	let Authorization = uni.getStorageSync(`Authorization`);
	// 	let userPhoneInfo = uni.getStorageSync(`userPhoneInfo`);
	// 	if (Authorization && userPhoneInfo) {
	// 		this.$store.commit('setUserPhoneInfo', userPhoneInfo);
	// 		this.$store.commit('setAuthorization', Authorization);
	// 		if (this.id != '') {
	// 			uni.navigateTo({
	// 				url: `/menuSubPackage/pages/settlement/settlement?orderId=${this.id}&buyType=3`
	// 			})
	// 		} else {
	// 			uni.reLaunch({
	// 				url: '/pages/menu/menu'
	// 			})
	// 		}
	// 	} else {
	// 		uni.removeStorageSync('Authorization');
	// 		uni.removeStorageSync('userPhoneInfo');
	// 		if (this.id != '') {
	// 			let _this = this;
	// 			uni.showToast({
	// 				title: '请授权登录',
	// 				icon: 'error',
	// 				success() {
	// 					setTimeout(() => {
	// 						uni.reLaunch({
	// 							url: '/pages/menu/menu?orderId=' + _this.id
	// 						})
	// 					}, 1500)
	// 				}
	// 			})
	// 		} else {
	// 			uni.reLaunch({
	// 				url: '/pages/menu/menu'
	// 			})
	// 		}
张成 committed
67 68


张成 committed
69 70
	// 	}
	// },
张成 committed
71
	methods: {
zhangpeng committed
72
	}
张成 committed
73
}
zhangpeng committed
74 75 76
</script>

<style>
张成 committed
77 78 79 80 81 82
.content {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}
zhangpeng committed
83

张成 committed
84 85 86 87 88 89 90 91
.logo {
	height: 200rpx;
	width: 200rpx;
	margin-top: 200rpx;
	margin-left: auto;
	margin-right: auto;
	margin-bottom: 50rpx;
}
zhangpeng committed
92

张成 committed
93 94 95 96
.text-area {
	display: flex;
	justify-content: center;
}
zhangpeng committed
97

张成 committed
98 99 100 101
.title {
	font-size: 36rpx;
	color: #8f8f94;
}
zhangpeng committed
102
</style>