Stages Concept Implemented
This commit is contained in:
1 parent
b40019068e
commit
7efa2b2a02
5 files changed
+606
-43
No files matched your search
@@ -185,6 +185,46 @@ function newStrategyPart () {
|
||||
compatibleType = 'Trading System'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Trigger Stage':
|
||||
compatibleType = 'Strategy'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Open Stage':
|
||||
compatibleType = 'Strategy'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Manage Stage':
|
||||
compatibleType = 'Strategy'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Close Stage':
|
||||
compatibleType = 'Strategy'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Take Position Event':
|
||||
compatibleType = 'Trigger Stage'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Trigger Off Event':
|
||||
compatibleType = 'Trigger Stage'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Trigger On Event':
|
||||
compatibleType = 'Trigger Stage'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Initial Information':
|
||||
compatibleType = 'Open Stage'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Stop':
|
||||
compatibleType = 'Manage Stage'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Take Profit':
|
||||
compatibleType = 'Manage Stage'
|
||||
compatibleSubType = undefined
|
||||
break
|
||||
case 'Phase':
|
||||
compatibleType = 'Stop' + '.' + 'Take Profit' + '.' + 'Phase'
|
||||
compatibleSubType = undefined
|
||||
@@ -674,4 +714,3 @@ function newStrategyPart () {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -186,6 +186,174 @@ function newStrategyPartConstructor () {
|
||||
}]
|
||||
break
|
||||
}
|
||||
case 'Trigger Stage': {
|
||||
menuItemsInitialValues = [
|
||||
{
|
||||
action: 'Pin / Unpin',
|
||||
actionFunction: floatingObject.pinToggle,
|
||||
actionStatus: floatingObject.getPinStatus,
|
||||
currentStatus: false,
|
||||
label: undefined,
|
||||
visible: false,
|
||||
iconPathOn: 'target',
|
||||
iconPathOff: 'security',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -135
|
||||
},
|
||||
{
|
||||
action: 'Delete Trigger Stage',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Delete This Stage',
|
||||
visible: false,
|
||||
iconPathOn: 'trash',
|
||||
iconPathOff: 'trash',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -20
|
||||
},
|
||||
{
|
||||
action: 'Download',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Download',
|
||||
visible: false,
|
||||
iconPathOn: 'upload',
|
||||
iconPathOff: 'upload',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: 20
|
||||
}]
|
||||
break
|
||||
}
|
||||
case 'Open Stage': {
|
||||
menuItemsInitialValues = [
|
||||
{
|
||||
action: 'Pin / Unpin',
|
||||
actionFunction: floatingObject.pinToggle,
|
||||
actionStatus: floatingObject.getPinStatus,
|
||||
currentStatus: false,
|
||||
label: undefined,
|
||||
visible: false,
|
||||
iconPathOn: 'target',
|
||||
iconPathOff: 'security',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -135
|
||||
},
|
||||
{
|
||||
action: 'Delete Open Stage',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Delete This Stage',
|
||||
visible: false,
|
||||
iconPathOn: 'trash',
|
||||
iconPathOff: 'trash',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -20
|
||||
},
|
||||
{
|
||||
action: 'Download',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Download',
|
||||
visible: false,
|
||||
iconPathOn: 'upload',
|
||||
iconPathOff: 'upload',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: 20
|
||||
}]
|
||||
break
|
||||
}
|
||||
case 'Manage Stage': {
|
||||
menuItemsInitialValues = [
|
||||
{
|
||||
action: 'Pin / Unpin',
|
||||
actionFunction: floatingObject.pinToggle,
|
||||
actionStatus: floatingObject.getPinStatus,
|
||||
currentStatus: false,
|
||||
label: undefined,
|
||||
visible: false,
|
||||
iconPathOn: 'target',
|
||||
iconPathOff: 'security',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -135
|
||||
},
|
||||
{
|
||||
action: 'Delete Manage Stage',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Delete This Stage',
|
||||
visible: false,
|
||||
iconPathOn: 'trash',
|
||||
iconPathOff: 'trash',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -20
|
||||
},
|
||||
{
|
||||
action: 'Download',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Download',
|
||||
visible: false,
|
||||
iconPathOn: 'upload',
|
||||
iconPathOff: 'upload',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: 20
|
||||
}]
|
||||
break
|
||||
}
|
||||
case 'Close Stage': {
|
||||
menuItemsInitialValues = [
|
||||
{
|
||||
action: 'Pin / Unpin',
|
||||
actionFunction: floatingObject.pinToggle,
|
||||
actionStatus: floatingObject.getPinStatus,
|
||||
currentStatus: false,
|
||||
label: undefined,
|
||||
visible: false,
|
||||
iconPathOn: 'target',
|
||||
iconPathOff: 'security',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -135
|
||||
},
|
||||
{
|
||||
action: 'Delete Close Stage',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Delete This Stage',
|
||||
visible: false,
|
||||
iconPathOn: 'trash',
|
||||
iconPathOff: 'trash',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -20
|
||||
},
|
||||
{
|
||||
action: 'Download',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Download',
|
||||
visible: false,
|
||||
iconPathOn: 'upload',
|
||||
iconPathOff: 'upload',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: 20
|
||||
}]
|
||||
break
|
||||
}
|
||||
case 'Trigger On Event': {
|
||||
menuItemsInitialValues = [
|
||||
{
|
||||
@@ -315,6 +483,48 @@ function newStrategyPartConstructor () {
|
||||
}]
|
||||
break
|
||||
}
|
||||
case 'Initial Information': {
|
||||
menuItemsInitialValues = [
|
||||
{
|
||||
action: 'Pin / Unpin',
|
||||
actionFunction: floatingObject.pinToggle,
|
||||
actionStatus: floatingObject.getPinStatus,
|
||||
currentStatus: false,
|
||||
label: undefined,
|
||||
visible: false,
|
||||
iconPathOn: 'target',
|
||||
iconPathOff: 'security',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -135
|
||||
},
|
||||
{
|
||||
action: 'Delete Initial Information',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Delete This Stage',
|
||||
visible: false,
|
||||
iconPathOn: 'trash',
|
||||
iconPathOff: 'trash',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: -20
|
||||
},
|
||||
{
|
||||
action: 'Download',
|
||||
actionFunction: payload.onMenuItemClick,
|
||||
label: 'Download',
|
||||
visible: false,
|
||||
iconPathOn: 'upload',
|
||||
iconPathOff: 'upload',
|
||||
rawRadius: 8,
|
||||
targetRadius: 0,
|
||||
currentRadius: 0,
|
||||
angle: 20
|
||||
}]
|
||||
break
|
||||
}
|
||||
case 'Stop': {
|
||||
menuItemsInitialValues = [
|
||||
{
|
||||
@@ -609,6 +819,22 @@ function newStrategyPartConstructor () {
|
||||
level_1()
|
||||
break
|
||||
}
|
||||
case 'Trigger Stage': {
|
||||
level_1()
|
||||
break
|
||||
}
|
||||
case 'Open Stage': {
|
||||
level_1()
|
||||
break
|
||||
}
|
||||
case 'Manage Stage': {
|
||||
level_1()
|
||||
break
|
||||
}
|
||||
case 'Close Stage': {
|
||||
level_1()
|
||||
break
|
||||
}
|
||||
case 'Trigger On Event': {
|
||||
level_2()
|
||||
break
|
||||
@@ -621,7 +847,7 @@ function newStrategyPartConstructor () {
|
||||
level_2()
|
||||
break
|
||||
}
|
||||
case 'Trade Exit Event': {
|
||||
case 'Initial Information': {
|
||||
level_2()
|
||||
break
|
||||
}
|
||||
|
||||
@@ -56,6 +56,18 @@ function newStrategyPartTitle () {
|
||||
thisObject.allwaysVisible = true
|
||||
break
|
||||
}
|
||||
case 'Trigger Stage': {
|
||||
break
|
||||
}
|
||||
case 'Open Stage': {
|
||||
break
|
||||
}
|
||||
case 'Manage Stage': {
|
||||
break
|
||||
}
|
||||
case 'Close Stage': {
|
||||
break
|
||||
}
|
||||
case 'Trigger On Event': {
|
||||
break
|
||||
}
|
||||
@@ -65,6 +77,9 @@ function newStrategyPartTitle () {
|
||||
case 'Take Position Event': {
|
||||
break
|
||||
}
|
||||
case 'Initial Information': {
|
||||
break
|
||||
}
|
||||
case 'Stop': {
|
||||
break
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user