You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
Tiobon.Web/Tiobon.Core.Api/Controllers/Ghre/Ghre_ExamRecordController.cs

71 lines
2.3 KiB

namespace Tiobon.Core.Api.Controllers;
/// <summary>
/// 考试记录(Controller)
/// </summary>
[Route("api/[controller]")]
[ApiController, GlobalActionFilter]
[Authorize(Permissions.Name), ApiExplorerSettings(GroupName = Grouping.GroupName_Ghre)]
public class Ghre_ExamRecordController : BaseController<IGhre_ExamRecordServices, Ghre_ExamRecord, Ghre_ExamRecordDto, InsertGhre_ExamRecordInput, EditGhre_ExamRecordInput>
{
public Ghre_ExamRecordController(IGhre_ExamRecordServices service) : base(service)
{
}
#region 根据条件查询数据
/// <summary>
/// 根据条件查询数据
/// </summary>
/// <param name="examId">examId</param>
/// <param name="body">条件</param>
/// <returns></returns>
[HttpPost, Route("QueryList/{examId}")]
public async Task<ServicePageResult<Ghre_ExamRecordDto>> Query(string examId, [FromBody] QueryBody body)
{
return await _service.Query(examId, body);
}
#endregion
[HttpPost("ModifyAdjustScore/{examRecordId}")]
public async Task<ServiceResult> ModifyAdjustScore(string examRecordId, [FromBody] EditGhre_ExamRecordInput edit)
{
return await _service.ModifyAdjustScore(examRecordId, edit);
}
/// <summary>
/// 获取考试记录明细扩展接口
/// </summary>
/// <param name="examRecordId"></param>
/// <returns></returns>
[HttpPost("QueryExtend/{examRecordId}")]
public async Task<ServiceResult<Ghre_ExamRecordExtend>> ExtendAsync(long examRecordId)
{
return await _service.ExtendAsync(examRecordId);
}
/// <summary>
/// 提交评语接口
/// </summary>
/// <param name="extend"></param>
/// <param name="examRecordId"></param>
/// <returns></returns>
[HttpPost("Comment/{examRecordId}")]
public async Task<ServiceResult> CommentAsync([FromBody] Ghre_ExamRecordExtend extend, long examRecordId)
{
return await _service.CommentAsync(extend, examRecordId);
}
/// <summary>
/// 获取考试信息
/// </summary>
/// <param name="id">学习记录ID/考试记录ID</param>
/// <returns></returns>
[HttpPost("QueryExam/{id}")]
public async Task<ServiceResult<QueryExam>> QueryExamAsync( long id)
{
return await _service.QueryExamAsync(id);
}
}