Commit e204645e by 姜雷

Merge branch 'develop' into test

parents 37e50b9c 33942358
...@@ -730,7 +730,15 @@ class Shower extends Component { ...@@ -730,7 +730,15 @@ class Shower extends Component {
.then(res => { .then(res => {
const deviceId = res.deviceId; const deviceId = res.deviceId;
const services = res.services; const services = res.services;
let service = services[services.length - 1]; let service = services.find(
item =>
item.uuid.toLocaleLowerCase() ===
'6e401103-b5a3-f393-e0a9-e50e24dcca9e',
);
if (!service) {
service = services[0];
}
console.log('获取全部services: ', services, '. serviceId: ', service);
const serviceId = service.uuid; const serviceId = service.uuid;
this.setState(({ deviceInfo }: PageState) => ({ this.setState(({ deviceInfo }: PageState) => ({
deviceInfo: { deviceInfo: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment