Skip to content

Instantly share code, notes, and snippets.

@bjoerntx
Created November 23, 2023 13:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bjoerntx/991b33e8a35cd6f8f6009a18f30b1446 to your computer and use it in GitHub Desktop.
Save bjoerntx/991b33e8a35cd6f8f6009a18f30b1446 to your computer and use it in GitHub Desktop.
public static string GetDummyInvoiceData()
{
Invoice invoice = new Invoice
{
InvoiceID = "123456789",
InvoiceNumber = "123456789",
InvoiceDate = "2020-01-01",
Customer = new Customer
{
CustomerID = "123456789",
Name = "John Doe",
Email = ""
},
LineItems = new List<LineItem>
{
new LineItem
{
LineItemID = "123456789",
Description = "Item 1",
Quantity = "1",
Price = "100.00",
Tax = "10.00",
Total = "110.00"
},
new LineItem
{
LineItemID = "123456789",
Description = "Item 2",
Quantity = "1",
Price = "100.00",
Tax = "10.00",
Total = "110.00"
},
new LineItem
{
LineItemID = "123456789",
Description = "Item 3",
Quantity = "1",
Price = "100.00",
Tax = "10.00",
Total = "110.00"
}
}
};
List<Invoice> invoices = new List<Invoice>();
invoices.Add(invoice);
return JsonConvert.SerializeObject(invoices);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment