private Contact ParseContact(dataPackDataPackItem i) { var customer = MatchContact(i.invoice.invoiceHeader.partnerIdentity.address); customer = MergeContact(i.invoice.invoiceHeader.partnerIdentity.address, customer); return(customer); }
private IssuedInvoiceBase ParseInvoice(dataPackDataPackItem i, Contact contact) { var invoice = MatchInvoice(i.invoice.invoiceHeader.number.numberRequested.ToString()); if (invoice != null) { return(MergeInvoice(i.invoice, invoice)); } else { return(CreateInvoice(i.invoice, contact.Id)); } }