Ejemplo n.º 1
0
 public void Save(IProperty property)
 {
     using (DatabaseContext context = CreateDatabaseContext())
     {
         PropertyRepository propertyRepository = new PropertyRepository(context);
         _addressDataProvider.Save(property.Address);
         VProperty vProperty = propertyRepository.Save(property);
         context.SaveChanges();
         property.PropertyId = vProperty.PropertyId;
     }
 }
        public VPropertyFile(VProperty property, IFile file)
        {
            if (file == null)
            {
                return;
            }

            PropertyId     = property.PropertyId.GetValueOrDefault(0);
            FileId         = file.FileId;
            FileName       = file.FileName;
            SystemFileName = file.SystemFileName;
            MimeType       = file.MimeType;
            Flags          = file.Flags;
            LastUpdated    = file.LastUpdated;
        }