Skip to content

Conversation

@trejjam
Copy link
Member

@trejjam trejjam commented May 28, 2018

This PR provide possibility append Tag to a method Doc

@f3l1x
Copy link
Member

f3l1x commented May 28, 2018

Wow, nice job. Could give me some example of new annotation? And how does it look in swagger?

@trejjam
Copy link
Member Author

trejjam commented May 28, 2018

These should be possible: @Controller\Method("GET", tag="Info") or @Controller\Method("GET", tags={"Info", "About"}).

I will pass a link to Swagger after CI completes its job.

Here is result https://efpa.scalesoft.cz/api/swagger (it is a staging and is available only at daytime)

@f3l1x
Copy link
Member

f3l1x commented May 28, 2018

I see. Looks great. But, we already have @tag annotation. Which is quite general, you can use it for your own purpose or also for openapi. WDYT?

@trejjam
Copy link
Member Author

trejjam commented May 28, 2018

For me was the @Tag quite confusing. It requires name, but intuitively I do not know what it should be. For some time I was thinking to create @MethodTag, but I left this idea for further development.

Maybe make name optional?

@f3l1x
Copy link
Member

f3l1x commented May 29, 2018

Tag name should be required, @Tag(Info), rather make the value optional. Don't you think? Value is usefule when you need to set some internal tag @Tag(name="resource", value="user/detail") and then implement it easily on your own security handler.

@trejjam trejjam force-pushed the feature/openapi-extend-configuration branch from b5d9f12 to c8600b2 Compare May 29, 2018 13:14
@trejjam
Copy link
Member Author

trejjam commented May 29, 2018

Thanks for the hint, it sounds right. Take a look

@trejjam trejjam force-pushed the feature/openapi-extend-configuration branch from c8600b2 to a76eb55 Compare May 29, 2018 13:16
@f3l1x
Copy link
Member

f3l1x commented May 29, 2018

Awesome.

@f3l1x f3l1x merged commit 081a411 into contributte:master May 29, 2018
@f3l1x f3l1x added feature and removed feature labels Oct 3, 2018
@f3l1x f3l1x added this to the v0.4 milestone Oct 3, 2018
@trejjam trejjam deleted the feature/openapi-extend-configuration branch January 2, 2019 15:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

2 participants