|
@@ -1,6 +1,6 @@
|
|
|
const app = getApp()
|
|
|
import dRequest from '../../../request/deviceListRequest'
|
|
|
-import routeUtil from '../../../utils/route_util'
|
|
|
+import route_util from '../../../utils/route_util'
|
|
|
import route_constant from '../../../utils/route_constant.js'
|
|
|
import strings from '../../../utils/strings.js';
|
|
|
import store from '../../../utils/store.js';
|
|
@@ -23,7 +23,9 @@ Page({
|
|
|
}
|
|
|
|
|
|
///数据请求
|
|
|
- dRequest.deviceList({ unShowLoad: true }).then((res) => {
|
|
|
+ dRequest.deviceList({
|
|
|
+ unShowLoad: true
|
|
|
+ }).then((res) => {
|
|
|
if (res) {
|
|
|
that.setDeviceList(res, true);
|
|
|
}
|
|
@@ -58,7 +60,7 @@ Page({
|
|
|
that.setData({
|
|
|
deviceList: devices
|
|
|
});
|
|
|
- } catch (e) { }
|
|
|
+ } catch (e) {}
|
|
|
},
|
|
|
|
|
|
deviceTap(e) {
|
|
@@ -71,17 +73,15 @@ Page({
|
|
|
|
|
|
var clientTypes = lexin_devices.clientTypes;
|
|
|
if (clientTypes.includes(device.clientType)) {
|
|
|
- var param = JSON.stringify(device);
|
|
|
- routeUtil.jumpParam(route_constant.deviceConnect0, param);
|
|
|
+ var param = '?param=' + JSON.stringify(device);
|
|
|
+ route_util.jumpParam(route_constant.deviceConnect0, param);
|
|
|
} else if (device.clientType === "MW-S2" || device.clientType === "猫王妙播黑胶音箱(BLE)") {
|
|
|
- let json = JSON.stringify(device)
|
|
|
- routeUtil.jumpParam(route_constant.connectBle, json)
|
|
|
+ var param = '?param=' + JSON.stringify(device);
|
|
|
+ route_util.jumpParam(route_constant.connectBle, param)
|
|
|
} else {
|
|
|
wx.showToast({
|
|
|
title: '暂不支持该设备',
|
|
|
})
|
|
|
}
|
|
|
-
|
|
|
},
|
|
|
-
|
|
|
})
|