toJson method
Implementation
Map<String, dynamic> toJson() {
if (type == DropdownSourceTypes.static) {
return (this as StaticDropdownSource).toJson();
} else if (type == DropdownSourceTypes.dynamic) {
return (this as DynamicDropdownSource).toJson();
}
throw Exception('Unknown dropdown source type');
}