public async Task <SalesRecord> UpdateAsync(SalesRecord record, SalesRecordUpdateObject update) { _salesRecordRepository.Update(record, update); await _salesRecordRepository.CompleteAsync(); return(await _salesRecordRepository.GetByIdAsync(record.Id)); }
public void Update(SalesRecord record, SalesRecordUpdateObject update) { Context.SalesRecords.Attach(record); update.ApplyTo(record); }
public Task <SalesRecord> UpdateAsync(SalesRecord record, SalesRecordUpdateObject update) { update.ApplyTo(record); return(Task.FromResult(record)); }