File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,27 @@ CRUD templates are split into configurable blocks.
2121
2222You can add new blocks, disable existing ones, or reorder them using the [ TwigHooks package] ( ../twig-hooks/getting-started.md ) .
2323
24+ ### Usage with the Sylius Resource package
25+
26+ {% code title="src/Entity/Speaker.php" lineNumbers="true" %}
27+ ``` php
28+ namespace App\Entity;
29+
30+ use Sylius\Resource\Metadata\AsResource;
31+ use Sylius\Resource\Model\ResourceInterface;
32+
33+ #[AsResource(
34+ // We still use the Sylius admin ui templates dir.
35+ templatesDir: '@SyliusAdminUi/crud',
36+ )]
37+ class Speaker implements ResourceInterface
38+ {
39+ // ...
40+ }
41+
42+ ```
43+ {% endcode %}
44+
2445### Create
2546
2647This package sets up the template content needed to create a new resource.
You can’t perform that action at this time.
0 commit comments