<template>
	<ciy-header title="您的小程序码"></ciy-header>
	<view v-if="init.code != 1" class="px4 py4">
		<view style="height:90vw;width:100%;" class="ciy-skeleton"></view>
	</view>
	<view v-else>
		<view style="padding:1em;">
			<image show-menu-by-longpress :src="file_stor(init.qrcode)" mode="widthFix" style="width: 100%;"></image>
		</view>
	</view>
</template>

<style>
</style>

<script>
	export default {
		data() {
			return {
			}
		},
		onLoad() {
			this.getinit();
		},
		methods: {
			async getinit() {
				var retjson = await this.callajax({
					func: 'me.getqrcode',
					data: {}
				});
				if (retjson.code != 1)
					return this.alert(retjson.errmsg);
				this.init = retjson;
			}
		}
	}
</script>