From da269fd031b0bee7f0b25ad0d53808c5a1602461 Mon Sep 17 00:00:00 2001 From: shunmugam Date: Fri, 18 Oct 2019 13:03:50 +0530 Subject: [PATCH] Commit - Hide popup and fix graphs --- server/controllers/BlockchainKernel.ts | 2 +- .../components/header/header.component.html | 2 +- .../home/graph-list/graph-list.component.ts | 22 +++++++++++++++++++ 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/server/controllers/BlockchainKernel.ts b/server/controllers/BlockchainKernel.ts index 920a61b..a60a1d1 100644 --- a/server/controllers/BlockchainKernel.ts +++ b/server/controllers/BlockchainKernel.ts @@ -898,7 +898,7 @@ LEFT JOIN (select block_id, count(block_id) as block_id_count from blockchain_ou totaloutput = []; TransactionHeatmapChartQuery.forEach(e => { - if(moment(e.hour).format('YYYY-MM-DD') >= moment('2019-09-02').format('YYYY-MM-DD')) + if(moment(e.hour).format('YYYY-MM-DD') >= moment('2019-09-03').format('YYYY-MM-DD')) { date.push(moment(e.hour).format('YYYY-MM-DD')); totalinput.push(e.totalinput != null ? e.totalinput : 0); diff --git a/src/app/shared/components/header/header.component.html b/src/app/shared/components/header/header.component.html index 6cac608..9b5a129 100755 --- a/src/app/shared/components/header/header.component.html +++ b/src/app/shared/components/header/header.component.html @@ -103,7 +103,7 @@ -

"Mining in August was on testnet; mainnet launched with an initial money supply of precisely zero units on September 2." +

diff --git a/src/app/view/home/graph-list/graph-list.component.ts b/src/app/view/home/graph-list/graph-list.component.ts index 1c62f34..e048001 100644 --- a/src/app/view/home/graph-list/graph-list.component.ts +++ b/src/app/view/home/graph-list/graph-list.component.ts @@ -615,6 +615,13 @@ export class GraphListComponent implements OnInit { } difficultyChartFunc(DifficultychartDate, data, Type, range1, range2, range3, tickformat) { + let dtickval; + if(tickformat == "%H-%M") + dtickval = '' + else if(DifficultychartDate.length <11712) + dtickval =2*24*60*60*1000 + else + dtickval =6*24*60*60*1000 let window_width = window.screen.width; let position = 0.00; @@ -658,6 +665,8 @@ export class GraphListComponent implements OnInit { // fixedrange: true, rangemode: 'nonnegative', domain: [domain_start, 0.9], + tick0:DifficultychartDate[0], + dtick:dtickval, // showgrid: true tickfont: { size: 12 @@ -1472,6 +1481,17 @@ export class GraphListComponent implements OnInit { }; } totaldifficultyChartFunc(DifficultychartDate, data, type, range1, range2, range3, tickformat) { + + let dtickval; + if(tickformat == "%H-%M") + dtickval = '' + else if(DifficultychartDate.length <11712) + dtickval =2*24*60*60*1000 + else + dtickval =6*24*60*60*1000 + + + let window_width = window.screen.width; let position = 0.00; let angle = 0; @@ -1509,6 +1529,8 @@ export class GraphListComponent implements OnInit { xaxis: { tickangle: -40, tickformat: tickformat, + tick0:DifficultychartDate[0], + dtick:dtickval, // fixedrange: true, domain: [domain_start, 0.9] // showgrid: true