Multi Exchange, Multi Market adaptations part 1
This commit is contained in:
1 parent
8b878bbb74
commit
b459856f1f
4 files changed
+17
-9
No files matched your search
+8
-4
@@ -33,6 +33,8 @@ function newPlottersManager () {
|
||||
let initializationReady = false
|
||||
|
||||
let productsPanel
|
||||
let exchange
|
||||
let market
|
||||
|
||||
return thisObject
|
||||
|
||||
@@ -97,13 +99,15 @@ function newPlottersManager () {
|
||||
}
|
||||
}
|
||||
|
||||
function initialize (pProductsPanel, callBackFunction) {
|
||||
function initialize (pProductsPanel, pExchange, pMarket, callBackFunction) {
|
||||
try {
|
||||
if (INFO_LOG === true) { logger.write('[INFO] initialize -> Entering function.') }
|
||||
|
||||
/* Remember the Products Panel */
|
||||
|
||||
productsPanel = pProductsPanel
|
||||
exchange = pExchange
|
||||
market = pMarket
|
||||
|
||||
/* Listen to the event of change of status */
|
||||
|
||||
@@ -222,7 +226,7 @@ function newPlottersManager () {
|
||||
let host = ecosystem.getHost(COMPETITION_HOST)
|
||||
let competition = ecosystem.getCompetition(host, COMPETITION)
|
||||
|
||||
storage.initialize(host, competition, DEFAULT_EXCHANGE, DEFAULT_MARKET, onCompetitionStorageInitialized)
|
||||
storage.initialize(host, competition, exchange, market, onCompetitionStorageInitialized)
|
||||
|
||||
function onCompetitionStorageInitialized (err) {
|
||||
try {
|
||||
@@ -461,7 +465,7 @@ function newPlottersManager () {
|
||||
}
|
||||
}
|
||||
|
||||
storage.initialize(pProductCard.devTeam, pProductCard.bot, pProductCard.product, DEFAULT_EXCHANGE, DEFAULT_MARKET, datetime, timePeriod, onProductStorageInitialized)
|
||||
storage.initialize(pProductCard.devTeam, pProductCard.bot, pProductCard.product, exchange, market, datetime, timePeriod, onProductStorageInitialized)
|
||||
|
||||
function onProductStorageInitialized (err) {
|
||||
try {
|
||||
@@ -505,7 +509,7 @@ function newPlottersManager () {
|
||||
plotter.container.frame.position.x = thisObject.container.frame.width / 2 - plotter.container.frame.width / 2
|
||||
plotter.container.frame.position.y = thisObject.container.frame.height / 2 - plotter.container.frame.height / 2
|
||||
|
||||
plotter.initialize(storage, DEFAULT_EXCHANGE, DEFAULT_MARKET, datetime, timePeriod, onPlotterInizialized)
|
||||
plotter.initialize(storage, exchange, market, datetime, timePeriod, onPlotterInizialized)
|
||||
|
||||
function onPlotterInizialized () {
|
||||
try {
|
||||
|
||||
Reference in new issue
Block a user