feat: 档案详情列表生成二维码
This commit is contained in:
@@ -2,7 +2,8 @@
|
||||
<div>
|
||||
<ai-list class="app-archives-list">
|
||||
<template slot="title">
|
||||
<ai-title title="门店档案" isShowBottomBorder v-model="search.areaId" isShowArea :hideLevel="hideLevel - 1" @change="search.current = 1, getList()"></ai-title>
|
||||
<ai-title title="门店档案" isShowBottomBorder v-model="search.areaId" isShowArea :hideLevel="hideLevel - 1"
|
||||
@change="search.current = 1, getList()"></ai-title>
|
||||
</template>
|
||||
<template slot="content">
|
||||
<ai-search-bar class="search-bar">
|
||||
@@ -68,7 +69,8 @@
|
||||
@success="getList()">
|
||||
<el-button icon="iconfont iconImport">导入</el-button>
|
||||
</ai-import>
|
||||
<ai-download :instance="instance" url="/app/appintegraluser/girdIntegralExport" :params="search" fileName="门店档案"
|
||||
<ai-download :instance="instance" url="/app/appintegraluser/girdIntegralExport" :params="search"
|
||||
fileName="门店档案"
|
||||
:disabled="tableData.length == 0">
|
||||
</ai-download>
|
||||
</template>
|
||||
@@ -112,7 +114,9 @@
|
||||
<ai-dialog title="二维码"
|
||||
:visible.sync="dialog"
|
||||
:destroyOnClose="true"
|
||||
width="720px"></ai-dialog>
|
||||
width="720px">
|
||||
<img :src="qrSrc" class="qr-img" alt="">
|
||||
</ai-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -155,7 +159,8 @@ export default {
|
||||
],
|
||||
tableData: [],
|
||||
dateList: [],
|
||||
dialog:false
|
||||
dialog: false,
|
||||
qrSrc: ''
|
||||
}
|
||||
},
|
||||
|
||||
@@ -278,7 +283,20 @@ export default {
|
||||
})
|
||||
},
|
||||
|
||||
generateQr(row){
|
||||
async generateQr({id}) {
|
||||
try {
|
||||
const {code, data} = await this.instance.post('/app/appshoparchives/generateQrCode', null, {
|
||||
params: {
|
||||
id
|
||||
}
|
||||
})
|
||||
if (code === 0) {
|
||||
this.dialog = true
|
||||
this.qrSrc = data
|
||||
}
|
||||
} catch (e) {
|
||||
console.error(e)
|
||||
}
|
||||
this.dialog = true
|
||||
},
|
||||
|
||||
@@ -296,6 +314,9 @@ export default {
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.app-archives-list {
|
||||
|
||||
.qr-img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user