|
@@ -32,7 +32,7 @@ Page({
|
|
let wifiName = wifiDic.wifiName
|
|
let wifiName = wifiDic.wifiName
|
|
let pwd = wifiDic.wifiPassword
|
|
let pwd = wifiDic.wifiPassword
|
|
// if (wifiName && pwd) {
|
|
// if (wifiName && pwd) {
|
|
- if (wifiName) {
|
|
|
|
|
|
+ if (wifiName) {
|
|
console.log("获取Wi-Fi信息", wifiName, pwd);
|
|
console.log("获取Wi-Fi信息", wifiName, pwd);
|
|
that.setData({
|
|
that.setData({
|
|
wifiName: wifiName,
|
|
wifiName: wifiName,
|
|
@@ -96,6 +96,22 @@ Page({
|
|
wifiPassword: e.detail.value
|
|
wifiPassword: e.detail.value
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ onFocus(event) {
|
|
|
|
+ console.log("onFocus:", event)
|
|
|
|
+ if (event.detail.value !== this.data.pwdData) {
|
|
|
|
+ this.setData({
|
|
|
|
+ wifiPassword: event.detail.value
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ onBlur(event) {
|
|
|
|
+ console.log("onBlur", event)
|
|
|
|
+ if (event.detail.value !== this.data.pwdData) {
|
|
|
|
+ this.setData({
|
|
|
|
+ wifiPassword: event.detail.value
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
|
|
togglePasswordVisibility: function () {
|
|
togglePasswordVisibility: function () {
|
|
const passwordType = !this.data.passwordType;
|
|
const passwordType = !this.data.passwordType;
|