You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
443 B
Go
22 lines
443 B
Go
package config
|
|
|
|
import (
|
|
"github.com/0xJacky/Nginx-UI/internal/middleware"
|
|
"github.com/gin-gonic/gin"
|
|
)
|
|
|
|
func InitRouter(r *gin.RouterGroup) {
|
|
r.GET("config_base_path", GetBasePath)
|
|
|
|
r.GET("configs", GetConfigs)
|
|
r.GET("config/*name", GetConfig)
|
|
r.POST("config", AddConfig)
|
|
r.POST("config/*name", EditConfig)
|
|
|
|
o := r.Group("", middleware.RequireSecureSession())
|
|
{
|
|
o.POST("config_mkdir", Mkdir)
|
|
o.POST("config_rename", Rename)
|
|
}
|
|
}
|