This commit is contained in:
laodaming
2023-09-15 10:39:08 +08:00
parent 6e89f318fd
commit dd13dcbf0d
14 changed files with 25 additions and 15 deletions

View File

@@ -31,7 +31,7 @@ func NewGetCanteenDetailLogic(ctx context.Context, svcCtx *svc.ServiceContext) *
// 获取餐厅详情
func (l *GetCanteenDetailLogic) GetCanteenDetail(req *types.GetCanteenDetailReq, userinfo *auth.UserInfo) (resp *basic.Response) {
if userinfo.GetIdType() != auth.IDTYPE_User {
return resp.SetStatusWithMessage(basic.CodeServiceErr, "please login first")
return resp.SetStatusWithMessage(basic.CodeServiceErr, "please sign in first")
}
//获取餐厅类型数据
canteenTypeModel := gmodel.NewFsCanteenTypeModel(l.svcCtx.MysqlConn)

View File

@@ -32,7 +32,7 @@ func NewSaveCanteenTypeProductLogic(ctx context.Context, svcCtx *svc.ServiceCont
// 保存餐厅类型的关联产品
func (l *SaveCanteenTypeProductLogic) SaveCanteenTypeProduct(req *types.SaveCanteenTypeProductReq, userinfo *auth.UserInfo) (resp *basic.Response) {
if userinfo.GetIdType() != auth.IDTYPE_User {
return resp.SetStatusWithMessage(basic.CodeServiceErr, "please login first")
return resp.SetStatusWithMessage(basic.CodeServiceErr, "please sign in first")
}
if len(req.ProductList) == 0 {
return resp.SetStatusWithMessage(basic.CodeRequestParamsErr, "product list can`t be empty")