public.go 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. package routers
  2. import (
  3. "github.com/gin-gonic/gin"
  4. "hongze/hongze_yb/controller"
  5. "hongze/hongze_yb/middleware"
  6. )
  7. func InitPublic(r *gin.Engine) {
  8. rGroup := r.Group("public").Use(middleware.Token())
  9. {
  10. rGroup.GET("/get_apply_variety_list", controller.GetApplyVarietyList)
  11. rGroup.POST("/upload", controller.Upload)
  12. }
  13. initPublic(r)
  14. }
  15. func initPublic(r *gin.Engine) {
  16. rGroup := r.Group("api/public").Use(middleware.Token())
  17. {
  18. rGroup.GET("/get_apply_variety_list", controller.GetApplyVarietyList)
  19. rGroup.POST("/upload", controller.Upload)
  20. rGroup.POST("/get_share_poster", controller.GetSharePoster)
  21. rGroup.GET("/get_suncode_scene", controller.GetSuncodeScene)
  22. rGroup.GET("/get_variety_tag_tree", controller.GetVarietyTagTree)
  23. rGroup.POST("/wechat_warning", controller.WechatWarning)
  24. rGroup.POST("/view_log/update", controller.UpdateViewLog)
  25. rGroup.POST("/banner/mark", controller.BannerMark)
  26. rGroup.GET("/banner/list", controller.BannerList)
  27. rGroup.GET("/banner_history/list", controller.BannerHistoryList)
  28. rGroup.GET("/banner/signup", controller.ResearchSignUp)
  29. rGroup.GET("/banner/get_qrcode", controller.BannerGetQRCode)
  30. rGroup.GET("/banner/detail", controller.BannerDetail)
  31. rGroup.POST("/banner/download", controller.BannerDowload)
  32. }
  33. rGroup2 := r.Group("api/public")
  34. rGroup2.POST("/upload_audio", controller.UploadAudio)
  35. rGroup2.GET("/tel_area_list", controller.GetTelAreaList)
  36. }