public async Task AddUserScreenAccessAsync(List <ScreenAccessModel> model) { await _repository.DeleteAsyncUserScreenAccess(model[0].UserRoleId); await _unitOfWork.SaveChangesAsync(); List <UserScreenAccess> item = new List <UserScreenAccess>(); UserScreenAccessFactory.CreateUserScreenAccess(model, item); await _repository.AddUserScreenAccessAsync(item); await _unitOfWork.SaveChangesAsync(); }