mirror of
https://github.com/Unleash/unleash.git
synced 2024-12-28 00:06:53 +01:00
f85f66d4f5
* feat: add project and environment columns to events * Added events for feature_strategy update * fix duplicate test key for dbInit * Fix argument list for toggleService calls in tests
30 lines
658 B
JavaScript
30 lines
658 B
JavaScript
'use strict';
|
|
|
|
exports.up = function (db, cb) {
|
|
db.runSql(
|
|
`
|
|
ALTER TABLE events
|
|
ADD COLUMN project TEXT;
|
|
ALTER TABLE events
|
|
ADD COLUMN environment TEXT;
|
|
CREATE INDEX events_project_idx ON events(project);
|
|
CREATE INDEX events_environment_idx ON events(environment);
|
|
`,
|
|
cb,
|
|
);
|
|
};
|
|
|
|
exports.down = function (db, cb) {
|
|
db.runSql(
|
|
`
|
|
DROP INDEX events_environment_idx;
|
|
DROP INDEX events_project_idx;
|
|
ALTER TABLE events
|
|
DROP COLUMN environment;
|
|
ALTER TABLE events
|
|
DROP COLUMN project;
|
|
`,
|
|
cb,
|
|
);
|
|
};
|