Closed dduo518 closed 6 years ago
dynogels.define()
returns the table model. Perhaps you could return this from your promise?
let model = dynogels.define(...);
// In callback:
resolve({ success: true, model });
You can also access any model by its name as an attribute of dynogels.models
. For example, in your code you could fetch the model as dynogels.models[params.name]
after the call to dynogels.define()
.
hi! I use api dynamic create table;
one api want to query the table ,then how to get the model; or change expression: can I not defined the model and save or query the table thanks