Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,11 @@ function AngularApplicationRun(rest, applicationConstants, notificationService,
rest.setDefaultHttpFields({
timeout: 10000 // milliseconds
});
//var url = applicationConstants.NODE_ADDRESS;
var url = applicationConstants.NODE_ADDRESS;
//var url = 'http://52.28.66.217:6869';
//var url = 'http://52.77.111.219:6869';
//var url = 'http://127.0.0.1:6869';
//var url = 'http://127.0.0.1:8089';
var url = 'http://95.85.56.190:6869';
rest.setBaseUrl(url);

// override mock methods cos in config phase services are not available yet
Expand Down
15 changes: 13 additions & 2 deletions src/js/portfolio/asset.list.controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,20 +83,31 @@
name: ''
};

// adding asset details to cache
applicationContext.cache.assets.put(assetBalance.issueTransaction);
applicationContext.cache.assets.update(id, assetBalance.balance,
assetBalance.reissuable, assetBalance.quantity);
loadAssetDataFromCache(asset);

assets.push(asset);
// adding an asset with positive balance only
if (assetBalance.balance !== 0) {
loadAssetDataFromCache(asset);
assets.push(asset);
}
});

var delay = 1;
// handling the situation when some assets appeared on the account
if (assetList.assets.length === 0 && assets.length > 0) {
assetList.noData = false;
delay = 500; // waiting for 0.5 sec on first data loading attempt
}

// handling the situation when all assets were transferred from the account
if (assetList.assets.length > 0 && assets.length === 0) {
assetList.noData = true;
delay = 500;
}

// to prevent no data message and asset list from displaying simultaneously
// we need to update
$timeout(function() {
Expand Down