php - FOSRest bundle remove trailing s on routes -


i have issue fosrest bundle , using symfony 2.
problem fosrest adds trailing s post routes.

i have function in accountbundle\settings controller

public function postaccountsettingsaction() {     // } 

now when debug routes shows me

post            accounts/settings.{_format} 

my routing looks following

settings_v1:      type: rest      resource: "........\controller\settingscontroller"      prefix: /v1      name_prefix: v1_  settings_v2:      type: rest      resource: "........\controller\settingscontroller"      prefix: /v2      name_prefix: v2_ 

i don’t want have accounts/settings want account/settings
question: possible rid of trailing s?

i don't think it's possible configure globally. there pull request on repository of project add functionality hasn't been merged yet.

you can still define own url on controller, loose automatic route generation :

/**  * @post("/account/settings")  */ public function postaccountsettingsaction() {     // } 

Comments

Popular posts from this blog

java - Andrioid studio start fail: Fatal error initializing 'null' -

android - Gradle sync Error:Configuration with name 'default' not found -

StringGrid issue in Delphi XE8 firemonkey mobile app -