MCPcopy Create free account
hub / github.com/APIParkLab/APIPark / ServiceDetail

Method ServiceDetail

controller/catalogue/iml.go:30–42  ·  view source on GitHub ↗
(ctx *gin.Context, sid string)

Source from the content-addressed store, hash-verified

28}
29
30func (i *imlCatalogueController) ServiceDetail(ctx *gin.Context, sid string) (*catalogue_dto.ServiceDetail, error) {
31 detail, err := i.catalogueModule.ServiceDetail(ctx, sid)
32 if err != nil {
33 return nil, err
34 }
35 _, canSubscribe, err := i.appModule.SearchCanSubscribe(ctx, sid)
36 if err != nil {
37 return nil, err
38 }
39 detail.CanSubscribe = canSubscribe
40 return detail, nil
41
42}
43
44func (i *imlCatalogueController) Search(ctx *gin.Context, keyword string) ([]*catalogue_dto.Item, []*tag_dto.Item, error) {
45 catalogues, err := i.catalogueModule.Search(ctx, keyword)

Callers

nothing calls this directly

Calls 2

ServiceDetailMethod · 0.65
SearchCanSubscribeMethod · 0.65

Tested by

no test coverage detected