diff --git a/react/src/components/dashboard/walletsProgress.js b/react/src/components/dashboard/walletsProgress.js index 8815e49..c3157ce 100644 --- a/react/src/components/dashboard/walletsProgress.js +++ b/react/src/components/dashboard/walletsProgress.js @@ -2,6 +2,22 @@ import React from 'react'; import { translate } from '../../translate/translate'; class WalletsProgress extends React.Component { + constructor(props) { + super(props); + this.isFullySynced = this.isFullySynced.bind(this); + } + + isFullySynced() { + if ((Number(this.props.Dashboard.progress.balances) + + Number(this.props.Dashboard.progress.validated) + + Number(this.props.Dashboard.progress.bundles) + + Number(this.props.Dashboard.progress.utxo)) / 4 === 100) { + return true; + } else { + return false; + } + } + render() { if (this.props && this.props.ActiveCoin && this.props.ActiveCoin.mode === 'full' && this.props.Dashboard.progress) { if (this.props.Dashboard.progress && this.props.Dashboard.progress.error) { @@ -12,12 +28,15 @@ class WalletsProgress extends React.Component {
-
+
+ {translate('INDEX.BUNDLES')} ({this.props.ActiveCoin.coin}) 100.00% - ( {this.props.Dashboard.progress.blocks} / {this.props.Dashboard.progress.blocks} ) ==>> RT{this.props.Dashboard.progress.RTheight} +
+
{translate('INDEX.BUNDLES')} {this.props.Dashboard.progress.bundles}%
-
+
utxo {this.props.Dashboard.progress.utxo}% diff --git a/react/src/reducers/activeCoin.js b/react/src/reducers/activeCoin.js index ab49d86..bf1d5b3 100644 --- a/react/src/reducers/activeCoin.js +++ b/react/src/reducers/activeCoin.js @@ -12,6 +12,8 @@ import { DASHBOARD_ACTIVE_COIN_NATIVE_OPIDS } from '../actions/actionCreators'; +// TODO: keep all coin data in array of objects instead of single object + export function ActiveCoin(state = { coin: null, mode: null,