Feature #9327

Make the resource argument name for REST controllers configurable

Added by Robert Lemke over 9 years ago. Updated about 9 years ago.

Status:
Resolved
Priority:
Should have
Assignee:
Category:
MVC
Start date:
2010-08-16
Due date:
% Done:

100%

PHP Version:
Has patch:
Complexity:

Description

The (not yet fully functional) RestController automatically selects the appropriate action depending on the request type (GET, PUT, DELETE etc.) and if a resource was specified. By now the controller assumes that the resource for show() etc. is specified by an argument called "id". This is, however, old-fashioned, not really DDD compliant and unflexible.

Let's make "resource" the default argument name and allow developers to specify a differing name if necessary.

Associated revisions

Revision cf53c63b (diff)
Added by Robert Lemke about 9 years ago

[~TASK][!!!] FLOW3 (MVC): Renamed the RESTController to RestController.
[+FEATURE] FLOW3 (MVC): The name of the request argument triggering the actions show(), delete() and update is now configurable through the RestController's property "resourceArgumentName". Default name is "resource". Resolves #9327

Change-Id: I9b3427f57f3f9458a71a71fc11df2a0d9209a2c5

History

#1 Updated by Robert Lemke over 9 years ago

  • Status changed from Accepted to Resolved
  • % Done changed from 0 to 100

Applied in changeset r4989.

Also available in: Atom PDF