openweathermap search works now
This commit is contained in:
parent
33e64038fa
commit
8a8df6337a
@ -324,7 +324,7 @@ void DevicePluginOpenweathermap::searchResultsReady(const QList<QVariantMap> &ci
|
|||||||
{
|
{
|
||||||
QList<DeviceDescriptor> retList;
|
QList<DeviceDescriptor> retList;
|
||||||
foreach (QVariantMap elemant, cityList) {
|
foreach (QVariantMap elemant, cityList) {
|
||||||
DeviceDescriptor descriptor(deviceClassId,"city","searchresult");
|
DeviceDescriptor descriptor(deviceClassId, elemant.value("name").toString(),elemant.value("country").toString());
|
||||||
QVariantMap params;
|
QVariantMap params;
|
||||||
params.insert("location", elemant.value("name"));
|
params.insert("location", elemant.value("name"));
|
||||||
params.insert("country", elemant.value("country"));
|
params.insert("country", elemant.value("country"));
|
||||||
@ -332,7 +332,6 @@ void DevicePluginOpenweathermap::searchResultsReady(const QList<QVariantMap> &ci
|
|||||||
descriptor.setParams(params);
|
descriptor.setParams(params);
|
||||||
retList.append(descriptor);
|
retList.append(descriptor);
|
||||||
}
|
}
|
||||||
|
|
||||||
emit devicesDiscovered(deviceClassId,retList);
|
emit devicesDiscovered(deviceClassId,retList);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user