Skip to content

Add show_webby option #612

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

Closed
wants to merge 34 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
0c031d2
Fix typo
rogamoore Jul 8, 2018
405485b
Merge pull request #529 from rogamoore/patch-2
teohhanhui Jul 8, 2018
1f2f0da
Documentation for the _api_persist flag (#523)
dunglas Jul 16, 2018
fb1173f
Add missing Field Cardinality in documentation
lologhi Jul 18, 2018
431742a
Merge pull request #541 from lologhi/patch-1
dunglas Jul 19, 2018
fea0876
Fixed some grammatical errors and/or typos.
MelvinLoos Aug 26, 2018
ccda39e
Merge pull request #568 from MelvinLoos/patch-1
teohhanhui Aug 27, 2018
ae97fb3
Correct typo
cedricziel Aug 28, 2018
d2197ab
Update design.md
cedricziel Aug 28, 2018
7f68ca3
Correct sentence in validation.md
cedricziel Aug 28, 2018
be31f5b
Add correct doc tag
cedricziel Aug 28, 2018
07ef7df
Merge pull request #572 from cedricziel/patch-5
dunglas Aug 28, 2018
d6d8b50
Merge pull request #571 from cedricziel/patch-4
dunglas Aug 28, 2018
765639f
Merge pull request #570 from cedricziel/patch-3
dunglas Aug 28, 2018
292928e
Merge pull request #569 from cedricziel/patch-1
dunglas Aug 28, 2018
c0aaba9
Fix broken URL in the doc
maks-rafalko Aug 30, 2018
2ea3fb2
Merge pull request #575 from borNfreee/patch-2
dunglas Aug 30, 2018
c73103f
Merge branch '2.3'
dunglas Oct 1, 2018
c37ed20
Merge branch '2.3'
dunglas Oct 1, 2018
e176770
Add plural s
cedricziel Oct 4, 2018
4403515
Merge pull request #597 from cedricziel/patch-7
teohhanhui Oct 4, 2018
db1cb25
Add `show_webby` option
Deuchnord Oct 9, 2018
e17e0ec
Fixed typo
Deuchnord Oct 9, 2018
88136bd
:pencil2: fix (core-file-upload): remove unused imports from CreateMe…
GregoireHebert Oct 20, 2018
052d53a
Merge branch '2.3'
dunglas Oct 22, 2018
d977c96
Fix typo on subresourceOperations.access_control
vincentchalamon Oct 25, 2018
0b9a518
Merge pull request #632 from vincentchalamon/master
dunglas Oct 25, 2018
8a0436f
Merge pull request #627 from GregoireHebert/fix-upload-example
dunglas Oct 30, 2018
fadb5de
Merge branch '2.3'
dunglas Oct 31, 2018
80ada83
Merge branch '2.3'
dunglas Nov 9, 2018
eba014d
Merge branch '2.3'
dunglas Nov 12, 2018
bda7281
Add `show_webby` option
Deuchnord Oct 9, 2018
727e4b0
Fixed typo
Deuchnord Oct 9, 2018
d1b3f17
Merge branch 'patch-2' of github.com:Deuchnord/api-platform-docs into…
Nov 13, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions core/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ api_platform:

# The version of the API.
version: '0.0.0'

# Set this to false if you want Webby to disappear.
show_webby: true

# Specify a name converter to use.
name_converter: ~
Expand Down
6 changes: 3 additions & 3 deletions core/design.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,10 @@ For [Rapid Application Development](https://en.wikipedia.org/wiki/Rapid_applicat
ORM's data provider and persister implementations shipped with API Platform.

In this case, the public (`@ApiResource`) and internal (Doctrine entity) data model are shared. Then, API Platform will
be able to query, filter, paginate and persist automatically data.
This is approach is super-convenient and efficient, but is probably **not a good idea** for non-[CRUD](https://en.wikipedia.org/wiki/Create,_read,_update_and_delete)
be able to query, filter, paginate and persist data automatically.
This approach is super-convenient and efficient, but is probably **not a good idea** for non-[CRUD](https://en.wikipedia.org/wiki/Create,_read,_update_and_delete)
and/or large systems.
Again, it's up to the developers to use, or to not use those built-in data providers/persisters depending of the business
Again, it's up to the developers to use, or to not use these built-in data providers/persisters depending on the business logic
they are dealing with. API Platform makes it easy to create custom data providers and persisters, and to implement appropriate
patterns such as [CQS](https://www.martinfowler.com/bliki/CommandQuerySeparation.html) or [CQRS](https://martinfowler.com/bliki/CQRS.html).

Expand Down
2 changes: 1 addition & 1 deletion core/errors.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Errors Handling

API Platform comes with a powerful error system. It handles excepted (such as faulty JSON documents sent by the
API Platform comes with a powerful error system. It handles expected (such as faulty JSON documents sent by the
client or validation errors) as well as unexpected errors (PHP exceptions and errors).
API Platform automatically sends the appropriate HTTP status code to the client: `400` for expected errors, `500` for
unexpected ones. It also provides a description of the error in [the Hydra error format](http://www.hydra-cg.com/spec/latest/core/#description-of-http-status-codes-and-errors)
Expand Down
3 changes: 0 additions & 3 deletions core/file-upload.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,8 @@ use App\Entity\MediaObject;
use App\Form\MediaObjectType;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\IsGranted;
use Symfony\Bridge\Doctrine\RegistryInterface;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\Form\FormFactoryInterface;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Serializer\SerializerInterface;
use Symfony\Component\Validator\Validator\ValidatorInterface;

final class CreateMediaObjectAction
Expand Down
2 changes: 1 addition & 1 deletion core/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Validator\Constraints as Assert;

/**
* An offer from my shop - this description will be automatically extracted form the PHPDoc to document the API.
* An offer from my shop - this description will be automatically extracted from the PHPDoc to document the API.
*
* @ApiResource(iri="http://schema.org/Offer")
* @ORM\Entity
Expand Down
4 changes: 2 additions & 2 deletions core/identifiers.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ use App\Uuid;
*/
final class Person {
/**
* @type Uuid
* @var Uuid
* @ApiProperty(identifier=true)
*/
public $code;
Expand Down Expand Up @@ -119,5 +119,5 @@ Your `PersonDataProvider` will now work as expected!
ApiPlatform supports the following identifier types:

- `scalar` (string, integer)
- `\DateTime` (uses the symfony `DateTimeNormalizer` internally, see [DateTimeIdentifierNormalizer](https://github.com/api-platform/core/blob/master/src/Identifier/Normalizer/DateTimeIdentifierNormalizer.php))
- `\DateTime` (uses the symfony `DateTimeNormalizer` internally, see [DateTimeIdentifierNormalizer](https://github.com/api-platform/core/blob/master/src/Identifier/Normalizer/DateTimeIdentifierDenormalizer.php))
- `\Ramsey\Uuid\Uuid` (see [UuidNormalizer](https://github.com/api-platform/core/blob/master/src/Bridge/RamseyUuid/Identifier/Normalizer/UuidNormalizer.php))
9 changes: 4 additions & 5 deletions core/operations.md
Original file line number Diff line number Diff line change
Expand Up @@ -468,19 +468,18 @@ The `subresourceOperations` attribute also allows you to add an access control o

```php
<?php
// api/src/Entity/Question.php
// api/src/Entity/Answer.php

/**
* ...
* @ApiResource(
* subresourceOperations={
* "answer_get_subresource"= {
* "method"="GET",
* "api_questions_answer_get_subresource"= {
* "access_control"="has_role('ROLE_AUTHENTICATED')"
* }
* }
* )
class Question
class Answer
{
}
```
Expand Down Expand Up @@ -740,7 +739,7 @@ Or in XML:
#### Entity Retrieval

If you want to bypass the automatic retrieval of the entity in your custom operation, you can set the parameter
`_api_receive` to `false` in the `default` attribute:
`_api_receive` to `false` in the `defaults` attribute:

```php
<?php
Expand Down
2 changes: 1 addition & 1 deletion core/validation.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ if you want to.

## Validating Submitted Data

Validating submitted data is simple as adding [Symfony's built-in constraints](http://symfony.com/doc/current/reference/constraints.html)
Validating submitted data is as simple as adding [Symfony's built-in constraints](http://symfony.com/doc/current/reference/constraints.html)
or [custom constraints](http://symfony.com/doc/current/validation/custom_constraint.html) directly in classes marked with
the `@ApiResource` annotation:

Expand Down
3 changes: 3 additions & 0 deletions schema-generator/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ Supported cardinalities are:
* `(0..*)`: array, not required
* `(1..1)`: scalar, required
* `(1..*)`: array, required
* `(*..0)`
* `(*..1)`
* `(*..*)`

Cardinalities are enforced by the class generator, the Doctrine ORM generator and the Symfony validation generator.

Expand Down