16 lines
372 B
Go
16 lines
372 B
Go
package route
|
|
|
|
import (
|
|
"github.com/gin-gonic/gin"
|
|
"wireguard-dashboard/http/api"
|
|
"wireguard-dashboard/middleware"
|
|
)
|
|
|
|
func ServerApi(r *gin.RouterGroup) {
|
|
apiGroup := r.Group("server", middleware.Authorization())
|
|
{
|
|
apiGroup.GET("", api.Server().GetServer) // 获取服务端信息
|
|
apiGroup.POST("", api.Server().SaveServer) // 新增/更新服务端信息
|
|
}
|
|
}
|