<template>
    <view class="content"></view>
</template>

<script>
    import { wechatCode } from '@/apis/interfaces/authUrl'
    export default {
    	data() {
    		return {
                
    		}
    	},
        onLoad(options) {
            // 获取微信code
            wechatCode({
                code: options.code
            }).then(res => {
				this.$store.commit('setOpenId', res.openid)
				this.$Router.push({
					name: this.$Route.query.pageName
				})
			}).catch(err => {
            	uni.showToast({
            		title: err.message,
            		icon: "none"
            	})
            })
        },
    	onShow() {
    	    
    	},
    	methods: {}
    }
</script>

<style lang="scss" scoped>
</style>
