package main

import (
	"fmt"
	"github.com/gin-gonic/gin"
)

func main() {
	//获取web引擎对象
	engine := gin.Default()
	engine.DELETE("user/:id", DeleteHandle)

	engine.Run(":8080")
}

func DeleteHandle(context *gin.Context) {
	fmt.Println(context.FullPath())
	userID := context.Param("id")
	fmt.Println(userID)
	context.Writer.Write([]byte("delete user's id:" + userID))

}
