DecryptedInvoice.fromJSON constructor

DecryptedInvoice.fromJSON(
  1. Map<String, dynamic> data
)

Implementation

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