|
@@ -1,6 +1,6 @@
|
|
|
<template>
|
|
|
<div class="sweep" v-if="show">
|
|
|
- <video ref="video" id="reader" style="width:100%;height:auto;"></video>
|
|
|
+ <video ref="video" playsinline id="reader" style="width:100%;height:auto;"></video>
|
|
|
<div class="ku-scanner">
|
|
|
<div class="ku-scanner-content">
|
|
|
<div class="ku-scanner-tooltip">
|
|
@@ -73,9 +73,8 @@ export default {
|
|
|
this.scanner = new QrScanner(
|
|
|
this.$refs.video,
|
|
|
result => {
|
|
|
- if (result) {
|
|
|
- this.$toast(result)
|
|
|
- this.$emit('success', result)
|
|
|
+ if (result.data) {
|
|
|
+ this.$emit('success', result.data)
|
|
|
}
|
|
|
|
|
|
// this.scanner.stop() // 扫描一次后停止
|