Skip to content
Snippets Groups Projects

Add manual strategy

Merged kzoli requested to merge feature/manual_datasource into master
Compare and
2 files
+ 55
2
Preferences
Compare changes
Files
2
+ 10
2
const BASE_STRATEGY = 'base';
const EDITOR_STRATEGY = 'editor';
const LIGHTWORK_STRATEGY = 'lightwork';
const MANUAL_STRATEGY = 'manual';
const strategyMap = new Map([
['editor', 'editor'],
['tracksy-mouse-keyboard-monitor', 'lightwork'],
['editor', EDITOR_STRATEGY],
['tracksy-mouse-keyboard-monitor', LIGHTWORK_STRATEGY],
['manual_start', MANUAL_STRATEGY],
['manual_end', MANUAL_STRATEGY],
]);
@@ -11,6 +14,8 @@ module.exports = {
availableStrategies: [
BASE_STRATEGY,
EDITOR_STRATEGY,
MANUAL_STRATEGY,
LIGHTWORK_STRATEGY
],
createStrategy: (type) => {
switch (type) {
@@ -20,6 +25,9 @@ module.exports = {
case LIGHTWORK_STRATEGY:
return require('./lightwork-strategy');
case MANUAL_STRATEGY:
return require('./manual-strategy');
default:
return require('./base-strategy');
}