namespace Tiobon.Core.Api.Controllers; /// /// 题目(Controller) /// [Route("api/[controller]")] [ApiController, GlobalActionFilter] [Authorize(Permissions.Name), ApiExplorerSettings(GroupName = Grouping.GroupName_Ghre)] public class Ghre_QuestionController : BaseController { IGhre_QuestionAnswerServices _ghre_QuestionAnswerServices; public Ghre_QuestionController(IGhre_QuestionServices service, IGhre_QuestionAnswerServices ghre_QuestionAnswerServices) : base(service) { _ghre_QuestionAnswerServices = ghre_QuestionAnswerServices; } #region 基础接口 #region 查询 /// /// 根据Id查询数据 /// /// /// [HttpPost("QueryFrom/{Id}")] public async Task> QueryFrom(long Id) { return await _service.QueryFrom(Id); } #endregion #region 新增 /// /// 新增数据 /// /// /// [HttpPost("InsertFrom")] public async Task InsertFrom([FromBody] FromGhre_QuestionPageData insertModel) { return await _service.InsertFrom(insertModel); } #endregion #region 更新 /// /// 更新数据 /// /// 主键ID /// /// [HttpPost("UpdareFrom/{Id}")] public async Task UpdareFrom(long Id, [FromBody] FromGhre_QuestionPageData editModel) { return await _service.UpdareFrom(Id, editModel); } #endregion #endregion\ }