JSDoc improvements
Improve createModel doc, Fix some other minor issues.
This commit is contained in:
parent
ca0c82ca4e
commit
653aab856c
|
@ -494,7 +494,11 @@ DataSource.prototype.setupDataAccess = function (modelClass, settings) {
|
|||
};
|
||||
|
||||
/**
|
||||
* Define a model class.
|
||||
* Define a model class. Returns newly created model object.
|
||||
* The first (String) argument specifying the model name is required.
|
||||
* You can provide one or two JSON object arguments, to provide configuration options.
|
||||
* See [Model definition reference](http://docs.strongloop.com/display/DOC/Model+definition+reference) for details.
|
||||
*
|
||||
* Simple example:
|
||||
* ```
|
||||
* var User = dataSource.createModel('User', {
|
||||
|
@ -533,9 +537,8 @@ DataSource.prototype.setupDataAccess = function (modelClass, settings) {
|
|||
* ```
|
||||
*
|
||||
* @param {String} className Name of the model to create.
|
||||
* @param {Object} properties Hash of class properties in format `{property: Type, property2: Type2, ...}` or `{property: {type: Type}, property2: {type: Type2}, ...}`
|
||||
* @param {Object} settings Other configuration settings.
|
||||
* @returns newly created class
|
||||
* @param {Object} properties Hash of model properties in format `{property: Type, property2: Type2, ...}` or `{property: {type: Type}, property2: {type: Type2}, ...}`
|
||||
* @options {Object} properties Other configuration options. This corresponds to the options key in the config object.
|
||||
*
|
||||
*/
|
||||
|
||||
|
@ -766,10 +769,10 @@ DataSource.prototype.autoupdate = function (models, cb) {
|
|||
*
|
||||
* Keys in options object:
|
||||
*
|
||||
* @property all {Boolean} If true, discover all models; if false, discover only models owned by the current user.
|
||||
* @property views {Boolean} If true, nclude views; if false, only tables.
|
||||
* @property limit {Number} Page size
|
||||
* @property offset {Number} Starting index
|
||||
* @property {Boolean} all If true, discover all models; if false, discover only models owned by the current user.
|
||||
* @property {Boolean} views If true, nclude views; if false, only tables.
|
||||
* @property {Number} limit Page size
|
||||
* @property {Number} offset Starting index
|
||||
*
|
||||
*/
|
||||
DataSource.prototype.discoverModelDefinitions = function (options, cb) {
|
||||
|
|
Loading…
Reference in New Issue