package router import ( v1 "aps_crm/api/v1" "github.com/gin-gonic/gin" ) func InitTimeSpentRouter(router *gin.RouterGroup) { TimeSpentRouter := router.Group("timeSpent") TimeSpentApi := v1.TimeSpentApi{} { TimeSpentRouter.POST("add", TimeSpentApi.Add) // 添加花费时间 TimeSpentRouter.DELETE("delete/:id", TimeSpentApi.Delete) // 删除花费时间 TimeSpentRouter.PUT("update", TimeSpentApi.Update) // 更新花费时间 TimeSpentRouter.GET("list", TimeSpentApi.List) // 获取花费时间列表 } }