package youngeetalentapi

import (
	"youngmini_server/app/service/youngee_talent_service"

	"github.com/gogf/gf/net/ghttp"
)

var TalentGetApi = talentGetApi{}

type talentGetApi struct {
}

// ListProject godoc
// @BasePath		 /talent/g
// @Summary      GetProjectList
// @Description  GetProjectListInfo
// @Tags         Project
// @Accept       json
// @Produce      json
// @Param        idx    		query     int  		true		"index of page"
// @Param        cnt    		query     int  		true  	"size of page"
// @Param        platform 	query     string	false		"search by platform"
// @Param        mode    		query     string  false		"search by mode"
// @Success      200  {object}   youngee_talent_model.ProjectInfoList
// @Router       /talent/g/get-project-list [get]
func (*talentGetApi) GetProjectList(r *ghttp.Request) {
	res := youngee_talent_service.GetProjectInfoList(r)

	err := r.Response.WriteJson(res)
	if err != nil {
		panic("write response error")
	}
}

// GetInfoTables 获取所有信息表
func (*talentGetApi) GetInfoTables(r *ghttp.Request) {
	res := youngee_talent_service.GetInfoTables()

	err := r.Response.WriteJson(res)
	if err != nil {
		panic("write response error")
	}
}
