You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

43 lines
616 B

3 years ago
<template>
<view>
<tabbar :page="page"></tabbar>
3 years ago
</view>
</template>
<script>
import tabbar from "@/components/tabbar/tabbar.vue";
3 years ago
export default {
3 years ago
data() {
return {
page: ""
3 years ago
};
},
onReady() {
this.QR();
},
onShow() {
this.page= "scan"
},
methods: {
QR() {
uni.scanCode({
onlyFromCamera: true,
success: (res) => {
console.log('扫描二维码成功,结果:' + res.result);
},
error: (res) => {
console.log('扫描二维码出现错误')
}
})
},
},
components: {
tabbar
}
3 years ago
}
</script>
<style lang="scss">
</style>