toJson method
Implementation
Map<String, dynamic> toJson() {
final json = <String, dynamic>{};
if (this.id != null) {
json[r'id'] = this.id;
} else {
json[r'id'] = null;
}
if (this.type != null) {
json[r'type'] = this.type;
} else {
json[r'type'] = null;
}
if (this.source_ != null) {
json[r'source'] = this.source_;
} else {
json[r'source'] = null;
}
if (this.amount != null) {
json[r'amount'] = this.amount;
} else {
json[r'amount'] = null;
}
if (this.currency != null) {
json[r'currency'] = this.currency;
} else {
json[r'currency'] = null;
}
if (this.description != null) {
json[r'description'] = this.description;
} else {
json[r'description'] = null;
}
if (this.originalAmount != null) {
json[r'originalAmount'] = this.originalAmount;
} else {
json[r'originalAmount'] = null;
}
if (this.originalCurrency != null) {
json[r'originalCurrency'] = this.originalCurrency;
} else {
json[r'originalCurrency'] = null;
}
if (this.conversionRate != null) {
json[r'conversionRate'] = this.conversionRate;
} else {
json[r'conversionRate'] = null;
}
if (this.date != null) {
json[r'date'] = this.date!.toUtc().toIso8601String();
} else {
json[r'date'] = null;
}
return json;
}