diff --git a/assets/scripts/dashboard/DashboardBasilisk.js b/assets/scripts/dashboard/DashboardBasilisk.js index c8cc53f..914cb18 100644 --- a/assets/scripts/dashboard/DashboardBasilisk.js +++ b/assets/scripts/dashboard/DashboardBasilisk.js @@ -1,7 +1,8 @@ function ShowBasiliskFetchDataProgress(coin) { var active_edexcoinmodecode = sessionStorage.getItem('edexTmpMode'); - Shepherd_GetBasiliskCache().then(function(result) { + Shepherd_GetBasiliskCache() + .then(function(result) { var _data = JSON.parse(result), query = _data.result.basilisk, coin_exists = true, @@ -292,9 +293,12 @@ function SwitchBasicliskFull(switch_data) { } function getBasiliskCoinBalance(coin) { - EDEXMainAddr(coin).then(function(result){ - console.log(result) - EDEX_DEXlistunspent(coin, result).then(function(result_listunspent) { + EDEXMainAddr(coin) + .then(function(result){ + console.log(result); + + EDEX_DEXlistunspent(coin, result) + .then(function(result_listunspent) { console.log(result_listunspent[0].amount); $('span[data-edexcoincode="' + coin + '"][id="edexcoin-balance"]').text(result_listunspent[0].amount); }); diff --git a/assets/scripts/dashboard/DashboardCoinFiat.js b/assets/scripts/dashboard/DashboardCoinFiat.js index 0ebb409..ec86539 100644 --- a/assets/scripts/dashboard/DashboardCoinFiat.js +++ b/assets/scripts/dashboard/DashboardCoinFiat.js @@ -1,13 +1,19 @@ function getCoinBalance(coin) { var active_edexcoin = $('[data-edexcoin]').attr('data-edexcoin'); - EDEXlistunspent(active_edexcoin).then(function(result) { + EDEXlistunspent(active_edexcoin) + .then(function(result) { console.log(result) if (result[0] != undefined) { if ( result[0].interest !== undefined ) { - $('#edexcoin_getbalance_interest').show(); - $('#edexcoin_getbalance_total_interest').show(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-12' ).addClass( 'col-lg-4' ); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ) + .show(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-12' ) + .addClass( 'col-lg-4' ); $('#edex_interest_balance').text(result[0].interest); $('#edex_total_balance_interest').text(result[0].totalbalance); $('#edex_total_interest_coincode').text(active_edexcoin); @@ -15,11 +21,19 @@ function getCoinBalance(coin) { } if ( result[0].interest === undefined ) { - $('#edexcoin_getbalance_interest').hide(); - $('#edexcoin_getbalance_total_interest').hide(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-4' ).addClass( 'col-lg-12' ); - $('#edex_interest_balance').text('-'); - $('#edex_total_balance_interest').text('-'); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ) + .hide(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-4' ) + .addClass( 'col-lg-12' ); + $( + '#edex_interest_balance,' + + '#edex_total_balance_interest' + ) + .text('-'); } $('#edex_total_balance').text(result[0].total); @@ -142,11 +156,14 @@ function ShowCoinProgressBar(coin) { coin_blocks_plus1 = coin_blocks + 1; sessionStorage.setItem('Activate' + coin + 'History', 'Yes'); - $('div[data-edexcoin="'+coin+'"][id="currency-progressbars"]').show(); - $('div[data-edexcoin="'+coin+'"][id="currency-bundles"]').width(parseFloat(CoinInfoData.bundles).toFixed(2) + '%'); - $('span[data-edexcoin="'+coin+'"][id="currency-bundles-percent"]').text('(' + coin + ') ' + parseFloat(CoinInfoData.bundles).toFixed(2) + '% - ( ' + coin_blocks_plus1 + ' / '+ CoinInfoData.longestchain + ' ) ==>> RT' + CoinInfoData.RTheight); - $('div[data-edexcoin="'+coin+'"][id="additional-progress-bars"]').hide(); - $('div[data-edexcoin="'+coin+'"][id="currency-bundles"]').removeClass( 'progress-bar-info' ).addClass( 'progress-bar-indicating progress-bar-success' ); + $('div[data-edexcoin="' + coin + '"][id="currency-progressbars"]').show(); + $('div[data-edexcoin="' + coin + '"][id="currency-bundles"]').width(parseFloat(CoinInfoData.bundles).toFixed(2) + '%'); + $('span[data-edexcoin="' + coin + '"][id="currency-bundles-percent"]') + .text('(' + coin + ') ' + parseFloat(CoinInfoData.bundles).toFixed(2) + '% - ( ' + coin_blocks_plus1 + ' / '+ CoinInfoData.longestchain + ' ) ==>> RT' + CoinInfoData.RTheight); + $('div[data-edexcoin="' + coin + '"][id="additional-progress-bars"]').hide(); + $('div[data-edexcoin="' + coin + '"][id="currency-bundles"]') + .removeClass( 'progress-bar-info' ) + .addClass( 'progress-bar-indicating progress-bar-success' ); $('#edex-footer').css('height', '11px'); resizeDashboardWindow(); $('#edexcoin-wallet-waitingrt-alert').hide(); @@ -159,9 +176,12 @@ function ShowCoinProgressBar(coin) { console.log(coin + ': ' + CoinInfoData.bundles); $('div[data-edexcoin="' + coin + '"][id="additional-progress-bars"]').show(); $('div[data-edexcoin="' + coin + '"][id="currency-progressbars"]').show(); - $('div[data-edexcoin="' + coin + '"][id="currency-bundles"]').removeClass( 'progress-bar-indicating progress-bar-success' ).addClass( 'progress-bar-info' ); + $('div[data-edexcoin="' + coin + '"][id="currency-bundles"]') + .removeClass( 'progress-bar-indicating progress-bar-success' ) + .addClass( 'progress-bar-info' ); $('div[data-edexcoin="' + coin + '"][id="currency-bundles"]').width(parseFloat(CoinInfoData.bundles).toFixed(2) + '%'); - $('span[data-edexcoin="' + coin + '"][id="currency-bundles-percent"]').text('(' + coin + ') ' + parseFloat(CoinInfoData.bundles).toFixed(2) + '% - ( ' + coin_blocks_plus1 + ' / ' + CoinInfoData.longestchain + ' )'); + $('span[data-edexcoin="' + coin + '"][id="currency-bundles-percent"]') + .text('(' + coin + ') ' + parseFloat(CoinInfoData.bundles).toFixed(2) + '% - ( ' + coin_blocks_plus1 + ' / ' + CoinInfoData.longestchain + ' )'); $('div[data-edexcoin="' + coin + '"][id="currency-utxo"]').width(parseFloat(CoinInfoData.utxo).toFixed(2) + '%'); $('span[data-edexcoin="' + coin + '"][id="currency-utxo-percent"]').text('(' + coin + ') ' + parseFloat(CoinInfoData.utxo).toFixed(2) + '%'); $('div[data-edexcoin="' + coin + '"][id="currency-balances"]').width(parseFloat(CoinInfoData.balances).toFixed(2) + '%'); diff --git a/assets/scripts/dashboard/DashboardDEX.js b/assets/scripts/dashboard/DashboardDEX.js index 3197433..c225e4f 100644 --- a/assets/scripts/dashboard/DashboardDEX.js +++ b/assets/scripts/dashboard/DashboardDEX.js @@ -29,7 +29,8 @@ function getDEXGetBalance(coin) { url: 'http://127.0.0.1:' + config.iguanaPort, type: 'POST', dataType: 'json' - }).then(data => { + }) + .then(data => { var total_balance = 0, total_interest = 0; @@ -50,7 +51,8 @@ function getDEXGetBalance(coin) { url: 'http://127.0.0.1:' + config.iguanaPort, type: 'POST', dataType: 'json' - }).then(data => { + }) + .then(data => { console.log(data); total_balance = total_balance + data.balance; @@ -70,8 +72,9 @@ function getDEXGetBalance(coin) { resolve(pass_data); }); }); - })).then(result => { - resolve(result[result.length-1]); + })) + .then(result => { + resolve(result[result.length - 1]); NProgress.done(); }); }); @@ -89,7 +92,8 @@ function getDEXGetBalance_cache(coin) { NProgress.start(); return new Promise((resolve) => { - Shepherd_CheckBasiliskCacheData(coin).then(function(result) { + Shepherd_CheckBasiliskCacheData(coin) + .then(function(result) { //console.log(result); //console.log(result.coin); @@ -100,7 +104,8 @@ function getDEXGetBalance_cache(coin) { 'calls': 'listtransactions:getbalance:refresh' }; //console.log(call_data) - Shepherd_FetchBasiliskData(call_data).then(function(result) { + Shepherd_FetchBasiliskData(call_data) + .then(function(result) { console.log(result); }); } else if (result.getbalance == false) { @@ -116,7 +121,8 @@ function getDEXGetBalance_cache(coin) { } }) - Shepherd_GetBasiliskCache().then(function(result) { + Shepherd_GetBasiliskCache() + .then(function(result) { var _data = JSON.parse(result), query = _data.result.basilisk, total_balance = 0, @@ -147,9 +153,10 @@ function getDEXGetBalance_cache(coin) { pass_data = { 'total': 0.00000000 }; } - resolve(pass_data) - }) - })).then(result => { + resolve(pass_data); + }); + })) + .then(result => { if ( result[result.length - 1].total == 0 ) { resolve(result[result.length - 2]); } else { @@ -255,7 +262,8 @@ function getDEXGetBalance2(coin) { resolve(tmp_addr_total_balance_output) NProgress.done(); - }).fail(function(xhr, textStatus, error) { + }) + .fail(function(xhr, textStatus, error) { // handle request failures console.log(xhr.statusText); if ( xhr.readyState == 0 ) { diff --git a/assets/scripts/dashboard/DashboardEDEX.js b/assets/scripts/dashboard/DashboardEDEX.js index e6811da..2ee7b89 100644 --- a/assets/scripts/dashboard/DashboardEDEX.js +++ b/assets/scripts/dashboard/DashboardEDEX.js @@ -12,7 +12,8 @@ function EdexfillTxHistory(coin) { var active_edexcoinmodecode = sessionStorage.getItem('edexTmpMode'); if ( active_edexcoinmodecode === 'Basilisk' ) { - EdexGetTxList_cache(coin).then(function(result) { + EdexGetTxList_cache(coin) + .then(function(result) { var edex_txhistory_table = ''; edex_txhistory_table = $('#edex-tx-history-tbl').DataTable({ data: result, @@ -38,7 +39,8 @@ function EdexfillTxHistory(coin) { } if ( active_edexcoinmodecode === 'Full' ) { - EdexGetTxList(coin).then(function(result){ + EdexGetTxList(coin) + .then(function(result){ var edex_txhistory_table = ''; edex_txhistory_table = $('#edex-tx-history-tbl').DataTable({ data: result, @@ -265,19 +267,20 @@ function refreshEDEXCoinWalletList() { break; } - walletDivContent += ''; - walletDivContent += '
'; - walletDivContent += '
'; - walletDivContent += '
'; - walletDivContent += ''; - walletDivContent += '
' + coinname + '
'; - walletDivContent += '
'; - walletDivContent += '
'; - walletDivContent += '
'; - walletDivContent += ''; + walletDivContent += + '' + + '
' + + '
' + + '
' + + '' + + '
' + coinname + '
' + + '
' + + '
' + + '
' + + ''; $('.wallet-widgets-row').html(walletDivContent); //getCoinBalance(AllcoinsDataOutput[value][index]); @@ -336,7 +339,8 @@ function EdexGetTxList(coin) { url: 'http://127.0.0.1:' + config.iguanaPort, type: 'POST', dataType: 'json' - }).then(data => { + }) + .then(data => { var total_utxos = []; let params = ''; @@ -403,7 +407,8 @@ function EdexGetTxList(coin) { resolve(total_utxos); }); }); - })).then(result => { + })) + .then(result => { let result_data = result[result.length - 1]; let compiled_result = []; @@ -438,18 +443,18 @@ function EdexGetTxList(coin) { var tmp_secondsToString = secondsToString(result_data[index].blocktime); if ( result_data[index].category == 'send' ) { - tmp_category = ' OUT'; + tmp_category = ' ' + _lang[defaultLang].DASHBOARD.OUT; } if ( result_data[index].category == 'receive' ) { - tmp_category = ' IN'; + tmp_category = ' ' + _lang[defaultLang].DASHBOARD.IN; } if ( result_data[index].category == 'generate' ) { - tmp_category = ' Mined'; + tmp_category = ' ' + _lang[defaultLang].DASHBOARD.IMMATURE; }if ( result_data[index].category == 'immature' ) { - tmp_category = ' Immature'; + tmp_category = ' ' + _lang[defaultLang].DASHBOARD.OUT; } if ( result_data[index].category == 'unknown' ) { - tmp_category = ' Unknown'; + tmp_category = ' ' + _lang[defaultLang].DASHBOARD.UNKNOWN; } tmplisttransactions = [ @@ -498,10 +503,14 @@ function EdexGetTxList(coin) { var tmp_secondsToString = secondsToString(result_data[index].timestamp); if ( result_data[index].type == 'sent' ) { - tmp_category = ' ' + _lang[defaultLang].DASHBOARD.OUT + ''; + tmp_category = '' + + ' ' + _lang[defaultLang].DASHBOARD.OUT + + ''; } if ( result_data[index].type == 'received' ) { - tmp_category = ' ' + _lang[defaultLang].DASHBOARD.IN + ''; + tmp_category = '' + + ' ' + _lang[defaultLang].DASHBOARD.IN + + ''; } if ( result_data[index].type == 'generate' ) { tmp_category = ' ' + _lang[defaultLang].DASHBOARD.MINED; @@ -552,8 +561,9 @@ function EdexGetTxList_cache(coin) { NProgress.start(); return new Promise((resolve) => { - Shepherd_GetBasiliskCache().then(function(result) { - var _data = JSON.parse(result) + Shepherd_GetBasiliskCache() + .then(function(result) { + var _data = JSON.parse(result), query = _data.result.basilisk, active_edexcoinmodecode = sessionStorage.getItem('edexTmpMode'), total_utxos = []; @@ -565,7 +575,8 @@ function EdexGetTxList_cache(coin) { total_utxos = $.merge(total_utxos, data); resolve(total_utxos); }); - })).then(result => { + })) + .then(result => { let result_data = result[result.length - 1]; let compiled_result = []; @@ -590,10 +601,14 @@ function EdexGetTxList_cache(coin) { var tmp_secondsToString = secondsToString(result_data[index].timestamp); if ( result_data[index].type == 'sent' ) { - tmp_category = ' ' + _lang[defaultLang].DASHBOARD.OUT + ''; + tmp_category = '' + + ' ' + _lang[defaultLang].DASHBOARD.OUT + + ''; } if ( result_data[index].type == 'received' ) { - tmp_category = ' ' + _lang[defaultLang].DASHBOARD.IN + ''; + tmp_category = '' + + ' ' + _lang[defaultLang].DASHBOARD.IN + + ''; } if ( result_data[index].type == 'generate' ) { tmp_category = ' ' + _lang[defaultLang].DASHBOARD.MINED; @@ -855,7 +870,8 @@ function EdexListAllAddr(coin) { active_edexcoinmodecode = sessionStorage.getItem('edexTmpMode'); if (active_edexcoinmodecode == 'Basilisk' && coin !== 'BTC' && coin !== 'SYS') { - EDEXgetaddrbyaccount_cache(coin).then(function(result) { + EDEXgetaddrbyaccount_cache(coin) + .then(function(result) { console.log(result); var only_reciving_addr_data = []; @@ -894,7 +910,8 @@ function EdexListAllAddr(coin) { NProgress.done(); }); } else if (active_edexcoinmodecode == 'Basilisk' ) { - EDEXgetaddrbyaccount(coin).then(function(result){ + EDEXgetaddrbyaccount(coin) + .then(function(result){ console.log(result); var only_reciving_addr_data = []; @@ -935,7 +952,8 @@ function EdexListAllAddr(coin) { } if (active_edexcoinmodecode == 'Full') { - EDEXgetaddrbyaccount(coin).then(function(result) { + EDEXgetaddrbyaccount(coin) + .then(function(result) { console.log(result); var only_reciving_addr_data = []; @@ -980,28 +998,42 @@ function edexCoinBtnAction() { $('.edexcoin-logo').click(function() { $( '#edexcoin_send_coins_back_btn' ).trigger( 'click' ); $('#btn_edexcoin_dashboard').hide(); - $('#btn_edexcoin_send').show(); - $('#btn_edexcoin_recieve').show(); + $( + '#btn_edexcoin_send,' + + '#btn_edexcoin_recieve' + ) + .show(); var selected_coin = $(this).data('edexcoincode'), selected_coinmode = $(this).data('edexcoinmodecode'), selected_coinname = $(this).data('edexcoinname'); - $('#edexcoin_getbalance_interest').hide(); - $('#edexcoin_getbalance_total_interest').hide(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-4' ).addClass( 'col-lg-12' ); - $('#edex_interest_balance').text('-'); - $('#edex_total_balance_interest').text('-'); - $('#edex_total_balance').text('-'); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ) + .hide(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-4' ) + .addClass( 'col-lg-12' ); + $( + '#edex_interest_balance,' + + '#edex_total_balance_interest,' + + '#edex_total_balance' + ) + .text('-'); $('#edex_total_balance_coincode').text(selected_coin); sessionStorage.setItem('edexTmpMode', selected_coinmode); resizeDashboardWindow(); if ( selected_coinmode == 'Basilisk' ) { - $('#edex-footer').hide(); - $('#btn_edexcoin_basilisk').show(); - $('#edexcoin-wallet-waitingrt-alert').hide(); + $('#btn_edexcoin_basilisk').show(); + $( + '#edex-footer,' + + '#edexcoin-wallet-waitingrt-alert' + ) + .hide(); sessionStorage.setItem('edexTmpRefresh', 'start'); } if ( selected_coinmode == 'Full' ) { @@ -1010,15 +1042,21 @@ function edexCoinBtnAction() { sessionStorage.setItem('edexTmpRefresh', 'start'); } if ( selected_coinmode !== 'Native' ) { - $('#edexcoin_dashoard_section').show(); - $('#header-dashboard').show(); - $('#wallet-widgets').show(); - $('#edexcoin_dashboardinfo').show(); - $('#no_wallet_selected').hide(); - $('#edexcoin_send').hide(); - $('#edexcoin_recieve_section').hide(); - $('#edexcoin_settings').hide(); - $('#currency-progressbars').show(); + $( + '#edexcoin_dashoard_section,' + + '#header-dashboard,' + + '#wallet-widgets,' + + '#edexcoin_dashboardinfo,' + + '#currency-progressbars' + ) + .show(); + $( + '#no_wallet_selected,' + + '#edexcoin_send,' + + '#edexcoin_recieve_section,' + + '#edexcoin_settings' + ) + .hide(); // get selected coin's code and populate in easydex wallet widget's html elements var coincode = $(this).data('edexcoincode'); @@ -1034,13 +1072,14 @@ function edexCoinBtnAction() { $('#edexcoin-active').text(selected_coinname); $('#edex_total_balance_coincode').text(coincode); // populate selected coin's address - EDEXMainAddr(selected_coin).then(function(result) { + EDEXMainAddr(selected_coin) + .then(function(result) { $('#edexcoin_active_addr').text(result); $('#edexcoin_active_addr_clipboard').attr('data-clipboard-text', result); }) $('#edexcoin_active_addr_clipboard').click(function() { - alertify.success('Address Copied.'); + alertify.success(_lang[defaultLang].DASHBOARD.ADDR_COPIED + '.'); }); var clipboard = new Clipboard('.clipboard-edexaddr'); @@ -1080,11 +1119,17 @@ function edexCoinBtnAction() { selected_coin !== 'CARB' && selected_coin !== 'ANC' && selected_coin !== 'FRK') { - getDEXGetBalance_cache(selected_coin).then(function(result) { + getDEXGetBalance_cache(selected_coin) + .then(function(result) { if ( result.interest !== undefined && selected_coin == 'KMD') { - $('#edexcoin_getbalance_interest').show(); - $('#edexcoin_getbalance_total_interest').show(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-12' ).addClass( 'col-lg-4' ); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ) + .show(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-12' ) + .addClass( 'col-lg-4' ); $('#edex_interest_balance').text(result.interest); $('#edex_total_balance_interest').text(result.totalbalance); $('#edex_total_interest_coincode').text(selected_coin); @@ -1092,22 +1137,36 @@ function edexCoinBtnAction() { } if ( result.interest === undefined || selected_coin !== 'KMD') { - $('#edexcoin_getbalance_interest').hide(); - $('#edexcoin_getbalance_total_interest').hide(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-4' ).addClass( 'col-lg-12' ); - $('#edex_interest_balance').text('-'); - $('#edex_total_balance_interest').text('-'); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ) + .hide(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-4' ) + .addClass( 'col-lg-12' ); + $( + '#edex_interest_balance,' + + '#edex_total_balance_interest' + ) + .text('-'); } $('#edex_total_balance').text(result.total); $('#edex_total_balance_coincode').text(selected_coin); }); } else if (selected_coinmode == 'Basilisk') { - getDEXGetBalance2(selected_coin).then(function(result) { + getDEXGetBalance2(selected_coin) + .then(function(result) { if ( result.interest !== undefined ) { - $('#edexcoin_getbalance_interest').show(); - $('#edexcoin_getbalance_total_interest').show(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-12' ).addClass( 'col-lg-4' ); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ) + .show(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-12' ) + .addClass( 'col-lg-4' ); $('#edex_interest_balance').text(result.interest); $('#edex_total_balance_interest').text(result.totalbalance); $('#edex_total_interest_coincode').text(selected_coin); @@ -1115,23 +1174,36 @@ function edexCoinBtnAction() { } if ( result.interest === undefined || selected_coin !== 'KMD') { - $('#edexcoin_getbalance_interest').hide(); - $('#edexcoin_getbalance_total_interest').hide(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-4' ).addClass( 'col-lg-12' ); - $('#edex_interest_balance').text('-'); - $('#edex_total_balance_interest').text('-'); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ) + .hide(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-4' ) + .addClass( 'col-lg-12' ); + $( + '#edex_interest_balance,' + + '#edex_total_balance_interest' + ) + .text('-'); } $('#edex_total_balance').text(result.total); $('#edex_total_balance_coincode').text(selected_coin); }); } else { - EDEXlistunspent(selected_coin).then(function(result) { + EDEXlistunspent(selected_coin) + .then(function(result) { if (result[0] != undefined) { if ( result[0].interest !== undefined ) { - $('#edexcoin_getbalance_interest').show(); - $('#edexcoin_getbalance_total_interest').show(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-12' ).addClass( 'col-lg-4' ); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ).show(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-12' ) + .addClass( 'col-lg-4' ); $('#edex_interest_balance').text(result[0].interest); $('#edex_total_balance_interest').text(result[0].totalbalance); $('#edex_total_interest_coincode').text(selected_coin); @@ -1139,11 +1211,19 @@ function edexCoinBtnAction() { } if ( result[0].interest === undefined ) { - $('#edexcoin_getbalance_interest').hide(); - $('#edexcoin_getbalance_total_interest').hide(); - $('#edexcoin_getbalance_t').removeClass( 'col-lg-4' ).addClass( 'col-lg-12' ); - $('#edex_interest_balance').text('-'); - $('#edex_total_balance_interest').text('-'); + $( + '#edexcoin_getbalance_interest,' + + '#edexcoin_getbalance_total_interest' + ) + .hide(); + $('#edexcoin_getbalance_t') + .removeClass( 'col-lg-4' ) + .addClass( 'col-lg-12' ); + $( + '#edex_interest_balance,' + + '#edex_total_balance_interest' + ) + .text('-'); } $('#edex_total_balance').text(result[0].total); @@ -1167,24 +1247,24 @@ function edexCoinBtnAction() { sessionStorage.setItem('edexTmpRefresh', 'start'); $( '#nav-zcash-wallet' ).trigger( 'click' ); } - if ( selected_coin == 'SUPERNET' - || selected_coin == 'REVS' - || selected_coin == 'REVS' - || selected_coin == 'DEX' - || selected_coin == 'PANGEA' - || selected_coin == 'JUMBLR' - || selected_coin == 'BET' - || selected_coin == 'CRYPTO' - || selected_coin == 'HODL' - || selected_coin == 'SHARK' - || selected_coin == 'BOTS' - || selected_coin == 'MGW' - || selected_coin == 'MVP' - || selected_coin == 'WIRELESS' - || selected_coin == 'KV' - || selected_coin == 'CEAL' - || selected_coin == 'MESH' - || selected_coin == 'USD' ) { + if ( selected_coin == 'SUPERNET' || + selected_coin == 'REVS' || + selected_coin == 'REVS' || + selected_coin == 'DEX' || + selected_coin == 'PANGEA' || + selected_coin == 'JUMBLR' || + selected_coin == 'BET' || + selected_coin == 'CRYPTO' || + selected_coin == 'HODL' || + selected_coin == 'SHARK' || + selected_coin == 'BOTS' || + selected_coin == 'MGW' || + selected_coin == 'MVP' || + selected_coin == 'WIRELESS' || + selected_coin == 'KV' || + selected_coin == 'CEAL' || + selected_coin == 'MESH' || + selected_coin == 'USD' ) { sessionStorage.setItem('edexTmpMode', selected_coinmode); sessionStorage.setItem('edexTmpRefresh', 'start'); assetchain_pax_menu_actions(selected_coin) diff --git a/assets/scripts/iguana_api.js b/assets/scripts/iguana_api.js index 8fce8d9..7eccad9 100644 --- a/assets/scripts/iguana_api.js +++ b/assets/scripts/iguana_api.js @@ -133,7 +133,7 @@ function Iguana_HashHex(data) { } function Iguana_SetRPCAuth() { - var tmpPass = md5(PassPhraseGenerator.generatePassPhrase(128)); + var tmpPass = 1234; // md5(PassPhraseGenerator.generatePassPhrase(128)); sessionStorage.setItem('IguanaRPCAuth', tmpPass); } diff --git a/assets/scripts/iguana_api/IguanaAddcoin.js b/assets/scripts/iguana_api/IguanaAddcoin.js index 1441100..7ec51d0 100644 --- a/assets/scripts/iguana_api/IguanaAddcoin.js +++ b/assets/scripts/iguana_api/IguanaAddcoin.js @@ -337,9 +337,9 @@ function Iguana_addcoin(addcoin_data) { var startcoin = function() { return new Promise(function(resolve, reject) { Shepherd_herd('komodod', { - 'ac_name': 'komodod', - 'ac_options': [ - '-daemon=0', + 'ac_name': 'komodod', + 'ac_options': [ + '-daemon=0', '-addnode=78.47.196.146' ] }); @@ -386,10 +386,10 @@ function Iguana_addcoin(addcoin_data) { var startcoin = function() { return new Promise(function(resolve, reject) { Shepherd_herd('zcashd', { - 'ac_name': 'zcashd', - 'ac_options': [ - '-daemon=0', - '-server=1' + 'ac_name': 'zcashd', + 'ac_options': [ + '-daemon=0', + '-server=1' ] }); var result = 'startcoin: DONE'; @@ -487,7 +487,7 @@ function Iguana_addcoin(addcoin_data) { 'ac_name': 'SUPERNET', 'ac_options': [ '-daemon=0', - '-server', + '-server', '-ac_name=SUPERNET', '-ac_supply=816061', '-addnode=78.47.196.146' diff --git a/assets/scripts/iguana_api/IguanaDEX.js b/assets/scripts/iguana_api/IguanaDEX.js index 1ee0d69..71b6e93 100644 --- a/assets/scripts/iguana_api/IguanaDEX.js +++ b/assets/scripts/iguana_api/IguanaDEX.js @@ -196,8 +196,11 @@ function Iguana_DEXImportAll() { }); ajax_call_1.done(function(data) { - $.each([ 'basilisk','full' ], function(data_index,data_value) { - $.each(data[data_value], function(mode_index,mode_value) { + $.each([ + 'basilisk', + 'full' + ], function(data_index, data_value) { + $.each(data[data_value], function(mode_index, mode_value) { var ajax_data_2 = { 'userpass': tmpIguanaRPCAuth, 'coin': mode_value, @@ -256,7 +259,7 @@ function Iguana_DEXImportAll() { }); ajax_call_5.done(function(data) { - console.log(mode_value) + console.log(mode_value); console.log(data); if (data == 'already in list') { @@ -391,7 +394,8 @@ function Iguana_DEXsendrawtx(data) { url: 'http://127.0.0.1:' + config.iguanaPort, type: 'POST', //dataType: 'json' - }).then(result => { + }) + .then(result => { console.log(result); resolve(result); }); @@ -427,7 +431,8 @@ function EDEX_DEXlistunspent(coin, addr) { toastr.error('Less than required responses. Please try again.', 'Basilisk Notification'); } resolve(AjaxOutputData); - }).fail(function(xhr, textStatus, error) { + }) + .fail(function(xhr, textStatus, error) { // handle request failures console.log(xhr.statusText); if ( xhr.readyState == 0 ) { @@ -523,7 +528,8 @@ function EDEX_DEXgetinfoAll() { var tmp_index = parseInt(coin_index) + 1, refresh_percent = parseFloat(parseInt(coin_index, 10) * 100) / parseInt(get_dex_notarychains.length, 10); - console.log(refresh_percent) + + console.log(refresh_percent); $('#basilisk-connections-refresh-title').text('Connection status... ' + tmp_index + '/' + get_dex_notarychains.length + ': ' + coin_value); $('#basilisk-connections-refresh-percent').text(refresh_percent + '%'); $('#basilisk-connections-refresh-progress-bar').width(refresh_percent + '%'); diff --git a/assets/scripts/kmd_wallet/KMDWalletDashboard.js b/assets/scripts/kmd_wallet/KMDWalletDashboard.js index f15bd5d..f038c68 100644 --- a/assets/scripts/kmd_wallet/KMDWalletDashboard.js +++ b/assets/scripts/kmd_wallet/KMDWalletDashboard.js @@ -113,7 +113,7 @@ var KMDWalletDashboard = function() { $('#kmd_wallet_total_value').text(total_minus_currency_fee.toFixed(8)); - if ($('#kmd_wallet_send_from').val() != '- Select Transparent or Private KMD Address -' && + if ($('#kmd_wallet_send_from').val() != '- ' + _lang[defaultLang].KMD_NATIVE.SELECT_ADDRESS_ALT + ' -' && $('#kmd_wallet_amount').val() != '' && $('#kmd_wallet_sendto') != '' && $('#kmd_wallet_fee') != '' ) { diff --git a/assets/scripts/lang/en.js b/assets/scripts/lang/en.js index 78f645e..0725a05 100644 --- a/assets/scripts/lang/en.js +++ b/assets/scripts/lang/en.js @@ -247,7 +247,8 @@ const _lang = { 'OUT': 'OUT', 'MINED': 'Mined', 'IMMATURE': 'Immature', - 'ZADDR_NOT_LISTED': 'Z Address not listed by wallet' + 'ZADDR_NOT_LISTED': 'Z Address not listed by wallet', + 'ADDR_COPIED': 'Address Copied' }, 'TOASTR': { 'WALLET_NOTIFICATION': 'Wallet Notification', diff --git a/assets/scripts/sidebar.js b/assets/scripts/sidebar.js index 7ee2161..43c4d12 100644 --- a/assets/scripts/sidebar.js +++ b/assets/scripts/sidebar.js @@ -1,584 +1,738 @@ // DOM Ready ============================================================= $(document).ready(function() { $('#section-dashboard').show(); - $('#section-easydex').hide(); - $('#section-jumblr').hide(); - $('#section-extcoin').hide(); - $('#section-zcash').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').hide(); - $('#section-about-iguana').hide(); - $('#nav-dashboard').removeClass( '' ).addClass( 'active open' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( 'active open' ).addClass( '' ); - $('#nav-komodo-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - $(".header-easydex-section").text(_lang[defaultLang].INDEX.DASHBOARD); - - removeKMDWalletStyle(); - removeZECWalletStyle(); - removeJumblrStyle(); - removeACPAXWalletStyle(); - CommonSidebarActionsSet01(); - applyDashboardStyle(); + $( + '#section-easydex,' + + '#section-jumblr,' + + '#section-extcoin,' + + '#section-zcash,' + + '#section-iguana-atomic-explorer,' + + '#section-iguana-wallet-settings,' + + '#section-about-iguana' + ) + .hide(); + $('#nav-dashboard') + .removeClass( '' ) + .addClass( 'active open' ); + $( + '#nav-easydex,' + + '#nav-jumblr,' + + '#nav-komodo-wallet,' + + '#nav-zcash-wallet,' + + '#nav-iguana-atomic-explorer,' + + '#nav-iguana-wallet-settings,' + + '#nav-about-iguana' + ) + .removeClass( 'active open' ) + .addClass( '' ); + $('.header-easydex-section').text(_lang[defaultLang].INDEX.DASHBOARD); + + removeKMDWalletStyle(); + removeZECWalletStyle(); + removeJumblrStyle(); + removeACPAXWalletStyle(); + CommonSidebarActionsSet01(); + applyDashboardStyle(); }); $('#nav-dashboard').on('click', function() { - $('#section-dashboard').show(); - var active_edexcoin = $('[data-edexcoin]').attr('data-edexcoin'); - if (active_edexcoin !== 'COIN') { - $('#header-dashboard').show(); - } - $('#section-easydex').hide(); - $('#section-jumblr').hide(); - $('#section-extcoin').hide(); - $('#section-zcash').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').hide(); - $('#section-about-iguana').hide(); - $('#nav-dashboard').removeClass( '' ).addClass( 'active open' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( 'active open' ).addClass( '' ); - $('#nav-komodo-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - $(".header-easydex-section").text(_lang[defaultLang].INDEX.DASHBOARD); - $.each($('.nav-top-menu'), function(index, value) { $(value).removeClass('active'); }); - $(this.parentElement).addClass('active'); - removeKMDWalletStyle(); - removeZECWalletStyle(); - removeJumblrStyle(); - removeACPAXWalletStyle(); - CommonSidebarActionsSet011(); - applyDashboardStyle(); + $('#section-dashboard').show(); + var active_edexcoin = $('[data-edexcoin]').attr('data-edexcoin'); + if (active_edexcoin !== 'COIN') { + $('#header-dashboard').show(); + } + $( + '#section-easydex,' + + '#section-jumblr,' + + '#section-extcoin,' + + '#section-zcash,' + + '#section-iguana-atomic-explorer,' + + '#section-iguana-wallet-settings,' + + '#section-about-iguana' + ) + .hide(); + $('#nav-dashboard') + .removeClass( '' ) + .addClass( 'active open' ); + $( + '#nav-easydex,' + + '#nav-jumblr,' + + '#nav-komodo-wallet,' + + '#nav-zcash-wallet,' + + '#nav-iguana-atomic-explorer,' + + '#nav-iguana-wallet-settings,' + + '#nav-about-iguana' + ) + .removeClass( 'active open' ) + .addClass( '' ); + $('.header-easydex-section').text(_lang[defaultLang].INDEX.DASHBOARD); + + $.each($('.nav-top-menu'), function(index, value) { $(value).removeClass('active'); }); + $(this.parentElement).addClass('active'); + removeKMDWalletStyle(); + removeZECWalletStyle(); + removeJumblrStyle(); + removeACPAXWalletStyle(); + CommonSidebarActionsSet011(); + applyDashboardStyle(); }); $('#nav-easydex').on('click', function() { - $('#section-dashboard').hide(); - $('#header-dashboard').hide(); - $('#section-easydex').show(); - $('#section-jumblr').hide(); - $('#section-extcoin').hide(); - $('#section-zcash').hide(); - $('#section-about-iguana').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').hide(); - $('#nav-dashboard').removeClass( 'active open' ).addClass( '' ); - $('#nav-easydex').removeClass( '' ).addClass( 'active open' ); - $('#nav-komodo-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - $('.page-header-bordered h1').text('EasyDEX'); - $(".header-easydex-section").text(_lang[defaultLang].SIDEBAR.EDEX_MOTTO); - $.each($('.nav-top-menu'), function(index, value) { $(value).removeClass('active'); }); - $(this.parentElement).addClass('active') - removeKMDWalletStyle(); - removeZECWalletStyle(); - removeJumblrStyle(); - removeACPAXWalletStyle(); - CommonSidebarActionsSet02(); - removeDashboardStyle(); + $( + '#header-dashboard,' + + '#section-dashboard,' + + '#section-jumblr,' + + '#section-extcoin,' + + '#section-zcash,' + + '#section-about-iguana,' + + '#section-iguana-atomic-explorer,' + + '#section-iguana-wallet-settings' + ) + .hide(); + $('#section-easydex').show(); + $('#nav-easydex') + .removeClass( '' ) + .addClass( 'active open' ); + $( + '#nav-dashboard,' + + '#nav-komodo-wallet,' + + '#nav-zcash-wallet,' + + '#nav-iguana-atomic-explorer,' + + '#nav-iguana-wallet-settings,' + + '#nav-about-iguana' + ) + .removeClass( 'active open' ) + .addClass( '' ); + $('.page-header-bordered h1').text('EasyDEX'); + $('.header-easydex-section').text(_lang[defaultLang].SIDEBAR.EDEX_MOTTO); + + $.each($('.nav-top-menu'), function(index, value) { $(value).removeClass('active'); }); + $(this.parentElement).addClass('active'); + removeKMDWalletStyle(); + removeZECWalletStyle(); + removeJumblrStyle(); + removeACPAXWalletStyle(); + CommonSidebarActionsSet02(); + removeDashboardStyle(); }); $('#nav-jumblr').on('click', function() { - $('#section-dashboard').hide(); - $('#header-dashboard').hide(); - $('#section-easydex').hide(); - $('#section-jumblr').show(); - $('#section-extcoin').hide(); - $('#section-zcash').hide(); - $('#section-about-iguana').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').hide(); - $('#nav-dashboard').removeClass( 'active open' ).addClass( '' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( '' ).addClass( 'active open' ); - $('#nav-komodo-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - $('.page-header-bordered h1').text('Jumblr') - //$(".header-easydex-section").text('Secure, Native and Decentralised Coin Shuffling'); - $.each($('.nav-top-menu'), function(index, value) { $(value).removeClass('active'); }); - $(this.parentElement).addClass('active') - removeKMDWalletStyle(); - removeZECWalletStyle(); - removeACPAXWalletStyle(); - CommonSidebarActionsSet02(); - removeDashboardStyle(); - applyJumblrStyle() + $( + '#header-dashboard,' + + '#section-dashboard,' + + '#section-easydex,' + + '#section-extcoin,' + + '#section-zcash,' + + '#section-about-iguana,' + + '#section-iguana-atomic-explorer,' + + '#section-iguana-wallet-settings' + ) + .hide(); + $('#section-jumblr').show(); + $( + '#nav-dashboard,' + + '#nav-easydex,' + + '#nav-komodo-wallet,' + + '#nav-zcash-wallet,' + + '#nav-iguana-atomic-explorer,' + + '#nav-iguana-wallet-settings,' + + '#nav-about-iguana' + ) + .removeClass( 'active open' ) + .addClass( '' ); + $('#nav-jumblr') + .removeClass( '' ) + .addClass( 'active open' ); + $('.page-header-bordered h1').text('Jumblr') + //$(".header-easydex-section").text('Secure, Native and Decentralised Coin Shuffling'); + + $.each($('.nav-top-menu'), function(index, value) { $(value).removeClass('active'); }); + $(this.parentElement).addClass('active'); + removeKMDWalletStyle(); + removeZECWalletStyle(); + removeACPAXWalletStyle(); + CommonSidebarActionsSet02(); + removeDashboardStyle(); + applyJumblrStyle() }); $('#nav-komodo-wallet').on('click', function() { - $('#section-dashboard').hide(); - $('#header-dashboard').hide(); - $('#section-easydex').hide(); - $('#section-jumblr').hide(); - $('#section-extcoin').show(); - $('#section-zcash').hide(); - $('#section-about-iguana').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').hide(); - $('#nav-dashboard').removeClass( 'active open' ).addClass( '' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( 'active open' ).addClass( '' ); - $('#nav-komodo-wallet').removeClass( '' ).addClass( 'active open' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - - $.each($('[data-extcoin]'), function(index, value) { - $('[data-extcoin]').attr('data-extcoin', 'KMD'); - $('[data-extcoin="KMD"]'); - }); - $.each($('[data-extcoinname]'), function(index, value) { - $('[data-extcoinname]').text('KMD'); - $('[data-extcoinname="KMD"]'); - }); - $.each($('[data-extcointitle]'), function(index, value) { - $('[data-extcointitle]').text('Komodo'); - $('[data-extcointitle="Komodo"]'); - }); - KMDWalletDashboard.init(); // Initiate Komodo Dashboard sript - RunKMDInitFunctions(); - removeJumblrStyle(); - removeACPAXWalletStyle(); - // removeZECWalletStyle(); - applyKMDWalletStyle(); - CommonSidebarActionsSet02(); - removeDashboardStyle(); + $( + '#header-dashboard,' + + '#section-dashboard,' + + '#section-easydex,' + + '#section-jumblr,' + + '#section-zcash,' + + '#section-about-iguana,' + + '#section-iguana-atomic-explorer,' + + '#section-iguana-wallet-settings' + ) + .hide(); + $('#section-extcoin').show(); + $( + '#nav-dashboard,' + + '#nav-easydex,' + + '#nav-jumblr,' + + '#nav-zcash-wallet,' + + '#nav-iguana-atomic-explorer,' + + '#nav-iguana-wallet-settings,' + + '#nav-about-iguana' + ) + .removeClass( 'active open' ) + .addClass( '' ); + $('#nav-komodo-wallet') + .removeClass( '' ) + .addClass( 'active open' ); + + $.each($('[data-extcoin]'), function(index, value) { + $('[data-extcoin]').attr('data-extcoin', 'KMD'); + $('[data-extcoin="KMD"]'); + }); + $.each($('[data-extcoinname]'), function(index, value) { + $('[data-extcoinname]').text('KMD'); + $('[data-extcoinname="KMD"]'); + }); + $.each($('[data-extcointitle]'), function(index, value) { + $('[data-extcointitle]').text('Komodo'); + $('[data-extcointitle="Komodo"]'); + }); + KMDWalletDashboard.init(); // Initiate Komodo Dashboard sript + RunKMDInitFunctions(); + removeJumblrStyle(); + removeACPAXWalletStyle(); + // removeZECWalletStyle(); + applyKMDWalletStyle(); + CommonSidebarActionsSet02(); + removeDashboardStyle(); }); $('#nav-zcash-wallet').on('click', function() { - NProgress.done(true); - NProgress.configure({ - template: '
' + - '
' + - '
' + - '
' - }); - NProgress.start(); - $('#section-dashboard').hide(); - $('#header-dashboard').hide(); - $('#section-easydex').hide(); - $('#section-jumblr').hide(); - $('#section-extcoin').hide(); - // $('#section-zcash').show(); - $('#section-extcoin').show(); - $('#section-about-iguana').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').hide(); - $('#nav-dashboard').removeClass( 'active open' ).addClass( '' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( 'active open' ).addClass( '' ); - $('#nav-komodo-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-zcash-wallet').removeClass( '' ).addClass( 'active open' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - $(".header-easydex-section").text(_lang[defaultLang].INDEX.ZC_WALLET); - - $.each($('[data-extcoin]'), function(index, value) { - $('[data-extcoin]').attr('data-extcoin', 'ZEC'); - $('[data-extcoin="ZEC"]'); - }); - $.each($('[data-extcoinname]'), function(index, value) { - $('[data-extcoinname]').text('ZEC'); - $('[data-extcoinname="ZEC"]'); - }); - $.each($('[data-extcointitle]'), function(index, value) { - $('[data-extcointitle]').text('Zcash'); - $('[data-extcointitle="Zcash"]'); - }); - - KMDWalletDashboard.init(); // Initiate Komodo Dashbaord sript - RunKMDInitFunctions(); - //removeKMDWalletStyle(); - applyZECWalletStyle(); - CommonSidebarActionsSet02(); - removeDashboardStyle(); - NProgress.done(); + NProgress.done(true); + NProgress.configure({ + template: '
' + + '
' + + '
' + + '
' + }); + NProgress.start(); + $( + '#header-dashboard,' + + '#section-dashboard,' + + '#section-easydex,' + + '#section-jumblr,' + + '#section-extcoin,' + + '#section-about-iguana,' + + '#section-iguana-atomic-explorer,' + + '#section-iguana-wallet-settings' + ) + .hide(); + // $('#section-zcash').show(); + $('#section-extcoin').show(); + $( + '#nav-dashboard,' + + '#nav-easydex,' + + '#nav-jumblr,' + + '#nav-komodo-wallet,' + + '#nav-iguana-atomic-explorer,' + + '#nav-iguana-wallet-settings,' + + '#nav-about-iguana' + ) + .removeClass( 'active open' ) + .addClass( '' ); + $('#nav-zcash-wallet') + .removeClass( '' ) + .addClass( 'active open' ); + $('.header-easydex-section').text(_lang[defaultLang].INDEX.ZC_WALLET); + + $.each($('[data-extcoin]'), function(index, value) { + $('[data-extcoin]').attr('data-extcoin', 'ZEC'); + $('[data-extcoin="ZEC"]'); + }); + $.each($('[data-extcoinname]'), function(index, value) { + $('[data-extcoinname]').text('ZEC'); + $('[data-extcoinname="ZEC"]'); + }); + $.each($('[data-extcointitle]'), function(index, value) { + $('[data-extcointitle]').text('Zcash'); + $('[data-extcointitle="Zcash"]'); + }); + + KMDWalletDashboard.init(); // Initiate Komodo Dashbaord sript + RunKMDInitFunctions(); + //removeKMDWalletStyle(); + applyZECWalletStyle(); + CommonSidebarActionsSet02(); + removeDashboardStyle(); + NProgress.done(); }); $('#nav-iguana-atomic-explorer').on('click', function() { - $('#section-dashboard').hide(); - $('#header-dashboard').hide(); - $('#section-easydex').hide(); - $('#section-jumblr').hide(); - $('#section-extcoin').hide(); - $('#section-zcash').hide(); - $('#section-iguana-atomic-explorer').show(); - $('#section-iguana-wallet-settings').hide(); - $('#section-about-iguana').hide(); - $('#nav-dashboard').removeClass( 'active open' ).addClass( '' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( 'active open' ).addClass( '' ); - $('#nav-komodo-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( '' ).addClass( 'active open' ); - $(".header-easydex-section").text('Atomic Explorer'); - $.each($('.nav-top-menu'), function(index, value) { $(value).removeClass('active'); }); - $(this.parentElement).addClass('active'); - removeKMDWalletStyle(); - removeZECWalletStyle(); - removeJumblrStyle(); - removeACPAXWalletStyle(); - CommonSidebarActionsSet02(); - removeDashboardStyle(); - $('#easydex-header-div').hide(); + $( + '#header-dashboard,' + + '#section-dashboard,' + + '#section-easydex,' + + '#section-jumblr,' + + '#section-extcoin,' + + '#section-zcash,' + + '#section-iguana-wallet-settings,' + + '#section-about-iguana' + ) + .hide(); + $('#section-iguana-atomic-explorer').show(); + $( + '#nav-dashboard,' + + '#nav-easydex,' + + '#nav-jumblr,' + + '#nav-komodo-wallet,' + + '#nav-zcash-wallet,' + + '#nav-about-iguana,' + + '#nav-iguana-wallet-settings' + ) + .removeClass( 'active open' ) + .addClass( '' ); + $('#nav-iguana-atomic-explorer') + .removeClass( '' ) + .addClass( 'active open' ); + $('.header-easydex-section').text('Atomic Explorer'); + + $.each($('.nav-top-menu'), function(index, value) { $(value).removeClass('active'); }); + $(this.parentElement).addClass('active'); + removeKMDWalletStyle(); + removeZECWalletStyle(); + removeJumblrStyle(); + removeACPAXWalletStyle(); + CommonSidebarActionsSet02(); + removeDashboardStyle(); + $('#easydex-header-div').hide(); }); $('#nav-iguana-wallet-settings').on('click', function() { - $('#section-dashboard').hide(); - $('#header-dashboard').hide(); - $('#section-easydex').hide(); - $('#section-jumblr').hide(); - $('#section-extcoin').hide(); - $('#section-zcash').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').show(); - $('#section-about-iguana').hide(); - $('#nav-dashboard').removeClass( 'active open' ).addClass( '' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( 'active open' ).addClass( '' ); - $('#nav-komodo-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( '' ).addClass( 'active open' ); - // $(".header-easydex-section").text("Wallet Settings"); - removeKMDWalletStyle(); - removeZECWalletStyle(); - removeJumblrStyle(); - removeACPAXWalletStyle(); - Settings_ShowWalletInfo(); // Execute this function from walletsettings.js file - CommonSidebarActionsSet02(); - removeDashboardStyle(); - $('#easydex-header-div').hide(); + $( + '#section-dashboard,' + + '#header-dashboard,' + + '#section-easydex,' + + '#section-jumblr,' + + '#section-extcoin,' + + '#section-zcash,' + + '#section-iguana-atomic-explorer,' + + '#section-about-iguana' + ) + .hide(); + $('#section-iguana-wallet-settings').show(); + $( + '#nav-dashboard,' + + '#nav-easydex,' + + '#nav-jumblr,' + + '#nav-komodo-wallet,' + + '#nav-zcash-wallet,' + + '#nav-about-iguana,' + + '#nav-iguana-atomic-explorer' + ) + .removeClass( 'active open' ).addClass( '' ); + $('#nav-iguana-wallet-settings') + .removeClass( '' ) + .addClass( 'active open' ); + // $(".header-easydex-section").text("Wallet Settings"); + removeKMDWalletStyle(); + removeZECWalletStyle(); + removeJumblrStyle(); + removeACPAXWalletStyle(); + Settings_ShowWalletInfo(); // Execute this function from walletsettings.js file + CommonSidebarActionsSet02(); + removeDashboardStyle(); + $('#easydex-header-div').hide(); }); $('#nav-about-iguana').on('click', function() { - $('#section-dashboard').hide(); - $('#header-dashboard').hide(); - $('#section-easydex').hide(); - $('#section-jumblr').hide(); - $('#section-extcoin').hide(); - $('#section-zcash').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').hide(); - $('#section-about-iguana').show(); - $('#nav-dashboard').removeClass( 'active open' ).addClass( '' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( 'active open' ).addClass( '' ); - $('#nav-komodo-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( '' ).addClass( 'active open' ); - $(".header-easydex-section").text('About Iguana'); - removeKMDWalletStyle(); - removeZECWalletStyle(); - removeJumblrStyle(); - removeACPAXWalletStyle(); - CommonSidebarActionsSet02(); - removeDashboardStyle(); - $('#easydex-header-div').hide(); + $( + '#header-dashboard,' + + '#section-dashboard,' + + '#section-easydex,' + + '#section-jumblr,' + + '#section-extcoin,' + + '#section-zcash,' + + '#section-iguana-atomic-explorer,' + + '#section-iguana-wallet-settings' + ) + .hide(); + $('#section-about-iguana').show(); + $( + '#nav-dashboard,' + + '#nav-easydex,' + + '#nav-jumblr,' + + '#nav-komodo-wallet,' + + '#nav-zcash-wallet,' + + '#nav-iguana-atomic-explorer,' + + '#nav-iguana-wallet-settings' + ) + .removeClass( 'active open' ) + .addClass( '' ); + $('#nav-about-iguana') + .removeClass( '' ) + .addClass( 'active open' ); + $('.header-easydex-section').text('About Iguana'); + removeKMDWalletStyle(); + removeZECWalletStyle(); + removeJumblrStyle(); + removeACPAXWalletStyle(); + CommonSidebarActionsSet02(); + removeDashboardStyle(); + $('#easydex-header-div').hide(); }); - // ASSETCHAINS AND PAXCHAINS SIDE MENU function assetchain_pax_menu_actions(coin) { - $('#section-dashboard').hide(); - $('#header-dashboard').hide(); - $('#section-easydex').hide(); - $('#section-jumblr').hide(); - $('#section-extcoin').show(); - $('#section-zcash').hide(); - $('#section-about-iguana').hide(); - $('#section-iguana-atomic-explorer').hide(); - $('#section-iguana-wallet-settings').hide(); - $('#nav-dashboard').removeClass( 'active open' ).addClass( '' ); - $('#nav-easydex').removeClass( 'active open' ).addClass( '' ); - $('#nav-jumblr').removeClass( 'active open' ).addClass( '' ); - $('#nav-komodo-wallet').removeClass( '' ).addClass( 'active open' ); - $('#nav-zcash-wallet').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-atomic-explorer').removeClass( 'active open' ).addClass( '' ); - $('#nav-iguana-wallet-settings').removeClass( 'active open' ).addClass( '' ); - $('#nav-about-iguana').removeClass( 'active open' ).addClass( '' ); - - $.each($('[data-extcoin]'), function(index, value) { - $('[data-extcoin]').attr('data-extcoin', coin); - $('[data-extcoin='+coin+']'); - }); - $.each($('[data-extcoinname]'), function(index, value) { - $('[data-extcoinname]').text(coin); - $('[data-extcoinname='+coin+']'); - }); - $.each($('[data-extcointitle]'), function(index, value) { - $('[data-extcointitle]').text(coin); - $('[data-extcointitle='+coin+']'); - }); - KMDWalletDashboard.init(); // Initiate Komodo Dashboard sript - RunKMDInitFunctions(); - removeJumblrStyle(); - removeACPAXWalletStyle(); - //removeZECWalletStyle(); - //applyKMDWalletStyle(); - applyACPAXWalletStyle() - CommonSidebarActionsSet02(); - removeDashboardStyle(); + $( + '#header-dashboard,' + + '#section-dashboard,' + + '#section-easydex,' + + '#section-jumblr,' + + '#section-zcash,' + + '#section-about-iguana,' + + '#section-iguana-atomic-explorer,' + + '#section-iguana-wallet-settings' + ) + .hide(); + $('#section-extcoin').show(); + $('#nav-komodo-wallet') + .removeClass( '' ) + .addClass( 'active open' ); + $( + '#nav-dashboard,' + + '#nav-easydex,' + + '#nav-jumblr,' + + '#nav-zcash-wallet,' + + '#nav-iguana-atomic-explorer,' + + '#nav-iguana-wallet-settings,' + + '#nav-about-iguana' + ) + .removeClass( 'active open' ) + .addClass( '' ); + + $.each($('[data-extcoin]'), function(index, value) { + $('[data-extcoin]').attr('data-extcoin', coin); + $('[data-extcoin=' + coin + ']'); + }); + $.each($('[data-extcoinname]'), function(index, value) { + $('[data-extcoinname]').text(coin); + $('[data-extcoinname=' + coin + ']'); + }); + $.each($('[data-extcointitle]'), function(index, value) { + $('[data-extcointitle]').text(coin); + $('[data-extcointitle=' + coin + ']'); + }); + + KMDWalletDashboard.init(); // Initiate Komodo Dashboard sript + RunKMDInitFunctions(); + removeJumblrStyle(); + removeACPAXWalletStyle(); + //removeZECWalletStyle(); + //applyKMDWalletStyle(); + applyACPAXWalletStyle() + CommonSidebarActionsSet02(); + removeDashboardStyle(); switch (coin) { - case 'SUPERNET': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - break; - case 'REVS': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - $('#easydex-header-div').css(); - break; - case 'WIRELESS': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/wireless_transparent_header_bg.png")'); - break; - case 'PANGEA': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - break; - case 'DEX': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - break; - case 'JUMBLR': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - $('#easydex-header-div').css(); - break; - case 'BET': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/wireless_transparent_header_bg.png")'); - break; - case 'CRYPTO': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - break; - case 'HODL': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - $('#easydex-header-div').css(); - break; - case 'SHARK': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/wireless_transparent_header_bg.png")'); - break; - case 'BOTS': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - break; - case 'MGW': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - $('#easydex-header-div').css(); - break; - case 'MVP': - $('.header-easydex-section').html(''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/mvp_transparent_header_bg.png")'); - break; - case 'KV': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - break; - case 'CEAL': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/ceal_transparent_header_bg.png")'); - $('#easydex-header-div').css(); - break; - case 'MESH': - $('.header-easydex-section').html(''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/mesh_transparent_header_bg.png")'); - break; - - case 'USD': - $('.header-easydex-section').html(' '+ coin + ''); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/usd_transparent_header_bg.png")'); - break; - default: - $('.header-easydex-section').html(''+ coin + ''); - } + case 'SUPERNET': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + break; + case 'REVS': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + $('#easydex-header-div').css(); + break; + case 'WIRELESS': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/wireless_transparent_header_bg.png")'); + break; + case 'PANGEA': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + break; + case 'DEX': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + break; + case 'JUMBLR': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + $('#easydex-header-div').css(); + break; + case 'BET': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/wireless_transparent_header_bg.png")'); + break; + case 'CRYPTO': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + break; + case 'HODL': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + $('#easydex-header-div').css(); + break; + case 'SHARK': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/wireless_transparent_header_bg.png")'); + break; + case 'BOTS': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + break; + case 'MGW': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + $('#easydex-header-div').css(); + break; + case 'MVP': + $('.header-easydex-section').html(''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/mvp_transparent_header_bg.png")'); + break; + case 'KV': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); + break; + case 'CEAL': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/ceal_transparent_header_bg.png")'); + $('#easydex-header-div').css(); + break; + case 'MESH': + $('.header-easydex-section').html(''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/mesh_transparent_header_bg.png")'); + break; + case 'USD': + $('.header-easydex-section') + .html(' ' + coin + ''); + $('#easydex-header-div').css('background-image', 'url("assets/images/bg/usd_transparent_header_bg.png")'); + break; + default: + $('.header-easydex-section').html(''+ coin + ''); + break; + } } // END ASSETCHAINS AND PAXCHAINS SIDE MENU function CommonSidebarActionsSet01() { - sessionStorage.setItem('DashboardActions', 'start'); - sessionStorage.setItem('NativeWalletActions', 'stop'); - // $(document).ready(function() { Dashboard.init(); }); - $("#wifkeys_passphrase").val(''); - $('#wif-priv-keys').html(''); + sessionStorage.setItem('DashboardActions', 'start'); + sessionStorage.setItem('NativeWalletActions', 'stop'); + // $(document).ready(function() { Dashboard.init(); }); + $('#wifkeys_passphrase').val(''); + $('#wif-priv-keys').html(''); } function CommonSidebarActionsSet011() { - sessionStorage.setItem('DashboardActions', 'start'); - sessionStorage.setItem('NativeWalletActions', 'stop'); - // location.reload(); - $("#wifkeys_passphrase").val(''); - $('#wif-priv-keys').html(''); + sessionStorage.setItem('DashboardActions', 'start'); + sessionStorage.setItem('NativeWalletActions', 'stop'); + // location.reload(); + $('#wifkeys_passphrase').val(''); + $('#wif-priv-keys').html(''); } function CommonSidebarActionsSet02() { - sessionStorage.setItem('DashboardActions', 'stop'); - $("#wifkeys_passphrase").val(''); - $('#wif-priv-keys').html(''); + sessionStorage.setItem('DashboardActions', 'stop'); + $('#wifkeys_passphrase').val(''); + $('#wif-priv-keys').html(''); } function applyKMDWalletStyle() { - $('.header-easydex-section').html(''); - $('.page-title').hide(); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/kmd_transparent_header_bg.png")'); - $('#easydex-header-div').css('background-repeat', 'no-repeat'); - $('#easydex-header-div').css('background-position', '0%'); - $('#easydex_acpax_wallet_actions_header').hide(); - $('#easydex_kmd_wallet_actions_header').show(); - $('#easydex_zec_wallet_actions_header').hide(); - $('#jumblr_actions_header').hide(); - $('#easydex_btc_btcd_balances_header').hide(); - sessionStorage.setItem('NativeWalletActions', 'start'); - getTotalKMDBalance(); + $('.header-easydex-section').html(''); + $('.page-title').hide(); + $('#easydex-header-div').css({ + 'background-image': 'url("assets/images/bg/kmd_transparent_header_bg.png")', + 'background-repeat': 'no-repeat', + 'background-position': '0%' + }); + $( + '#easydex_acpax_wallet_actions_header,' + + '#easydex_kmd_wallet_actions_header,' + + '#easydex_zec_wallet_actions_header,' + + '#jumblr_actions_header,' + + '#easydex_btc_btcd_balances_header' + ) + .hide(); + sessionStorage.setItem('NativeWalletActions', 'start'); + getTotalKMDBalance(); } function removeKMDWalletStyle() { - $('.page-title').show(); - $('#easydex-header-div').removeAttr( 'style' ); - $('#easydex_acpax_wallet_actions_header').hide(); - $('#easydex_kmd_wallet_actions_header').hide(); - $('#easydex_zec_wallet_actions_header').hide(); - $('#jumblr_actions_header').hide(); - $('#easydex_btc_btcd_balances_header').hide(); - sessionStorage.setItem('NativeWalletActions', 'stop'); + $('.page-title').show(); + $('#easydex-header-div').removeAttr( 'style' ); + $( + '#easydex_acpax_wallet_actions_header,' + + '#easydex_kmd_wallet_actions_header,' + + '#easydex_zec_wallet_actions_header,' + + '#jumblr_actions_header,' + + '#easydex_btc_btcd_balances_header' + ) + .hide(); + sessionStorage.setItem('NativeWalletActions', 'stop'); } function applyZECWalletStyle() { - $('.header-easydex-section').html(''); - $('.page-title').hide(); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/zec_transparent_header_bg.png")'); - $('#easydex-header-div').css('background-repeat', 'no-repeat'); - $('#easydex-header-div').css('background-position', '0%'); - $('#easydex_acpax_wallet_actions_header').hide(); - $('#easydex_kmd_wallet_actions_header').hide(); - $('#easydex_zec_wallet_actions_header').show(); - $('#jumblr_actions_header').hide(); - $('#easydex_btc_btcd_balances_header').hide(); - sessionStorage.setItem('NativeWalletActions', 'start'); - getTotalKMDBalance(); + $('.header-easydex-section').html(''); + $('.page-title').hide(); + $('#easydex-header-div').css({ + 'background-image': 'url("assets/images/bg/zec_transparent_header_bg.png")', + 'background-repeat': 'no-repeat', + 'background-position': '0%' + }); + $('#easydex_zec_wallet_actions_header').show(); + $( + '#easydex_acpax_wallet_actions_header,' + + '#easydex_kmd_wallet_actions_header,' + + '#jumblr_actions_header,' + + '#easydex_btc_btcd_balances_header' + ) + .hide(); + sessionStorage.setItem('NativeWalletActions', 'start'); + getTotalKMDBalance(); } function removeZECWalletStyle() { - $('.page-title').show(); - $('#easydex-header-div').removeAttr( 'style' ); - $('#easydex_acpax_wallet_actions_header').hide(); - $('#easydex_kmd_wallet_actions_header').hide(); - $('#easydex_zec_wallet_actions_header').hide(); - $('#jumblr_actions_header').hide(); - $('#easydex_btc_btcd_balances_header').hide(); - sessionStorage.setItem('NativeWalletActions', 'stop'); + $('.page-title').show(); + $('#easydex-header-div').removeAttr( 'style' ); + $( + '#easydex_acpax_wallet_actions_header,' + + '#easydex_kmd_wallet_actions_header,' + + '#easydex_zec_wallet_actions_header,' + + '#jumblr_actions_header,' + + '#easydex_btc_btcd_balances_header' + ) + .hide(); + sessionStorage.setItem('NativeWalletActions', 'stop'); } function applyJumblrStyle() { - $('.header-easydex-section').html('
' + _lang[defaultLang].SIDEBAR.JUMBLR_MOTTO); - $('.page-title').hide(); - $('#easydex-header-div').css('background-image', 'url("assets/images/bg/jumblr_transparent_header_bg.png")'); - $('#easydex-header-div').css('background-repeat', 'no-repeat'); - $('#easydex-header-div').css('background-position', '0%'); - $('#easydex_acpax_wallet_actions_header').hide(); - $('#easydex_kmd_wallet_actions_header').hide(); - $('#easydex_zec_wallet_actions_header').hide(); - $('#jumblr_actions_header').show(); - $('#easydex_btc_btcd_balances_header').hide(); - sessionStorage.setItem('NativeWalletActions', 'start'); + $('.header-easydex-section').html('
' + _lang[defaultLang].SIDEBAR.JUMBLR_MOTTO); + $('.page-title').hide(); + $('#easydex-header-div').css({ + 'background-image': 'url("assets/images/bg/jumblr_transparent_header_bg.png")', + 'background-repeat': 'no-repeat', + 'background-position': '0%' + }); + $( + '#easydex_acpax_wallet_actions_header,' + + '#easydex_kmd_wallet_actions_header,' + + '#easydex_zec_wallet_actions_header,' + + '#easydex_btc_btcd_balances_header' + ) + .hide(); + $('#jumblr_actions_header').show(); + sessionStorage.setItem('NativeWalletActions', 'start'); } function removeJumblrStyle() { - $('.page-title').show(); - $('#easydex-header-div').removeAttr( 'style' ); - $('#easydex_acpax_wallet_actions_header').hide(); - $('#easydex_kmd_wallet_actions_header').hide(); - $('#easydex_zec_wallet_actions_header').hide(); - $('#jumblr_actions_header').hide(); - $('#easydex_btc_btcd_balances_header').hide(); - sessionStorage.setItem('NativeWalletActions', 'stop'); + $('.page-title').show(); + $('#easydex-header-div').removeAttr( 'style' ); + $( + '#easydex_acpax_wallet_actions_header,' + + '#easydex_kmd_wallet_actions_header,' + + '#jumblr_actions_header,' + + '#easydex_btc_btcd_balances_header' + ) + .hide(); + sessionStorage.setItem('NativeWalletActions', 'stop'); } function applyACPAXWalletStyle() { - $('.page-title').hide(); - $('#easydex-header-div').css('background-repeat', 'no-repeat'); - $('#easydex-header-div').css('background-position', '0%'); - $('#easydex_acpax_wallet_actions_header').show(); - $('#easydex_kmd_wallet_actions_header').hide(); - $('#easydex_zec_wallet_actions_header').hide(); - $('#jumblr_actions_header').hide(); - $('#easydex_btc_btcd_balances_header').hide(); - sessionStorage.setItem('NativeWalletActions', 'start'); - getTotalKMDBalance(); + $('.page-title').hide(); + $('#easydex-header-div').css({ + 'background-repeat': 'no-repeat', + 'background-position': '0%' + }); + $('#easydex_acpax_wallet_actions_header').show(); + $( + '#easydex_kmd_wallet_actions_header,' + + '#easydex_zec_wallet_actions_header,' + + '#jumblr_actions_header,' + + '#easydex_btc_btcd_balances_header' + ) + .hide(); + sessionStorage.setItem('NativeWalletActions', 'start'); + getTotalKMDBalance(); } function removeACPAXWalletStyle() { - $('.page-title').show(); - $('#easydex-header-div').removeAttr( 'style' ); - $('#easydex_acpax_wallet_actions_header').hide(); - $('#easydex_kmd_wallet_actions_header').hide(); - $('#easydex_zec_wallet_actions_header').hide(); - $('#jumblr_actions_header').hide(); - $('#easydex_btc_btcd_balances_header').hide(); - sessionStorage.setItem('NativeWalletActions', 'stop'); + $('.page-title').show(); + $('#easydex-header-div').removeAttr( 'style' ); + $( + '#easydex_acpax_wallet_actions_header,' + + '#easydex_kmd_wallet_actions_header,' + + '#easydex_zec_wallet_actions_header,' + + '#jumblr_actions_header,' + + '#easydex_btc_btcd_balances_header' + ) + .hide(); + sessionStorage.setItem('NativeWalletActions', 'stop'); } function applyDashboardStyle() { - $('.page-aside').show(); - $('.page-main').show(); - /* set default map height */ - var navbarH = $('.site-navbar').outerHeight(), - footerH = $('.site-footer').outerHeight(), - mapH = $(window).height() - navbarH - footerH; - $('.page-main').outerHeight(mapH); - $('#easydex-header-div').hide(); - var active_edexcoinmodecode = sessionStorage.getItem('edexTmpMode'); - console.log(active_edexcoinmodecode); - if (active_edexcoinmodecode == 'Basilisk') { - $('#edex-footer').hide(); - } else { - $('#edex-footer').show(); - } - - setTimeout(function() { - var active_edexcoin = $('[data-edexcoin]').attr('data-edexcoin'); - console.log(active_edexcoin) - if (active_edexcoin == 'COIN') { - var basiliskCoins = $('.page-aside .wallet-widgets-list .list-group .list-group-item .widget-content[data-edexcoinmodecode="Basilisk"] a'); - if (basiliskCoins && basiliskCoins.length) { - $('.page-aside .wallet-widgets-list .list-group .list-group-item .widget-content[data-edexcoinmodecode="Basilisk"] a')[0].click(); - } else { - $('.page-aside .wallet-widgets-list .list-group .list-group-item .widget-content[data-edexcoinmodecode="Full"] a')[0].click(); - } - } - }, 1000); + $( + '.page-aside,' + + '.page-main' + ) + .show(); + /* set default map height */ + var navbarH = $('.site-navbar').outerHeight(), + footerH = $('.site-footer').outerHeight(), + mapH = $(window).height() - navbarH - footerH; + + $('.page-main').outerHeight(mapH); + $('#easydex-header-div').hide(); + + var active_edexcoinmodecode = sessionStorage.getItem('edexTmpMode'); + console.log(active_edexcoinmodecode); + + if (active_edexcoinmodecode == 'Basilisk') { + $('#edex-footer').hide(); + } else { + $('#edex-footer').show(); + } + + setTimeout(function() { + var active_edexcoin = $('[data-edexcoin]').attr('data-edexcoin'); + console.log(active_edexcoin); + + if (active_edexcoin == 'COIN') { + var basiliskCoins = $('.page-aside .wallet-widgets-list .list-group .list-group-item .widget-content[data-edexcoinmodecode="Basilisk"] a'); + + if (basiliskCoins && basiliskCoins.length) { + basiliskCoins[0].click(); + } else { + var fullCoins = $('.page-aside .wallet-widgets-list .list-group .list-group-item .widget-content[data-edexcoinmodecode="Full"] a'); + + if (fullCoins && fullCoins.length) { + fullCoins[0].click(); + } + } + } + }, 1000); } function removeDashboardStyle() { - $('.page-aside').hide(); - $(".page-main").hide(); - $('#easydex-header-div').show(); - $('#edex-footer').hide(); + $( + '.page-aside,' + + '.page-main' + ) + .hide(); + $('#easydex-header-div').show(); + $('#edex-footer').hide(); } \ No newline at end of file