nfc提示优化
This commit is contained in:
parent
b08b6e182d
commit
04722a32b3
|
|
@ -23,7 +23,8 @@
|
||||||
<text class="nfc-status-title">{{ nfcStatusText }}</text>
|
<text class="nfc-status-title">{{ nfcStatusText }}</text>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="nfcError" class="nfc-error-text">
|
<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>
|
</view>
|
||||||
<view :class="{ ready: !!cardNo }" class="card-box">
|
<view :class="{ ready: !!cardNo }" class="card-box">
|
||||||
|
|
@ -136,7 +137,8 @@ export default {
|
||||||
return "设备不支持 NFC";
|
return "设备不支持 NFC";
|
||||||
}
|
}
|
||||||
if (this.nfcError) {
|
if (this.nfcError) {
|
||||||
return `NFC 错误: ${this.nfcError}`;
|
// return `NFC 错误: ${this.nfcError}`;
|
||||||
|
return ``;
|
||||||
}
|
}
|
||||||
return this.nfcEnabled ? "NFC 已开启,请将卡片贴近手机" : "NFC 未开启";
|
return this.nfcEnabled ? "NFC 已开启,请将卡片贴近手机" : "NFC 未开启";
|
||||||
},
|
},
|
||||||
|
|
@ -148,6 +150,9 @@ export default {
|
||||||
if (options.mac) {
|
if (options.mac) {
|
||||||
this.deviceMac = options.mac;
|
this.deviceMac = options.mac;
|
||||||
}
|
}
|
||||||
|
if (options.label) {
|
||||||
|
this.label = options.label;
|
||||||
|
}
|
||||||
this.initSocket();
|
this.initSocket();
|
||||||
this.initNFC();
|
this.initNFC();
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user