<template>
	<view></view>
</template>
<script setup>
	import {onLoad,onShow,onReady} from'@dcloudio/uni-app'
	import {home} from "../../stor/home/home.js"
	import {ref} from "vue"
	const  homes = home()
	const nums = ref(0)
	let qrCodeScanned = false
	let timer
	onShow(()=>{
		if (!qrCodeScanned) {
			homes.scanQrcode()
			qrCodeScanned = true
			timer = setTimeout(() => {
				qrCodeScanned = false
			}, 10000)
		}
	})
	onLoad(()=>{
		if (!qrCodeScanned) {
			homes.scanQrcode()
			qrCodeScanned = true
			timer = setTimeout(() => {
				qrCodeScanned = false
			}, 10000)
		}
	})
	// onReady(()=>{
	// })
</script>
<style lang="scss"></style>