Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore non reflectable methods #920

Closed
wants to merge 972 commits into from

Conversation

Projects
None yet
@gpenverne
Copy link

commented Sep 30, 2016

When controller is generated dynamically by a factory , apidocbundle can't reflect method and throws exception.

jeskew and others added some commits Sep 26, 2014

@hoducha

This comment has been minimized.

Copy link

commented on e7d3c80 Nov 4, 2014

An error occur if the API support only one method. Should change the line 251 to:

{% if methods|length > 0 %}

This comment has been minimized.

Copy link
Contributor Author

replied Nov 4, 2014

I use this feature from days now and i don't see the problem you pointing at, can you be more explicit plz?

This comment has been minimized.

Copy link

replied Nov 4, 2014

Sorry, it works well. There is an error in my code. Thank you!

This comment has been minimized.

Copy link
Collaborator

replied Nov 4, 2014

:)

Rodrigo Rigotti and others added some commits Nov 5, 2014

Merge pull request #555 from damienalexandre/fixLinkParser
Fix the PhpDoc Handler for `@link` annotation and add tests
fix sandbox with host
suggested change in #353 is not working
Fixed type annotations
(avoid triggering warning on IDEs like PhpStorm
Merge pull request #573 from jcrombez/patch-1
[doc] missing "sandbox:" in the authentication yaml examples
cs

jupeter and others added some commits Jun 2, 2016

Merge pull request #860 from jupeter/format-wrapping
Fix wrapping of format table row
Merge pull request #861 from Uplink03/master
Links from index.rst to the other doc files
Merge pull request #865 from javiereguiluz/fix_doc_links
Fixed the links to some doc articles
gmarchal
Merge pull request #866 from Gregoire-M/master
Usage of OUTPUT_RAW to avoid javascript syntax error when dumping HTML
Merge pull request #857 from zanardigit/master
Add navigation index for resources
Merge pull request #811 from InputOutput/allow-input-and-filters
Allow filter descriptions to be used in conjunction with POST/PUT inp…
Fix error:
Key "statusCodes" for array with keys "method, uri, description, documentation, filters, requirements, parsedResponseMap, https, authentication, authenticationRoles, deprecated, id" does not exist in NelmioApiDocBundle::method.html.twig at line 182.

Sample:

 /**
     * Retrieves the list of categories (paginated) based on criteria.
     *
     * @apidoc(
     *  resource=true,
     *  output={"class"="Sonata\DatagridBundle\Pager\PagerInterface", "groups"={"sonata_api_read"}}
     * )
     *
     *
     * @QueryParam(name="page", requirements="\d+", default="1", description="Page for category list pagination")
     * @QueryParam(name="count", requirements="\d+", default="10", description="Number of categories by page")
     * @QueryParam(name="enabled", requirements="0|1", nullable=true, strict=true, description="Enabled/Disabled categories filter")
     * @QueryParam(name="context", requirements="\S+", nullable=true, strict=true, description="Context of categories")
     *
     * @view(serializerGroups="sonata_api_read", serializerEnableMaxDepthChecks=true)
     *
     * @param ParamFetcherInterface $paramFetcher
     *
     * @return PagerInterface
     */
Merge pull request #874 from rmzamora/master
Fix error: Key "statusCodes" for array with keys...
Merge pull request #890 from Invis1ble/fix-889
Fixed placeholder translations #889
@andreyserdjuk

This comment has been minimized.

Copy link

commented on Resources/views/method.html.twig in 8aa5e47 Aug 22, 2016

JSON_UNESCAPED_UNICODE - since php5.4, may be to avoid usage of it?

ruscon and others added some commits Sep 9, 2016

@@ -144,14 +144,17 @@ public function extractAnnotations(array $routes, $view = ApiDoc::DEFAULT_VIEW)
foreach ($this->annotationsProviders as $annotationProvider) {
foreach ($annotationProvider->getAnnotations() as $annotation) {
$route = $annotation->getRoute();
$array[] = array('annotation' => $this->extractData($annotation, $route, $this->getReflectionMethod($route->getDefault('_controller'))));
$reflectionMethod = $this->getReflectionMethod($route->getDefault('_controller'));
if (null !== $reflectionMethod) {

This comment has been minimized.

Copy link
@gpenverne

gpenverne Sep 30, 2016

Author

Here, check if method can be reflected.

gpenverne added some commits Sep 30, 2016

@kbsali

This comment has been minimized.

Copy link
Contributor

commented Oct 3, 2016

👍

@GuilhemN GuilhemN closed this May 31, 2017

@GuilhemN GuilhemN force-pushed the nelmio:master branch from adcdd91 to 12247cb May 31, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.