From 901d81f1c56281bab87044d2ff562d8ed8601efa Mon Sep 17 00:00:00 2001 From: licp <lichunping@guanfang.com.cn> Date: 星期一, 11 三月 2024 09:25:17 +0800 Subject: [PATCH] 完成包装核对功能 --- src/views/common/qrCodeApp.vue | 17 ++++++++--------- 1 files changed, 8 insertions(+), 9 deletions(-) diff --git a/src/views/common/qrCodeApp.vue b/src/views/common/qrCodeApp.vue index 8c297ac..2e5ef67 100644 --- a/src/views/common/qrCodeApp.vue +++ b/src/views/common/qrCodeApp.vue @@ -27,7 +27,7 @@ data() { return { isShow: true, - camera: "front", + camera: "rear", result: "", // 鎵爜缁撴灉淇℃伅 error: "" // 閿欒淇℃伅 }; @@ -35,7 +35,7 @@ created() { }, methods: { openCamera(){ - this.camera="front" + this.camera='rear' }, //鍥炶皟鎵弿缁撴灉 onDecode(result) { @@ -48,14 +48,13 @@ // 鐩告満鍙嶈浆 switchCamera() { switch (this.camera) { - //鍓嶇疆 - case 'front': - //杞悗缃� - this.camera = 'rear' - break - //鍙嶄箣 + //鍙嶄箣 case 'rear': - this.camera = 'front' + this.camera = 'front' + break + case 'front': + //鍚庣疆 + this.camera = 'rear' break default: this.$toast('閿欒') -- Gitblit v1.9.3