Commit 5bb5e543 authored by Mat's avatar Mat
Browse files

harmonisation des routes

parent b9149828
......@@ -7,11 +7,17 @@ api_legume_read:
methods: [ GET ]
api_legume_count:
path: /legumes/count
path: /legumes/compteur
defaults:
_controller: APIBundle:LegumeAPI:count
methods: [ GET ]
api_legume_create:
path: /legume/ajouter
defaults:
_controller: APIBundle:LegumeAPI:create
methods: [ POST ]
api_legume_read_one:
path: /legume/{id}
requirements:
......@@ -20,12 +26,6 @@ api_legume_read_one:
_controller: APIBundle:LegumeAPI:readOne
methods: [ GET ]
api_legume_create:
path: /legume/ajouter
defaults:
_controller: APIBundle:LegumeAPI:create
methods: [ POST ]
api_legume_update:
path: /legume/{id}
requirements:
......@@ -42,6 +42,12 @@ api_legume_delete:
_controller: APIBundle:LegumeAPI:delete
methods: [ DELETE ]
api_legume_search:
path: /legumes/rechercher
defaults:
_controller: APIBundle:LegumeAPI:search
methods: [ GET ]
api_legume_duplicate:
path: /legume/copier/{id}
requirements:
......@@ -50,12 +56,6 @@ api_legume_duplicate:
_controller: APIBundle:LegumeAPI:duplicate
methods: [ GET ]
api_legume_search:
path: /legumes/recherche
defaults:
_controller: APIBundle:LegumeAPI:search
methods: [ GET ]
api_legume_insert_read:
path: /legume/inserer/{id}
requirements:
......@@ -74,12 +74,6 @@ api_legume_insert:
## CRUD OffreAPI
api_offre_create:
path: /offre/ajouter
defaults:
_controller: APIBundle:OffreAPI:create
methods: [ POST ]
api_offre_read_by_status:
path: /offres/{status}
requirements:
......@@ -88,6 +82,12 @@ api_offre_read_by_status:
_controller: APIBundle:OffreAPI:readByStatus
methods: [ GET ]
api_offre_create:
path: /offre/ajouter
defaults:
_controller: APIBundle:OffreAPI:create
methods: [ POST ]
api_offre_update_status:
path: /offre/{id}
requirements:
......
......@@ -6,13 +6,13 @@ potage_homepage:
### les routes des fonctions qui interrogent l'APIBundle
potage_legume_ajax_display:
path: /admin/leslegumes
path: /admin/legumes
defaults:
_controller: PotageBundle:Legume:ajaxDisplay
methods: [ GET ]
potage_offre_ajax_display:
path: /admin/lesoffres
path: /admin/offres
defaults:
_controller: PotageBundle:Offre:ajaxDisplay
methods: [ GET ]
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment