Merged with SP-203

This commit is contained in:
Abdullah Alassaf
2024-07-25 14:15:06 +03:00
46 changed files with 1973 additions and 811 deletions

View File

@ -17,12 +17,13 @@ class DeviceModel {
String? timeZone;
int? updateTime;
String? uuid;
String? productUuid;
DeviceType? productType;
bool isSelected = false;
late List<FunctionModel> functions;
DeviceModel(
{this.activeTime,
// this.id,
this.productUuid,
this.localKey,
this.model,
this.name,
@ -61,27 +62,26 @@ class DeviceModel {
tempIcon = Assets.assetsIconsLogo;
}
return DeviceModel(
icon: tempIcon,
activeTime: json['activeTime'],
// id: json['id'],
localKey: json['localKey'],
model: json['model'],
name: json['name'],
isOnline: json['online'],
productName: json['productName'],
timeZone: json['timeZone'],
updateTime: json['updateTime'],
uuid: json['uuid'],
productType: type,
type: json['productType'],
status: [],
);
icon: tempIcon,
activeTime: json['activeTime'],
// id: json['id'],
localKey: json['localKey'],
model: json['model'],
name: json['name'],
isOnline: json['online'],
productName: json['productName'],
timeZone: json['timeZone'],
updateTime: json['updateTime'],
uuid: json['uuid'],
productType: type,
type: json['productType'],
status: [],
productUuid: json['productUuid']);
}
Map<String, dynamic> toJson() {
return {
'activeTime': activeTime,
// 'id': id,
'localKey': localKey,
'model': model,
'name': name,