[ALOY-1278] Pass model config to migration functions
| GitHub Issue | n/a |
|---|---|
| Type | Improvement |
| Priority | Low |
| Status | Closed |
| Resolution | Fixed |
| Resolution Date | 2017-05-09T19:23:31.000+0000 |
| Affected Version/s | Alloy 1.6.0 |
| Fix Version/s | Release 6.2.3 |
| Components | Models |
| Labels | alloy, migration, sqlite |
| Reporter | Far |
| Assignee | Radamantis Torres-Lechuga |
| Created | 2015-05-06T23:05:04.000+0000 |
| Updated | 2017-07-24T18:05:01.000+0000 |
Description
It will be nice if sql sync adapter will pass model config to migration functions. It will get access to model columns inside migration for example.
migration.up = function(migrator, config) {
migrator.createTable(config);
// other migration actions
};
Community PR: https://github.com/appcelerator/alloy/pull/684
PR merged.
Node Version: 6.10.3 NPM Version: 3.10.10 Mac OS: 10.12.4 Appc CLI: 6.2.3-master.21 Appc CLI NPM: 4.2.9 Titanium SDK version: 6.1.1.GA Validated fix with test app provided by development using the above environment.