feat: 迁移plant
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
||||
|
||||
"sundynix-micro-go/app/plant/api/internal/svc"
|
||||
"sundynix-micro-go/app/plant/api/internal/types"
|
||||
"sundynix-micro-go/app/plant/rpc/plant"
|
||||
|
||||
"github.com/zeromicro/go-zero/core/logx"
|
||||
)
|
||||
@@ -27,8 +28,10 @@ func NewGetPostDetailLogic(ctx context.Context, svcCtx *svc.ServiceContext) *Get
|
||||
}
|
||||
}
|
||||
|
||||
func (l *GetPostDetailLogic) GetPostDetail(req *types.IdPathReq) error {
|
||||
// todo: add your logic here and delete this line
|
||||
|
||||
return nil
|
||||
func (l *GetPostDetailLogic) GetPostDetail(req *types.IdPathReq) (interface{}, error) {
|
||||
result, err := l.svcCtx.PlantRpc.GetPostDetail(l.ctx, &plant.IdReq{Id: req.Id})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return result, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user