Exemple #1
0
        public async Task <Flat> AddAsync(Flat newEntity)
        {
            _context.Flat.Attach(newEntity); // Do we need this?
            _context.ApplyStateChanges();
            await _context.SaveChangesAsync();

            return(newEntity);
        }
        public async Task <Society> AddAsync(Society newEntity)
        {
            _context.Society.Attach(newEntity); // Do we need this?
            _context.ApplyStateChanges();
            await _context.SaveChangesAsync();

            return(newEntity);
        }
Exemple #3
0
        public async Task <Building> AddAsync(Building newEntity)
        {
            _context.Building.Attach(newEntity); // Do we need this?
            _context.ApplyStateChanges();
            await _context.SaveChangesAsync();

            return(newEntity);
        }