toJson method
Serializes the model to JSON.
Returns:
- A map representing the model in JSON format.
Implementation
@override
Map<String, dynamic> toJson() {
Map<String, dynamic> json = {};
if (equal != null) {
json[FilterField.equal] = equal;
}
if (notEqual != null) {
json[FilterField.notEqual] = notEqual;
}
if (inList != null) {
json[FilterField.inList] = inList;
}
if (notInList != null) {
json[FilterField.notInList] = notInList;
}
return json;
}