1 | using System;
|
---|
2 | using System.Collections.Generic;
|
---|
3 |
|
---|
4 | namespace HeuristicLab.Services.Optimization.Billing.Model {
|
---|
5 | public class ContactInformation {
|
---|
6 | public long ContactInformationId { get; set; }
|
---|
7 | public string OrganizationName { get; set; }
|
---|
8 | public string Street { get; set; }
|
---|
9 | public string City { get; set; }
|
---|
10 | public string State { get; set; }
|
---|
11 | public string PostalCode { get; set; }
|
---|
12 | public string LastName { get; set; }
|
---|
13 | public string FirstName { get; set; }
|
---|
14 | public string Email { get; set; }
|
---|
15 | }
|
---|
16 |
|
---|
17 | public enum PaymentMethod {
|
---|
18 | Cheque,
|
---|
19 | Visa,
|
---|
20 | MasterCard,
|
---|
21 | PayPal,
|
---|
22 | Diners
|
---|
23 | }
|
---|
24 |
|
---|
25 | public class Product {
|
---|
26 | public long ProductId { get; set; }
|
---|
27 | public string Name { get; set; }
|
---|
28 | public string Description { get; set; }
|
---|
29 | public string ProductType { get; set; }
|
---|
30 | public double Price { get; set; }
|
---|
31 | }
|
---|
32 |
|
---|
33 | public class User {
|
---|
34 | public long UserId { get; set; }
|
---|
35 | public string Name { get; set; }
|
---|
36 | }
|
---|
37 |
|
---|
38 | public enum OrderState {
|
---|
39 | Created,
|
---|
40 | Active,
|
---|
41 | Suspended,
|
---|
42 | Overdue,
|
---|
43 | Finished
|
---|
44 | }
|
---|
45 |
|
---|
46 | public class Order {
|
---|
47 | public long OrderId { get; set; }
|
---|
48 | public long UserId { get; set; }
|
---|
49 | public string BillingType { get; set; }
|
---|
50 | public long OrderStateId { get; set; }
|
---|
51 | public string BillingPeriod { get; set; }
|
---|
52 | public DateTime ActiveSince { get; set; }
|
---|
53 | public DateTime ActiveUntil { get; set; }
|
---|
54 |
|
---|
55 |
|
---|
56 | public virtual User User { get; set; }
|
---|
57 | public virtual OrderState State { get; set; }
|
---|
58 | public virtual IList<Invoice> Invoices { get; set; }
|
---|
59 | public virtual IList<OrderLine> OrderLines { get; set; }
|
---|
60 | }
|
---|
61 |
|
---|
62 | public class OrderLine {
|
---|
63 | public long OrderLineId { get; set; }
|
---|
64 | public long OrderId { get; set; }
|
---|
65 | public long ProductId { get; set; }
|
---|
66 | public int Quantity { get; set; }
|
---|
67 | public double ProductPrice { get; set; }
|
---|
68 |
|
---|
69 | public virtual Order Order { get; set; }
|
---|
70 | public virtual Product Product { get; set; }
|
---|
71 | }
|
---|
72 |
|
---|
73 | public class Invoice {
|
---|
74 | public long InvoiceId { get; set; }
|
---|
75 | public long UserId { get; set; }
|
---|
76 | public long OrderId { get; set; }
|
---|
77 | public DateTime Due { get; set; }
|
---|
78 | public string Status { get; set; }
|
---|
79 | public string InvoiceDocument { get; set; }
|
---|
80 |
|
---|
81 | public virtual User User { get; set; }
|
---|
82 | public virtual Order Order { get; set; }
|
---|
83 | }
|
---|
84 |
|
---|
85 | public class InvoiceLine {
|
---|
86 | public long InvoiceLineId { get; set; }
|
---|
87 | public long InvoiceId { get; set; }
|
---|
88 | public long ProductId { get; set; }
|
---|
89 | public int Quantity { get; set; }
|
---|
90 | public double ProductPrice { get; set; }
|
---|
91 |
|
---|
92 | public virtual Invoice Invoice { get; set; }
|
---|
93 | public virtual Product Product { get; set; }
|
---|
94 | }
|
---|
95 |
|
---|
96 | public class UsageRecord {
|
---|
97 | public long UsageRecordId { get; set; }
|
---|
98 | public long UserId { get; set; }
|
---|
99 |
|
---|
100 | public virtual User User { get; set; }
|
---|
101 | public virtual IList<UsageRecordLine> UsageRecordLines { get; set; }
|
---|
102 | }
|
---|
103 |
|
---|
104 | public class UsageRecordLine {
|
---|
105 | public long UsageRecordLineId { get; set; }
|
---|
106 | public long UsageRecordId { get; set; }
|
---|
107 | public DateTime Begin { get; set; }
|
---|
108 | public DateTime End { get; set; }
|
---|
109 |
|
---|
110 | public virtual UsageRecord UsageRecord { get; set; }
|
---|
111 | }
|
---|
112 | }
|
---|