nfc提示优化

This commit is contained in:
WindowBird 2025-11-25 09:12:04 +08:00
parent b08b6e182d
commit 04722a32b3

View File

@ -23,7 +23,8 @@
<text class="nfc-status-title">{{ nfcStatusText }}</text>
</view>
<view v-if="nfcError" class="nfc-error-text">
<text class="error-content">{{ nfcError }}</text>
<!-- <text class="error-content">{{ nfcError }}</text>-->
<text class="error-content">请打开NFC</text>
</view>
</view>
<view :class="{ ready: !!cardNo }" class="card-box">
@ -136,7 +137,8 @@ export default {
return "设备不支持 NFC";
}
if (this.nfcError) {
return `NFC 错误: ${this.nfcError}`;
// return `NFC : ${this.nfcError}`;
return ``;
}
return this.nfcEnabled ? "NFC 已开启,请将卡片贴近手机" : "NFC 未开启";
},
@ -148,6 +150,9 @@ export default {
if (options.mac) {
this.deviceMac = options.mac;
}
if (options.label) {
this.label = options.label;
}
this.initSocket();
this.initNFC();
},