Session to Panels
This commit is contained in:
1 parent
67c9b06cd6
commit
84fd943174
3 files changed
+4
-3
No files matched your search
@@ -200,7 +200,7 @@ function newPlottersManager () {
|
||||
panelCodeName: panelConfig.codeName
|
||||
}
|
||||
let panelOwner = exchange + ' ' + market.assetB + '/' + market.assetA
|
||||
let plotterPanelHandle = canvas.panelsSpace.createNewPanel('Plotter Panel', parameters, panelOwner)
|
||||
let plotterPanelHandle = canvas.panelsSpace.createNewPanel('Plotter Panel', parameters, panelOwner, pProductCard.session)
|
||||
let plotterPanel = canvas.panelsSpace.getPanel(plotterPanelHandle, panelOwner)
|
||||
/* Connect Panel to the Plotter via an Event. */
|
||||
if (panelConfig.event !== undefined) {
|
||||
|
||||
@@ -649,7 +649,7 @@ function newProductCard () {
|
||||
|
||||
if (thisObject.session !== undefined) {
|
||||
const MAX_LABEL_LENGTH = 30
|
||||
if (thisObject.session.name > MAX_LABEL_LENGTH) {
|
||||
if (thisObject.session.name.length > MAX_LABEL_LENGTH) {
|
||||
label = thisObject.session.name.substring(0, MAX_LABEL_LENGTH) + '...' + ' - ' + label
|
||||
} else {
|
||||
label = thisObject.session.name + ' - ' + label
|
||||
|
||||
@@ -35,7 +35,7 @@ function newPanelsSpace () {
|
||||
|
||||
}
|
||||
|
||||
function createNewPanel (pType, pParameters, pOwner) {
|
||||
function createNewPanel (pType, pParameters, pOwner, pSession) {
|
||||
let panel
|
||||
|
||||
switch (pType) {
|
||||
@@ -59,6 +59,7 @@ function newPanelsSpace () {
|
||||
panel = getNewPlotterPanel(pParameters.devTeam, pParameters.plotterCodeName, pParameters.moduleCodeName, pParameters.panelCodeName)
|
||||
panel.fitFunction = canvas.chartSpace.fitIntoVisibleArea
|
||||
panel.container.isVisibleFunction = canvas.chartSpace.isThisPointVisible
|
||||
panel.session = pSession
|
||||
panel.initialize()
|
||||
break
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user