place.go 973 B

123456789101112131415161718192021222324
  1. package autocode
  2. import (
  3. "github.com/flipped-aurora/gin-vue-admin/server/api/v1"
  4. "github.com/flipped-aurora/gin-vue-admin/server/middleware"
  5. "github.com/gin-gonic/gin"
  6. )
  7. type PlaceRouter struct {
  8. }
  9. // InitPlaceRouter 初始化 Place 路由信息
  10. func (s *PlaceRouter) InitPlaceRouter(Router *gin.RouterGroup) {
  11. placeRouter := Router.Group("place").Use(middleware.OperationRecord())
  12. var placeApi = v1.ApiGroupApp.AutoCodeApiGroup.PlaceApi
  13. {
  14. placeRouter.POST("createPlace", placeApi.CreatePlace) // 新建Place
  15. placeRouter.DELETE("deletePlace", placeApi.DeletePlace) // 删除Place
  16. placeRouter.DELETE("deletePlaceByIds", placeApi.DeletePlaceByIds) // 批量删除Place
  17. placeRouter.PUT("updatePlace", placeApi.UpdatePlace) // 更新Place
  18. placeRouter.GET("findPlace", placeApi.FindPlace) // 根据ID获取Place
  19. placeRouter.GET("getPlaceList", placeApi.GetPlaceList) // 获取Place列表
  20. }
  21. }