fusenapi/server_api/canteen.api

46 lines
1.2 KiB
Plaintext
Raw Normal View History

2023-06-09 04:07:54 +00:00
syntax = "v1"
info (
title: "餐厅服务"// TODO: add title
desc: // TODO: add description
author: "daming"
email: ""
)
import "basic.api"
2023-06-21 08:39:55 +00:00
2023-06-09 04:07:54 +00:00
service canteen {
//获取餐厅详情
@handler GetCanteenDetailHandler
2023-07-12 03:09:43 +00:00
post /api/canteen-type/detail(GetCanteenDetailReq) returns (response);
2023-06-09 04:16:37 +00:00
//保存餐厅类型关联产品数据
@handler SaveCanteenTypeProductHandler
2023-07-12 03:09:43 +00:00
post /api/canteen-type/save(SaveCanteenTypeProductReq) returns (response);
2023-06-09 04:07:54 +00:00
}
//获取餐厅详情
type GetCanteenDetailReq {
Id int64 `json:"id"`
}
type GetCanteenDetailRsp {
2023-06-20 10:37:56 +00:00
Id int64 `json:"id"`
Name string `json:"name"`
ProductList []*CanteenProduct `json:"product_list"`
2023-06-09 04:07:54 +00:00
}
type CanteenProduct {
Id int64 `json:"id"`
Name string `json:"name"`
SizeId int64 `json:"size_id"`
SId string `json:"s_id"`
2023-06-09 04:16:37 +00:00
}
//保存餐厅类型关联产品数据
type SaveCanteenTypeProductReq {
Id int64 `json:"id"`
Name string `json:"name"`
2023-06-09 08:45:29 +00:00
ProductList []SaveCanteenProduct `json:"product_list"`
2023-06-09 04:16:37 +00:00
}
type SaveCanteenProduct {
Id int64 `json:"id"`
Name string `json:"name"`
SizeId int64 `json:"size_id"`
SId string `json:"s_id"`
2023-06-09 04:07:54 +00:00
}