encode static method
Implementation
static Map<String, dynamic> encode(EncryptedInvoice value) {
Map<String, dynamic> entityAsMap = {
"id" : value.id,
"rev" : value.rev,
"created" : value.created,
"modified" : value.modified,
"author" : value.author,
"responsible" : value.responsible,
"medicalLocationId" : value.medicalLocationId,
"tags" : value.tags.map((x0) => CodeStub.encode(x0)).toList(),
"codes" : value.codes.map((x0) => CodeStub.encode(x0)).toList(),
"endOfLife" : value.endOfLife,
"deletionDate" : value.deletionDate,
"invoiceDate" : value.invoiceDate,
"sentDate" : value.sentDate,
"printedDate" : value.printedDate,
"invoicingCodes" : value.invoicingCodes.map((x0) => EncryptedInvoicingCode.encode(x0)).toList(),
"receipts" : value.receipts.map((k0, v0) => MapEntry(k0, v0)),
"recipientType" : value.recipientType,
"recipientId" : value.recipientId,
"invoiceReference" : value.invoiceReference,
"thirdPartyReference" : value.thirdPartyReference,
"thirdPartyPaymentJustification" : value.thirdPartyPaymentJustification,
"thirdPartyPaymentReason" : value.thirdPartyPaymentReason,
"reason" : value.reason,
"invoiceType" : value.invoiceType == null ? null : InvoiceType.encode(value.invoiceType!),
"sentMediumType" : value.sentMediumType == null ? null : MediumType.encode(value.sentMediumType!),
"interventionType" : value.interventionType == null ? null : InvoiceInterventionType.encode(value.interventionType!),
"groupId" : value.groupId,
"paymentType" : value.paymentType == null ? null : PaymentType.encode(value.paymentType!),
"paid" : value.paid,
"payments" : value.payments?.map((x0) => Payment.encode(x0)).toList(),
"gnotionNihii" : value.gnotionNihii,
"gnotionSsin" : value.gnotionSsin,
"gnotionLastName" : value.gnotionLastName,
"gnotionFirstName" : value.gnotionFirstName,
"gnotionCdHcParty" : value.gnotionCdHcParty,
"invoicePeriod" : value.invoicePeriod,
"careProviderType" : value.careProviderType,
"internshipNihii" : value.internshipNihii,
"internshipSsin" : value.internshipSsin,
"internshipLastName" : value.internshipLastName,
"internshipFirstName" : value.internshipFirstName,
"internshipCdHcParty" : value.internshipCdHcParty,
"internshipCbe" : value.internshipCbe,
"supervisorNihii" : value.supervisorNihii,
"supervisorSsin" : value.supervisorSsin,
"supervisorLastName" : value.supervisorLastName,
"supervisorFirstName" : value.supervisorFirstName,
"supervisorCdHcParty" : value.supervisorCdHcParty,
"supervisorCbe" : value.supervisorCbe,
"error" : value.error,
"encounterLocationName" : value.encounterLocationName,
"encounterLocationNihii" : value.encounterLocationNihii,
"encounterLocationNorm" : value.encounterLocationNorm,
"longDelayJustification" : value.longDelayJustification,
"correctiveInvoiceId" : value.correctiveInvoiceId,
"correctedInvoiceId" : value.correctedInvoiceId,
"creditNote" : value.creditNote,
"creditNoteRelatedInvoiceId" : value.creditNoteRelatedInvoiceId,
"idDocument" : value.idDocument == null ? null : IdentityDocumentReader.encode(value.idDocument!),
"admissionDate" : value.admissionDate,
"locationNihii" : value.locationNihii,
"locationService" : value.locationService,
"cancelReason" : value.cancelReason,
"cancelDate" : value.cancelDate,
"options" : value.options.map((k0, v0) => MapEntry(k0, v0)),
"secretForeignKeys" : value.secretForeignKeys.map((x0) => x0).toList(),
"cryptedForeignKeys" : value.cryptedForeignKeys.map((k0, v0) => MapEntry(k0, v0.map((x1) => Delegation.encode(x1)).toList())),
"delegations" : value.delegations.map((k0, v0) => MapEntry(k0, v0.map((x1) => Delegation.encode(x1)).toList())),
"encryptionKeys" : value.encryptionKeys.map((k0, v0) => MapEntry(k0, v0.map((x1) => Delegation.encode(x1)).toList())),
"encryptedSelf" : value.encryptedSelf,
"securityMetadata" : value.securityMetadata == null ? null : SecurityMetadata.encode(value.securityMetadata!)
};
return entityAsMap;
}