fromMap static method
Implementation
static PurchasePaymentNote? fromMap(Object? body) {
final source = readRecord(body);
if (source == null) return null;
return PurchasePaymentNote(
attachments: readList<PurchasePaymentNoteAttachment>(
source['attachments'], PurchasePaymentNoteAttachment.fromMap),
content: readText(source['content']),
createdBy: PurchasePaymentNoteCreatedBy.fromMap(source['created_by']),
createdOn: readText(source['created_on']),
group: readAny(source['group']),
href: readText(source['href']),
id: readText(source['id']),
lastUpdatedBy: readAny(source['last_updated_by']),
lastUpdatedOn: readAny(source['last_updated_on']),
object: readText(source['object']),
purchasePayment: PurchasePaymentNotePurchasePayment.fromMap(
source['purchase_payment']),
user: readAny(source['user']),
version: readInteger(source['version']),
watchers: readList<PurchasePaymentNoteWatcher>(
source['watchers'], PurchasePaymentNoteWatcher.fromMap),
);
}