Describe the "id" parameter of model's sharedCtor

Extend remoting metadata to describe the "id" parameter accepted
by the sharedCtor of all models.
This commit is contained in:
Miroslav Bajtoš 2014-04-03 10:39:42 +02:00
parent 006aca6b9c
commit 4c246c7f2c
1 changed files with 2 additions and 1 deletions

View File

@ -100,8 +100,9 @@ Model.setup = function () {
}; };
// Map the prototype method to /:id with data in the body // Map the prototype method to /:id with data in the body
var idDesc = ModelCtor.modelName + ' id';
ModelCtor.sharedCtor.accepts = [ ModelCtor.sharedCtor.accepts = [
{arg: 'id', type: 'any', http: {source: 'path'}} {arg: 'id', type: 'any', http: {source: 'path'}, description: idDesc}
// {arg: 'instance', type: 'object', http: {source: 'body'}} // {arg: 'instance', type: 'object', http: {source: 'body'}}
]; ];