diff --git a/docs/create_resource.md b/docs/create_resource.md index 3a979ada1..7d2c675a8 100644 --- a/docs/create_resource.md +++ b/docs/create_resource.md @@ -10,7 +10,7 @@ app_book_create: path: /books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction ``` Done! Now when you go to ``/books/new``, the ResourceController will use the factory (``app.factory.book``) to create a new book instance. Then it will try to create an ``app_book`` form, and set the newly created book as its data. @@ -38,7 +38,7 @@ app_book_create: path: /books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: template: Book/create.html.twig ``` @@ -55,7 +55,7 @@ app_book_create: path: /books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: form: App\Form\BookType ``` @@ -73,7 +73,7 @@ app_book_create: path: /books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: form: type: App\Form\BookType @@ -92,7 +92,7 @@ app_book_create: path: /books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: factory: createNewWithAuthor ``` @@ -105,7 +105,7 @@ app_book_create: path: /books/{author}/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: factory: method: createNewWithAuthor @@ -124,7 +124,7 @@ app_book_create: path: /{authorId}/books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: factory: method: ["expr:service('app.factory.custom_book_factory')", "createNewByAuthorId"] @@ -145,7 +145,7 @@ app_book_create: path: /books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: redirect: app_book_index ``` @@ -158,7 +158,7 @@ app_book_create: path: /genre/{genreId}/books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: redirect: route: app_genre_show @@ -173,7 +173,7 @@ app_book_create: path: /books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: redirect: route: app_book_show @@ -194,7 +194,7 @@ app_book_customer_create: path: /customer/books/new methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: event: customer_create ``` @@ -210,7 +210,7 @@ app_genre_book_add: path: /{genreName}/books/add methods: [GET, POST] defaults: - _controller: app.controller.book:createAction + _controller: app.controller.book::createAction _sylius: template: Book/addToGenre.html.twig form: App\Form\BookType diff --git a/docs/delete_resource.md b/docs/delete_resource.md index 24d8c9874..926aa3e17 100644 --- a/docs/delete_resource.md +++ b/docs/delete_resource.md @@ -9,7 +9,7 @@ app_book_delete: path: /books/{id} methods: [DELETE] defaults: - _controller: app.controller.book:deleteAction + _controller: app.controller.book::deleteAction ``` ## Calling an Action with DELETE method @@ -39,7 +39,7 @@ app_book_delete: path: /genre/{genreId}/books/{id} methods: [DELETE] defaults: - _controller: app.controller.book:deleteAction + _controller: app.controller.book::deleteAction _sylius: criteria: id: $id @@ -58,7 +58,7 @@ app_book_delete: path: /genre/{genreId}/books/{id} methods: [DELETE] defaults: - _controller: app.controller.book:deleteAction + _controller: app.controller.book::deleteAction _sylius: redirect: route: app_genre_show @@ -78,7 +78,7 @@ app_book_customer_delete: path: /customer/book-delete/{id} methods: [DELETE] defaults: - _controller: app.controller.book:deleteAction + _controller: app.controller.book::deleteAction _sylius: event: customer_delete ``` @@ -96,7 +96,7 @@ app_genre_book_remove: path: /{genreName}/books/{id}/remove methods: [DELETE] defaults: - _controller: app.controller.book:deleteAction + _controller: app.controller.book::deleteAction _sylius: event: book_delete repository: diff --git a/docs/index_resources.md b/docs/index_resources.md index ce1305793..836eff0f0 100644 --- a/docs/index_resources.md +++ b/docs/index_resources.md @@ -10,7 +10,7 @@ app_book_index: path: /books methods: [GET] defaults: - _controller: app.controller.book:indexAction + _controller: app.controller.book::indexAction ``` When you go to ``/books``, the ResourceController will use the repository (``app.repository.book``) to create a paginator. The default template will be rendered - ``App:Book:index.html.twig`` with the paginator as the ``books`` variable. @@ -29,7 +29,7 @@ app_book_index_inactive: path: /books/disabled methods: [GET] defaults: - _controller: app.controller.book:indexAction + _controller: app.controller.book::indexAction _sylius: filterable: true criteria: @@ -49,7 +49,7 @@ app_book_index_top: path: /books/top methods: [GET] defaults: - _controller: app.controller.book:indexAction + _controller: app.controller.book::indexAction _sylius: sortable: true sorting: @@ -78,7 +78,7 @@ app_book_index_top: path: /books/top methods: [GET] defaults: - _controller: app.controller.book:indexAction + _controller: app.controller.book::indexAction _sylius: paginate: 5 sortable: true @@ -99,7 +99,7 @@ app_book_index_top3: path: /books/top methods: [GET] defaults: - _controller: app.controller.book:indexAction + _controller: app.controller.book::indexAction _sylius: paginate: false limit: 3 @@ -119,7 +119,7 @@ app_book_index: path: /{author}/books methods: [GET] defaults: - _controller: app.controller.book:indexAction + _controller: app.controller.book::indexAction _sylius: serialization_groups: { 0: Default, items: [ Custom ] } ``` @@ -136,7 +136,7 @@ app_book_index: path: /{author}/books methods: [GET] defaults: - _controller: app.controller.book:indexAction + _controller: app.controller.book::indexAction _sylius: template: Author/books.html.twig repository: diff --git a/docs/show_resource.md b/docs/show_resource.md index b52722e7f..856f1df91 100644 --- a/docs/show_resource.md +++ b/docs/show_resource.md @@ -13,7 +13,7 @@ app_book_show: path: /books/{id} methods: [GET] defaults: - _controller: app.controller.book:showAction + _controller: app.controller.book::showAction ``` Done! Now when you go to ``/books/3``, ResourceController will use the repository (``app.repository.book``) to find a Book with the given id (``3``). If the requested book resource does not exist, it will throw a ``404 Not Found`` exception. @@ -32,7 +32,7 @@ app_admin_book_show: path: /admin/books/{id} methods: [GET] defaults: - _controller: app.controller.book:showAction + _controller: app.controller.book::showAction _sylius: template: Admin/Book/show.html.twig ``` @@ -50,7 +50,7 @@ app_book_show: path: /books/{title} methods: [GET] defaults: - _controller: app.controller.book:showAction + _controller: app.controller.book::showAction _sylius: criteria: title: $title @@ -71,7 +71,7 @@ app_book_show: path: /books/{author} methods: [GET] defaults: - _controller: app.controller.book:showAction + _controller: app.controller.book::showAction _sylius: repository: method: findOneNewestByAuthor @@ -90,7 +90,7 @@ app_book_show: path: /books/{author} methods: [GET] defaults: - _controller: app.controller.book:showAction + _controller: app.controller.book::showAction _sylius: repository: method: ["expr:service('app.repository.custom_book_repository')", "findOneNewestByAuthor"] @@ -108,7 +108,7 @@ app_book_show: path: /books/{author} methods: [GET] defaults: - _controller: app.controller.book:showAction + _controller: app.controller.book::showAction _sylius: template: Book/show.html.twig repository: diff --git a/docs/update_resource.md b/docs/update_resource.md index 3d40a414f..f5edea794 100644 --- a/docs/update_resource.md +++ b/docs/update_resource.md @@ -9,7 +9,7 @@ app_book_update: path: /books/{id}/edit methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction ``` Done! Now when you go to ``/books/5/edit``, ResourceController will use the repository (``app.repository.book``) to find the book with id == **5**. If found it will create the ``app_book`` form, and set the existing book as data. @@ -38,7 +38,7 @@ app_book_update: path: /books/{id}/edit methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: template: Admin/Book/update.html.twig ``` @@ -54,7 +54,7 @@ app_book_update: path: /books/{id}/edit methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: form: App\Form\BookType ``` @@ -71,7 +71,7 @@ app_book_update: path: /books/{id}/edit methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: form: type: app_book_custom @@ -90,7 +90,7 @@ app_book_update: path: /books/{title}/edit methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: criteria: { title: $title } ``` @@ -106,7 +106,7 @@ app_book_update: path: /books/{id}/edit methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: redirect: app_book_index ``` @@ -119,7 +119,7 @@ app_book_update: path: /genre/{genreId}/books/{id}/edit methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: redirect: route: app_genre_show @@ -139,7 +139,7 @@ app_book_customer_update: path: /customer/book-update/{id} methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: event: customer_update ``` @@ -159,7 +159,7 @@ app_book_update: path: /books/{title}/edit methods: [GET, PUT] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: criteria: { title: $title } return_content: true @@ -178,7 +178,7 @@ app_book_update: path: /genre/{genreId}/books/{title}/edit methods: [GET, PUT, PATCH] defaults: - _controller: app.controller.book:updateAction + _controller: app.controller.book::updateAction _sylius: template: Book/editInGenre.html.twig form: app_book_custom