diff --git a/SurveyBackend/SurveyBackend.API/Controllers/AuthController.cs b/SurveyBackend/SurveyBackend.API/Controllers/AuthController.cs
index e516621..5eb80ad 100644
--- a/SurveyBackend/SurveyBackend.API/Controllers/AuthController.cs
+++ b/SurveyBackend/SurveyBackend.API/Controllers/AuthController.cs
@@ -67,6 +67,11 @@ public class AuthController : ControllerBase
return Ok(new { token = token });
}
+ ///
+ /// Получить информацию о нынешнем юзере
+ ///
+ /// Возвращает инфо о пользователе, токен которого был использован
+ ///
[Authorize]
[HttpGet("me")]
[ProducesResponseType(StatusCodes.Status401Unauthorized)]
diff --git a/SurveyBackend/SurveyBackend.API/Controllers/QuestionController.cs b/SurveyBackend/SurveyBackend.API/Controllers/QuestionController.cs
index 41f6ac8..ee94aab 100644
--- a/SurveyBackend/SurveyBackend.API/Controllers/QuestionController.cs
+++ b/SurveyBackend/SurveyBackend.API/Controllers/QuestionController.cs
@@ -56,6 +56,13 @@ public class QuestionController : ControllerBase
return Ok(result);
}
+ ///
+ /// Обновляет вопрос целиком
+ ///
+ ///
+ ///
+ ///
+ ///
[Authorize]
[HttpPut("{id}")]
public async Task UpdateQuestion([FromBody] QuestionUpdateDto dto, [FromRoute] int id,
@@ -67,6 +74,12 @@ public class QuestionController : ControllerBase
return Ok(result);
}
+ ///
+ /// Удаляет вопрос по его ID
+ ///
+ ///
+ ///
+ ///
[Authorize]
[HttpDelete("{id}")]
public async Task DeleteQuestion([FromRoute] int id, [FromRoute] int surveyId)
diff --git a/SurveyBackend/SurveyBackend.API/Controllers/SurveyController.cs b/SurveyBackend/SurveyBackend.API/Controllers/SurveyController.cs
index ca82219..6dbf611 100644
--- a/SurveyBackend/SurveyBackend.API/Controllers/SurveyController.cs
+++ b/SurveyBackend/SurveyBackend.API/Controllers/SurveyController.cs
@@ -123,7 +123,8 @@ public class SurveyController : ControllerBase
{
var userId = _userContext.UserId;
- var result = await _surveyService.GetSurveysByUserIdAsync(userId);
+ var surveys = await _surveyService.GetSurveysByUserIdAsync(userId);
+ var result = surveys.Select(SurveyMapper.ModelToOutputDto);
return Ok(result);
}
}
\ No newline at end of file