public async Task EditAsync(LeadSourceEditModel model) { var item = await _repository.GetAsync(model.Id); LeadSourceFactory.Create(model, item, _userId); _repository.Edit(item); await _unitOfWork.SaveChangesAsync(); }
public async Task AddAsync(LeadSourceAddModel model) { await _repository.AddAsync(LeadSourceFactory.Create(model, _userId)); await _unitOfWork.SaveChangesAsync(); }