order_router.go
556 字节
package routers
import (
"github.com/beego/beego/v2/server/web"
"gitlab.fjmaimaimai.com/mmm-go-pp/partner01/pkg/port/beego/controllers"
)
func init() {
web.Router("/orders/", &controllers.OrderController{}, "Post:CreateOrder")
web.Router("/orders/:orderId", &controllers.OrderController{}, "Put:UpdateOrder")
web.Router("/orders/:orderId", &controllers.OrderController{}, "Get:GetOrder")
web.Router("/orders/:orderId", &controllers.OrderController{}, "Delete:RemoveOrder")
web.Router("/orders/", &controllers.OrderController{}, "Get:ListOrder")
}