public async Task <Guid> Upsert(PowerSuply model) { model.Brand = _appContext.Brands.Find(model.Brand.Id); model.Certificate = _appContext.Certificates.Find(model.Certificate.Id); _appContext.PowerSuplies.Update(model); await _appContext.SaveChangesAsync(); return(model.Id.Value); }
public Task <Guid> Upsert(PowerSuply model) { return(_powerSuplyRepository.Upsert(model)); }