Merge branch 'master' of https://gitlab.com/epic-tech/explorer2.epic.tech-angular8
This commit is contained in:
commit
b3714c2961
@ -1238,6 +1238,11 @@ export class BlockchainBlockController {
|
||||
|
||||
var Maxrange = Math.max.apply(Math, TotalDifficultyNBlockQuery.map(function(o) { return o.tarket_difficulty; }));
|
||||
var Minrange = Math.min.apply(Math, TotalDifficultyNBlockQuery.map(function(o) { return o.tarket_difficulty; }));
|
||||
if(Minrange != 0){
|
||||
Minrange = (Minrange - (Minrange * 0.2));
|
||||
}
|
||||
Maxrange = (Maxrange + (Maxrange * 0.2));
|
||||
|
||||
// Minrange = parseInt(Minrange);
|
||||
// var Minrange2 = parseInt(Minrange * 0.3);
|
||||
response.status(200).json({
|
||||
@ -1250,7 +1255,7 @@ export class BlockchainBlockController {
|
||||
// DifficultyCuckatoo: DifficultyCuckatoo,
|
||||
// DifficultyProgpow: DifficultyProgpow,
|
||||
Maxrange: Maxrange,
|
||||
Minrange: (Minrange * 0.2),
|
||||
Minrange: Minrange,
|
||||
TargetDifficulty: TargetDifficulty,
|
||||
tickFormat: tickFormat
|
||||
},
|
||||
|
@ -217,6 +217,7 @@ export async function universalGetLatestBlockDetails(socket) {
|
||||
input_count: BlockchainLatestBlockQuery[0].input_count,
|
||||
kernel_count: BlockchainLatestBlockQuery[0].kernel_count,
|
||||
output_count: BlockchainLatestBlockQuery[0].output_count,
|
||||
hash: BlockchainLatestBlockQuery[0].hash,
|
||||
proof: BlockchainLatestBlockQuery[0].proof,
|
||||
hasharray: hasharray,
|
||||
Difficulty: Difficulty,
|
||||
|
@ -2,7 +2,19 @@
|
||||
<nav class="navbar navbar-expand navbar-light bg-transparent">
|
||||
<div class="container-fluid">
|
||||
<div class="collapse navbar-collapse home_mble_hdr" id="navbarSupportedContent">
|
||||
<div class="home_tst_net">
|
||||
|
||||
<ul class="navbar-nav ml-auto">
|
||||
<!-- <li *ngIf="TimeArr" class="d-none d-sm-inline-block"><h1 class="test_msg d-inline-block mb-0 align-middle mr-3">{{'home.HEADER_TEXT' | translate}}</h1>
|
||||
<h1 class="test_msg align-middle mr-3 d-inline-block mb-0">{{'home.COUNTDOWN' | translate}}</h1>
|
||||
<ul class="list-unstyled d-inline-block bg-white p-2 mb-0 timer">
|
||||
<li class="d-inline-block"><span id="days">{{TimeArr.d}}d:</span></li>
|
||||
<li class="d-inline-block"><span id="hours">{{TimeArr.h}}h:</span></li>
|
||||
<li class="d-inline-block"><span id="minutes">{{TimeArr.m}}m:</span></li>
|
||||
<li class="d-inline-block"><span id="seconds">{{TimeArr.s}}s</span></li>
|
||||
</ul>
|
||||
|
||||
</li> -->
|
||||
<li class="home_tst_net mr-3">
|
||||
<span>You are viewing </span>
|
||||
<ul class="list-unstyled d-inline-block mb-0">
|
||||
<li class="nav-item dropdown">
|
||||
@ -23,20 +35,8 @@
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
<span> Network </span>
|
||||
</div>
|
||||
<ul class="navbar-nav ml-auto">
|
||||
<!-- <li *ngIf="TimeArr" class="d-none d-sm-inline-block"><h1 class="test_msg d-inline-block mb-0 align-middle mr-3">{{'home.HEADER_TEXT' | translate}}</h1>
|
||||
<h1 class="test_msg align-middle mr-3 d-inline-block mb-0">{{'home.COUNTDOWN' | translate}}</h1>
|
||||
<ul class="list-unstyled d-inline-block bg-white p-2 mb-0 timer">
|
||||
<li class="d-inline-block"><span id="days">{{TimeArr.d}}d:</span></li>
|
||||
<li class="d-inline-block"><span id="hours">{{TimeArr.h}}h:</span></li>
|
||||
<li class="d-inline-block"><span id="minutes">{{TimeArr.m}}m:</span></li>
|
||||
<li class="d-inline-block"><span id="seconds">{{TimeArr.s}}s</span></li>
|
||||
</ul>
|
||||
|
||||
</li> -->
|
||||
|
||||
|
||||
</li>
|
||||
<li class="nav-item px-2 dropdown bg-white">
|
||||
|
||||
<span class="flag " [ngStyle]="{ 'background-image': 'url(assets/img/' + translate.getCurrentLang() + '.jpg)'}"></span>
|
||||
|
@ -12,7 +12,7 @@ export class BlockAppendComponent implements OnInit {
|
||||
constructor() {}
|
||||
|
||||
ngOnInit() {
|
||||
console.log(this.blockdetails);
|
||||
//console.log(this.blockdetails);
|
||||
}
|
||||
|
||||
public onClickPlus(height) {
|
||||
|
@ -6,7 +6,19 @@
|
||||
<!-- <span class="txn_count" *ngIf="this.lg_last.length > 0"><span *ngFor="let l of lg_last">{{
|
||||
this.l | number</span>
|
||||
}}</span> -->
|
||||
|
||||
<div class="chart_show">
|
||||
<div class="difficulty_filter day_filter p-0 bg-transparent mt-2">
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', difficultyRange,'cuckatoo'); selectedItem12 = 1
|
||||
" id="1" #item121 [ngClass]="{ active: selectedItem12 == item121.id, txt_primay: true }">Cuckoo</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', difficultyRange,'progpow'); selectedItem12 = 2
|
||||
" id="2" #item122 [ngClass]="{ active: selectedItem12 == item122.id, txt_primay: true }">ProgPow</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', difficultyRange,'randomx'); selectedItem12 = 3
|
||||
" id="3" #item123 [ngClass]="{ active: selectedItem12 == item123.id, txt_primay: true }">RandomX</a>
|
||||
</div>
|
||||
<epic-explorer-plotly *ngIf="linearGraphData.data" [data]="linearGraphData.data" [layout]="linearGraphData.layout">
|
||||
</epic-explorer-plotly>
|
||||
<div *ngIf="!linearGraphData.data" class="feedback_div news_desc text-center">
|
||||
@ -26,13 +38,13 @@
|
||||
<div class="day_filter diff_margin">
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', '1 day',''); selectedItem = 6; difficultyRange = '1 day'
|
||||
" id="6" #item6 [ngClass]="{ active: selectedItem == item6.id, txt_primay: true }">1 Day</a>
|
||||
" id="6" #item6 [ngClass]="{ active: selectedItem == item6.id, txt_primay: true }">1 day</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', '1 week',''); selectedItem = 1; difficultyRange = '1 week'
|
||||
" id="1" #item1 [ngClass]="{ active: selectedItem == item1.id, txt_primay: true }">1 {{'home.WEEK' | translate}}</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
<!-- <a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', '15 days',''); selectedItem = 2; difficultyRange = '15 days'
|
||||
" id="2" #item2 [ngClass]="{ active: selectedItem == item2.id, day15_txt: true }">15 {{'home.DAYS' | translate}}</a>
|
||||
" id="2" #item2 [ngClass]="{ active: selectedItem == item2.id, day15_txt: true }">15 {{'home.DAYS' | translate}}</a> -->
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', '30 days',''); selectedItem = 3; difficultyRange = '30 days'
|
||||
" id="3" #item3 [ngClass]="{ active: selectedItem == item3.id, day30_txt: true }">30 {{'home.DAYS' | translate}}</a>
|
||||
@ -45,17 +57,7 @@
|
||||
</div>
|
||||
|
||||
<div class="explore_all text-right">
|
||||
<div class="d-inline float-left difficulty_filter day_filter p-0 bg-transparent">
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', difficultyRange,'cuckatoo'); selectedItem12 = 1
|
||||
" id="1" #item121 [ngClass]="{ active: selectedItem12 == item121.id, txt_primay: true }">Cuckoo</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', difficultyRange,'progpow'); selectedItem12 = 2
|
||||
" id="2" #item122 [ngClass]="{ active: selectedItem12 == item122.id, txt_primay: true }">ProgPow</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('target', '', '', difficultyRange,'randomx'); selectedItem12 = 3
|
||||
" id="3" #item123 [ngClass]="{ active: selectedItem12 == item123.id, txt_primay: true }">RandomX</a>
|
||||
</div>
|
||||
|
||||
<a routerLink="/chart/target-difficulty"><span class="text-uppercase">{{'home.EXPLORE_IT' | translate}} <i
|
||||
class="fa fa-long-arrow-right"></i></span></a>
|
||||
</div>
|
||||
@ -68,7 +70,22 @@
|
||||
<!-- <span class="txn_count" *ngIf="this.lg_last.length > 0"><span *ngFor="let l of lg_last">{{
|
||||
this.l | number</span>
|
||||
}}</span> -->
|
||||
|
||||
<div class="chart_show">
|
||||
<div class="difficulty_filter day_filter p-0 bg-transparent mt-2">
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', TdifficultyRange,'cuckatoo'); selectedTarget12 = 1
|
||||
" id="1" #itemtarget121
|
||||
[ngClass]="{ active: selectedTarget12 == itemtarget121.id, txt_primay: true }">Cuckoo</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', TdifficultyRange,'progpow'); selectedTarget12 = 2
|
||||
" id="2" #itemtarget122
|
||||
[ngClass]="{ active: selectedTarget12 == itemtarget122.id, txt_primay: true }">ProgPow</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', TdifficultyRange,'randomx'); selectedTarget12 = 3
|
||||
" id="3" #itemtarget123
|
||||
[ngClass]="{ active: selectedTarget12 == itemtarget123.id, txt_primay: true }">RandomX</a>
|
||||
</div>
|
||||
<epic-explorer-plotly *ngIf="linearTotalGraphData.data" [data]="linearTotalGraphData.data"
|
||||
[layout]="linearTotalGraphData.layout">
|
||||
</epic-explorer-plotly>
|
||||
@ -89,15 +106,15 @@
|
||||
<div class="day_filter diff_margin">
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', '1 day',''); selectedTarget = 6; TdifficultyRange = '1 day'
|
||||
" id="6" #itemtarget6 [ngClass]="{ active: selectedTarget == itemtarget6.id, txt_primay: true }">1 Day</a>
|
||||
" id="6" #itemtarget6 [ngClass]="{ active: selectedTarget == itemtarget6.id, txt_primay: true }">1 day</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', '1 week',''); selectedTarget = 1; TdifficultyRange = '1 week'
|
||||
" id="1" #itemtarget1 [ngClass]="{ active: selectedTarget == itemtarget1.id, txt_primay: true }">1
|
||||
{{'home.WEEK' | translate}}</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
<!-- <a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', '15 days',''); selectedTarget = 2; TdifficultyRange = '15 days'
|
||||
" id="2" #itemtarget2 [ngClass]="{ active: selectedTarget == itemtarget2.id, day15_txt: true }">15
|
||||
{{'home.DAYS' | translate}}</a>
|
||||
{{'home.DAYS' | translate}}</a> -->
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', '30 days',''); selectedTarget = 3; TdifficultyRange = '30 days'
|
||||
" id="3" #itemtarget3 [ngClass]="{ active: selectedTarget == itemtarget3.id, day30_txt: true }">30
|
||||
@ -113,20 +130,7 @@
|
||||
</div>
|
||||
|
||||
<div class="explore_all text-right">
|
||||
<div class="d-inline float-left difficulty_filter day_filter p-0 bg-transparent">
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', TdifficultyRange,'cuckatoo'); selectedTarget12 = 1
|
||||
" id="1" #itemtarget121
|
||||
[ngClass]="{ active: selectedTarget12 == itemtarget121.id, txt_primay: true }">Cuckoo</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', TdifficultyRange,'progpow'); selectedTarget12 = 2
|
||||
" id="2" #itemtarget122
|
||||
[ngClass]="{ active: selectedTarget12 == itemtarget122.id, txt_primay: true }">ProgPow</a>
|
||||
<a href="JavaScript:void(0);" (click)="
|
||||
Difficultyreq('total', '', '', TdifficultyRange,'randomx'); selectedTarget12 = 3
|
||||
" id="3" #itemtarget123
|
||||
[ngClass]="{ active: selectedTarget12 == itemtarget123.id, txt_primay: true }">RandomX</a>
|
||||
</div>
|
||||
|
||||
<a routerLink="/chart/total-difficulty"><span class="text-uppercase">{{'home.EXPLORE_IT' | translate}} <i
|
||||
class="fa fa-long-arrow-right"></i></span></a>
|
||||
</div>
|
||||
|
@ -173,7 +173,7 @@ export class GraphListComponent implements OnInit {
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Transactiondoublelinechartreq(fromDate = '', ToDate = '', interval = '') {
|
||||
return new Promise((resolve, reject) => {
|
||||
let params = new HttpParams();
|
||||
@ -285,7 +285,7 @@ export class GraphListComponent implements OnInit {
|
||||
let ProgPow = res.response.ProgPow;
|
||||
let Cuckoo = res.response.Cuckoo;
|
||||
let RandomX = res.response.RandomX;
|
||||
|
||||
|
||||
let ProgPowper = res.response.ProgPowper;
|
||||
let Cuckooper = res.response.Cuckooper;
|
||||
let RandomXper = res.response.RandomXper;
|
||||
@ -405,7 +405,7 @@ export class GraphListComponent implements OnInit {
|
||||
let tickformat = res.response.tickFormat;
|
||||
this.lg_last =
|
||||
TargetDifficulty[TargetDifficulty.length - 1];
|
||||
|
||||
|
||||
switch(difftype){
|
||||
case 'total':
|
||||
this.totaldifficultyChartFunc(
|
||||
@ -450,7 +450,7 @@ export class GraphListComponent implements OnInit {
|
||||
res => {
|
||||
if (res['status'] == 200) {
|
||||
let DifficultychartDate = res.response.Date;
|
||||
let BlocksChartDate = res.response.blockDate;
|
||||
let BlocksChartDate = res.response.blockDate;
|
||||
let Blockval = res.response.Blocks;
|
||||
this.brg_last = Blockval[Blockval.length - 1];
|
||||
this.totalBlocksFunc(BlocksChartDate, Blockval);
|
||||
@ -463,7 +463,7 @@ export class GraphListComponent implements OnInit {
|
||||
}
|
||||
|
||||
difficultyChartFunc(DifficultychartDate, TargetDifficulty, Type, range, tickformat) {
|
||||
console.log('range rangerangerange@@@@@@@22444',range);
|
||||
// console.log('range rangerangerange',range);
|
||||
this.linearGraphData = {
|
||||
data: [
|
||||
{
|
||||
|
@ -50,7 +50,7 @@ export class LatestblocksComponent implements OnInit {
|
||||
this.hashvalues = res.response.BlockchainBlockResult;
|
||||
if(CurrentPage == 1){
|
||||
this.lastblock = res.response.BlockchainBlockResult[0].blockchain_block_height;
|
||||
console.log(this.lastblock);
|
||||
//console.log(this.lastblock);
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -252,6 +252,7 @@ a:focus {
|
||||
background: #fff;
|
||||
padding: 0 5px;
|
||||
}
|
||||
.difficulty_filter.day_filter a.active{border-color: #0056b3; color: #0056b3;}
|
||||
.explore_all {
|
||||
background: #ecf2ff;
|
||||
padding: 15px;
|
||||
@ -353,6 +354,9 @@ a:focus {
|
||||
right: 5px;
|
||||
top: 1px;
|
||||
}
|
||||
.chart_show {
|
||||
min-height: 268px;
|
||||
}
|
||||
/************************************************Footer*****************************************/
|
||||
.footer_div {
|
||||
border-top: 1px solid rgba(0, 0, 0, 0.15);
|
||||
|
Loading…
Reference in New Issue
Block a user