You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
51 lines
1.6 KiB
Dart
51 lines
1.6 KiB
Dart
4 years ago
|
import 'package:diplomaticquarterapp/core/model/geofencing/responses/GeoZonesResponseModel.dart';
|
||
|
|
||
|
geoZonesResponseModelEntityFromJson(GeoZonesResponseModel data, Map<String, dynamic> json) {
|
||
|
if (json['GEOF_ID'] != null) {
|
||
|
data.geofId = json['GEOF_ID']?.toInt();
|
||
|
}
|
||
|
if (json['Description'] != null) {
|
||
|
data.description = json['Description']?.toString();
|
||
|
}
|
||
|
if (json['DescriptionN'] != null) {
|
||
|
data.descriptionN = json['DescriptionN']?.toString();
|
||
|
}
|
||
|
if (json['Latitude'] != null) {
|
||
|
data.latitude = json['Latitude']?.toString();
|
||
|
}
|
||
|
if (json['Longitude'] != null) {
|
||
|
data.longitude = json['Longitude']?.toString();
|
||
|
}
|
||
|
if (json['Radius'] != null) {
|
||
|
data.radius = json['Radius']?.toInt();
|
||
|
}
|
||
|
if (json['Type'] != null) {
|
||
|
data.type = json['Type']?.toInt();
|
||
|
}
|
||
|
if (json['ProjectID'] != null) {
|
||
|
data.projectID = json['ProjectID']?.toInt();
|
||
|
}
|
||
|
if (json['ImageURL'] != null) {
|
||
|
data.imageURL = json['ImageURL']?.toString();
|
||
|
}
|
||
|
if (json['IsCity'] != null) {
|
||
|
data.isCity = json['IsCity'];
|
||
|
}
|
||
|
return data;
|
||
|
}
|
||
|
|
||
|
Map<String, dynamic> geoZonesResponseModelEntityToJson(GeoZonesResponseModel entity) {
|
||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||
|
data['GEOF_ID'] = entity.geofId;
|
||
|
data['Description'] = entity.description;
|
||
|
data['DescriptionN'] = entity.descriptionN;
|
||
|
data['Latitude'] = entity.latitude;
|
||
|
data['Longitude'] = entity.longitude;
|
||
|
data['Radius'] = entity.radius;
|
||
|
data['Type'] = entity.type;
|
||
|
data['ProjectID'] = entity.projectID;
|
||
|
data['ImageURL'] = entity.imageURL;
|
||
|
data['IsCity'] = entity.isCity;
|
||
|
return data;
|
||
|
}
|