Return data source for app.dataSource()
This commit is contained in:
parent
e5b0e8cd70
commit
1fd562ecbd
|
@ -222,14 +222,15 @@ app.models = function () {
|
|||
* Define a DataSource.
|
||||
*
|
||||
* @param {String} name The data source name
|
||||
* @param {Object} config The data source config
|
||||
* @param {Object} config The data source config
|
||||
* @param {DataSource} The registered data source
|
||||
*/
|
||||
|
||||
app.dataSource = function (name, config) {
|
||||
var ds = dataSourcesFromConfig(config, this.connectors);
|
||||
this.dataSources[name] =
|
||||
this.dataSources[classify(name)] =
|
||||
this.dataSources[camelize(name)] =
|
||||
dataSourcesFromConfig(config, this.connectors);
|
||||
this.dataSources[camelize(name)] = ds;
|
||||
return ds;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue