public async Task <IResponseOutput> UpdateGroupAsync(PermissionUpdateGroupInput input) { if (!string.IsNullOrWhiteSpace(input?.Id)) { var entity = await _permissionRepo.FindByIdAsync(input.Id); entity = ObjectMapper.Map(input, entity); await _permissionRepo.UpdateAsync(entity); } return(ResponseOutput.Ok()); }
public async Task <IResponseOutput> UpdateGroupAsync(PermissionUpdateGroupInput input) { var result = false; if (input != null && input.Id > 0) { var entity = await _permissionRepository.GetAsync(input.Id); entity = _mapper.Map(input, entity); result = (await _permissionRepository.UpdateAsync(entity)) > 0; } return(ResponseOutput.Result(result)); }
public async Task <IResultModel> UpdateGroup(PermissionUpdateGroupInput input) { return(await _permissionServices.UpdateGroupAsync(input)); }