Commit 7ea18f29 by 李伟康

commit

1 parent 4f096331
......@@ -165,7 +165,7 @@
</template>
<div
class="scan flex"
v-if="type != 1"
v-if="type != 1 && showScan"
@click="scan"
>
<div class="sprite-icon icon-scan"></div>
......@@ -196,6 +196,20 @@ const itemObj = [
key: 'verificationOperator'
}
]
const itemObj2 = [
{
label: '券名',
key: 'couponName'
},
{
label: '发放人',
key: 'employeeName'
},
{
label: '核销人',
key: 'sellerName'
}
]
export default {
name: '',
data () {
......@@ -216,20 +230,8 @@ export default {
itemObj,
total: 0,
userName: '',
itemObj2: [
{
label: '券名',
key: 'couponName'
},
{
label: '发放人',
key: 'employeeName'
},
{
label: '核销人',
key: 'sellerName'
}
]
itemObj2,
showScan: false
}
},
beforeRouteEnter (to, from, next) {
......@@ -262,8 +264,9 @@ export default {
},
mounted () {
this.getTabNum()
window.$wx = wxConfig
window.$wx.init(['scanQRCode'])
wxConfig.init(['scanQRCode']).then(() => {
this.showScan = true
})
},
methods: {
/**获取列表数量 */
......@@ -422,7 +425,7 @@ export default {
},
scan () {
// let resultStr = 't=2&c=3483845737948516352'
window.$wx.scanQRCode(1).then(({ resultStr }) => {
wxConfig.scanQRCode(1).then(({ resultStr }) => {
let name = 'verificationDetail'
let [t, c] = resultStr.split('&')
let type = t.split('=')[1]
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!