fusenapi/server/shopping-cart/internal/handler/routes.go

43 lines
952 B
Go
Raw Normal View History

2023-09-13 09:33:58 +00:00
// Code generated by goctl. DO NOT EDIT.
package handler
import (
"net/http"
"fusenapi/server/shopping-cart/internal/svc"
"github.com/zeromicro/go-zero/rest"
)
func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
server.AddRoutes(
[]rest.Route{
{
Method: http.MethodPost,
2023-09-15 06:52:36 +00:00
Path: "/api/shopping-cart/add",
2023-09-13 09:33:58 +00:00
Handler: AddToCartHandler(serverCtx),
},
{
Method: http.MethodPost,
2023-09-15 06:52:36 +00:00
Path: "/api/shopping-cart/delete",
2023-09-13 09:33:58 +00:00
Handler: DeleteCartHandler(serverCtx),
},
{
Method: http.MethodPost,
2023-09-15 06:52:36 +00:00
Path: "/api/shopping-cart/modify",
2023-09-13 09:33:58 +00:00
Handler: ModifyCartPurchaseQuantityHandler(serverCtx),
},
{
Method: http.MethodGet,
Path: "/api/shopping-cart/get_carts",
Handler: GetCartsHandler(serverCtx),
},
2023-09-15 09:59:33 +00:00
{
Method: http.MethodPost,
Path: "/api/shopping-cart/calculate_cart_price",
Handler: CalculateCartPriceHandler(serverCtx),
},
2023-09-13 09:33:58 +00:00
},
)
}