|
using System;
using System.Collections.Generic;
using System.Linq;
namespace ECommerceSystem.Domain
{
public class Customer
{
public Customer()
{
CustomerPaidOrders = new List<PaymentApprovedOrder>();
}
public virtual long CustomerId { get; set; }
public virtual string CustomerName { get; set; }
public virtual Email EmailIdentity { get; set; }
public virtual IList<PaymentApprovedOrder> CustomerPaidOrders { get; set; }
public virtual void AddPaidOrder(PaymentApprovedOrder order)
{
//SET ONE end of the association
order.PaidByCustomer = this;
//SET MANY end of the association
CustomerPaidOrders.Add(order);
}
}
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.