public async Task <IActionResult> GetUserSettings() { return(Ok(await _userSettingRepository.GetsByUserId(x => new { x.Key, x.Value }, CurrentUser.Id))); }
public async Task <AppSettingViewModel> GetAppSettings(string userId, string tenantId, string languageId) { var appSetting = new AppSettingViewModel(); var isSupperAdmin = await _userRoleRepository.CheckIsSupperAdmin(userId); appSetting.UserSettings = await _userSettingRepository.GetsByUserId(x => new UserSetting { Key = x.Key, Value = x.Value }, userId); appSetting.Permissions = await _rolePageRepository.GetsByUserId(userId); appSetting.Languages = await _tenantLanguageRepository.GetLanguageSupport(tenantId); appSetting.Pages = await _pageRepository.GetPagesByUserId(tenantId, userId, languageId); return(appSetting); }