refactor: reorganize modules and add Linux build tooling
This commit is contained in:
27
module/base/cms/internal/logic/site/get.go
Normal file
27
module/base/cms/internal/logic/site/get.go
Normal file
@@ -0,0 +1,27 @@
|
||||
package site
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
pb "bsm/full/module/base/cms/pb"
|
||||
"git.apinb.com/bsm-sdk/core/errcode"
|
||||
"git.apinb.com/bsm-sdk/core/service"
|
||||
)
|
||||
|
||||
// 站点详情
|
||||
func Get(ctx context.Context, in *pb.IdentRequest) (reply *pb.SiteItem, err error) {
|
||||
// parse authorization meta.
|
||||
_, err = service.ParseMetaCtx(ctx, nil)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// valildate request id,identity.
|
||||
if in.Id == 0 && in.Identity == "" {
|
||||
return nil, errcode.ErrInvalidArgument
|
||||
}
|
||||
|
||||
// TODO: add your logic code & delete this line.
|
||||
|
||||
return
|
||||
}
|
||||
Reference in New Issue
Block a user