package autocode

import (
	"github.com/flipped-aurora/gin-vue-admin/server/api/v1"
	"github.com/flipped-aurora/gin-vue-admin/server/middleware"
	"github.com/gin-gonic/gin"
)

type ProblemTypeRouter struct {
}

// InitProblemTypeRouter 初始化 ProblemType 路由信息
func (s *ProblemTypeRouter) InitProblemTypeRouter(Router *gin.RouterGroup) {
	problemTypeRouter := Router.Group("problemType").Use(middleware.OperationRecord())
	var problemTypeApi = v1.ApiGroupApp.AutoCodeApiGroup.ProblemTypeApi
	{
		problemTypeRouter.POST("createProblemType", problemTypeApi.CreateProblemType)             // 新建ProblemType
		problemTypeRouter.DELETE("deleteProblemType", problemTypeApi.DeleteProblemType)           // 删除ProblemType
		problemTypeRouter.DELETE("deleteProblemTypeByIds", problemTypeApi.DeleteProblemTypeByIds) // 批量删除ProblemType
		problemTypeRouter.PUT("updateProblemType", problemTypeApi.UpdateProblemType)              // 更新ProblemType
		problemTypeRouter.GET("findProblemType", problemTypeApi.FindProblemType)                  // 根据ID获取ProblemType
		problemTypeRouter.GET("getProblemTypeList", problemTypeApi.GetProblemTypeList)            // 获取ProblemType列表
	}
}

func (s *ContentRouter) ProblemTypePRouter(Router *gin.RouterGroup) {
	problemTypeRouter := Router.Group("problemType").Use(middleware.OperationRecord())
	var problemTypeApi = v1.ApiGroupApp.AutoCodeApiGroup.ProblemTypeApi
	{
		problemTypeRouter.GET("findProblemTypeList", problemTypeApi.GetProblemTypeList)
	}
}
