feat:完善活动信息
This commit is contained in:
@ -126,45 +126,69 @@ func registerManageAPI(app *gin.Engine) {
|
||||
func registerEnterpriseAPI(app *gin.Engine) {
|
||||
apiPrefix := "/enterprise"
|
||||
g := app.Group(apiPrefix)
|
||||
|
||||
g.Use(NeedLogin(session.NewManage(), AddSkipperURL([]string{}...)))
|
||||
|
||||
v1 := g.Group("/v1")
|
||||
|
||||
// Upload 上传管理
|
||||
g.POST("/upload", new(api3.Upload).Upload)
|
||||
v1.POST("/upload", new(api3.Upload).Upload)
|
||||
// Config 配置管理
|
||||
config := g.Group("/config")
|
||||
configV1 := v1.Group("/config")
|
||||
{
|
||||
_api := new(api2.Config)
|
||||
config.GET("/area", _api.Area)
|
||||
configV1.GET("/area", _api.Area)
|
||||
}
|
||||
// Account 账号管理
|
||||
accountV1 := v1.Group("/account")
|
||||
{
|
||||
_api := new(api2.Account)
|
||||
accountV1.POST("/login", _api.Login)
|
||||
accountV1.POST("/register", _api.Register)
|
||||
accountV1.POST("/authorize", _api.Authorize)
|
||||
accountV1.POST("/logout", _api.Logout)
|
||||
}
|
||||
// Technology 技术管理
|
||||
technology := g.Group("/technology")
|
||||
technologyV1 := g.Group("/technology")
|
||||
{
|
||||
_api := new(api2.Technology)
|
||||
technology.POST("/paper", _api.Paper)
|
||||
technology.POST("/paper/add", _api.PaperAdd)
|
||||
technology.POST("/paper/edit", _api.PaperEdit)
|
||||
technology.POST("/paper/delete", _api.PaperDelete)
|
||||
technology.POST("/patent", _api.Patent)
|
||||
technology.POST("/patent/detail", _api.PatentDetail)
|
||||
technology.POST("/patent/add", _api.PatentAdd)
|
||||
technology.POST("/patent/edit", _api.PatentEdit)
|
||||
technology.POST("/patent/delete", _api.PatentDelete)
|
||||
technology.POST("/demand", _api.Demand)
|
||||
technology.POST("/demand/detail", _api.DemandDetail)
|
||||
technology.POST("/demand/add", _api.DemandAdd)
|
||||
technology.POST("/demand/edit", _api.DemandEdit)
|
||||
technology.POST("/demand/delete", _api.DemandDelete)
|
||||
technology.POST("/topic", _api.Topic)
|
||||
technology.POST("/topic/add", _api.TopicAdd)
|
||||
technology.POST("/topic/edit", _api.TopicEdit)
|
||||
technology.POST("/topic/delete", _api.TopicDelete)
|
||||
technology.POST("/equipment", _api.Equipment)
|
||||
technology.POST("/equipment/add", _api.EquipmentAdd)
|
||||
technology.POST("/equipment/edit", _api.EquipmentEdit)
|
||||
technology.POST("/equipment/delete", _api.EquipmentDelete)
|
||||
technologyV1.POST("/paper", _api.Paper)
|
||||
technologyV1.POST("/paper/add", _api.PaperAdd)
|
||||
technologyV1.POST("/paper/edit", _api.PaperEdit)
|
||||
technologyV1.POST("/paper/delete", _api.PaperDelete)
|
||||
technologyV1.POST("/patent", _api.Patent)
|
||||
technologyV1.POST("/patent/detail", _api.PatentDetail)
|
||||
technologyV1.POST("/patent/add", _api.PatentAdd)
|
||||
technologyV1.POST("/patent/edit", _api.PatentEdit)
|
||||
technologyV1.POST("/patent/delete", _api.PatentDelete)
|
||||
technologyV1.POST("/demand", _api.Demand)
|
||||
technologyV1.POST("/demand/detail", _api.DemandDetail)
|
||||
technologyV1.POST("/demand/add", _api.DemandAdd)
|
||||
technologyV1.POST("/demand/edit", _api.DemandEdit)
|
||||
technologyV1.POST("/demand/delete", _api.DemandDelete)
|
||||
technologyV1.POST("/topic", _api.Topic)
|
||||
technologyV1.POST("/topic/add", _api.TopicAdd)
|
||||
technologyV1.POST("/topic/edit", _api.TopicEdit)
|
||||
technologyV1.POST("/topic/delete", _api.TopicDelete)
|
||||
technologyV1.POST("/equipment", _api.Equipment)
|
||||
technologyV1.POST("/equipment/add", _api.EquipmentAdd)
|
||||
technologyV1.POST("/equipment/edit", _api.EquipmentEdit)
|
||||
technologyV1.POST("/equipment/delete", _api.EquipmentDelete)
|
||||
}
|
||||
// Identity 身份信息
|
||||
identity := g.Group("/config")
|
||||
identityV1 := v1.Group("/config")
|
||||
{
|
||||
_api := new(api2.Identity)
|
||||
identity.POST("/expert", _api.Expert)
|
||||
identityV1.POST("/expert", _api.Expert)
|
||||
}
|
||||
// Activity 活动信息
|
||||
activityV1 := v1.Group("/activity")
|
||||
{
|
||||
_api := new(api2.Activity)
|
||||
activityV1.POST("/apply", _api.Applys)
|
||||
activityV1.POST("/apply/revoke", _api.ApplyRevoke)
|
||||
activityV1.POST("/apply/delete", _api.ApplyDelete)
|
||||
activityV1.POST("/joins", _api.Joins)
|
||||
activityV1.POST("/join/delete", _api.JoinDelete)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user