第一版
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
const app = getApp();
|
||||
|
||||
Page({
|
||||
data: {
|
||||
wifiList: []
|
||||
},
|
||||
|
||||
onLoad() {
|
||||
this.initWifi();
|
||||
},
|
||||
|
||||
initWifi() {
|
||||
wx.showLoading({
|
||||
title: "正在获取Wi-Fi列表...",
|
||||
mask: true
|
||||
});
|
||||
app.globalData.ppScale.activeProtocol.dataFindSurroundDevice((res) => {
|
||||
wx.hideLoading();
|
||||
console.log("wifiList", res);
|
||||
this.setData({
|
||||
wifiList: res
|
||||
})
|
||||
})
|
||||
},
|
||||
|
||||
openSetWifiPassword(e) {
|
||||
let item = JSON.stringify(e.currentTarget.dataset.item);
|
||||
wx.navigateTo({
|
||||
url: "/pages/setWifiPassword/setWifiPassword?item=" + item
|
||||
})
|
||||
}
|
||||
})
|
||||
Reference in New Issue
Block a user