二维码

This commit is contained in:
bb_pan 2025-08-26 18:30:39 +08:00
parent 63f9f062f7
commit b278a776c6
2 changed files with 6 additions and 4 deletions

View File

@ -153,7 +153,7 @@
<!-- 二维码下载对话框 -->
<el-dialog title="二维码" :visible.sync="uploadOpen" width="450px" append-to-body :close-on-click-modal="false">
<div style="text-align: center" ref="codeBox">
<div style="text-align: center" ref="codeBox" v-if="uploadOpen">
<div class="uploadImg">
<div id="qrcode" class="qrcode" ref="codeItem"></div>
</div>

View File

@ -364,7 +364,7 @@
<!-- 二维码下载对话框 -->
<el-dialog title="二维码查看" :visible.sync="uploadOpen" width="450px" append-to-body :close-on-click-modal="false">
<div style="text-align: center" ref="codeQr">
<div style="text-align: center" ref="codeQr" v-if="uploadOpen">
<div class="uploadImg">
<div id="qrcode" class="qrcode" ref="codeItem"></div>
</div>
@ -819,10 +819,12 @@ export default {
//
handleViewQrCode(row) {
console.log('🚀 ~ handleViewQrCode ~ row:', row)
this.rowObj = row
this.uploadOpen = true
this.qrCode = row.qrCode
let str = row.qrCode
let str = 'http://ahjj.jypxks.com:9988/imw/backstage/machine/qrCodePage?qrcode=' + row.qrCode
console.log('🚀 ~ handleViewQrCode ~ str:', str)
this.$nextTick(() => {
this.$refs.codeItem.innerHTML = ''
var qrcode = new QRCode(this.$refs.codeItem, {
@ -855,7 +857,7 @@ export default {
// 使 qrcodejs2
new QRCode(qrcodeContainer, {
text: row.qrCode,
text: 'http://ahjj.jypxks.com:9988/imw/backstage/machine/qrCodePage?qrcode=' + row.qrCode,
width: 256,
height: 256,
colorDark: '#000000',