示例#1
0
 public void Copy(Owner other, bool isShallow = true)
 {
     FullName = other.FullName;
     Telephone1 = other.Telephone1;
     Telephone2 = other.Telephone2;
     Address = other.Address;
     IsAgency = other.IsAgency;
     LandlordRegNumber = other.LandlordRegNumber;
     HasDepositAccount = other.HasDepositAccount;
     Properties = isShallow ? new Collection<Property>() : other.Properties;
 }
示例#2
0
 public static Property CreateTestProperty(Owner owner = null)
 {
     return new Property
     {
         Address = "2 Buckingham Palace, London, LE3 1AB",
         BedroomNo = 2,
         Description = "Test description",
         Price = 100.00,
         PropertyGuid = Guid.NewGuid().ToString("N"),
         Title = "Test Title",
         Owner = owner,
         PostDate = DateTime.Now,
         State = ObjectState.Added
     };
 }