Skip to content

Commit e3dcc72

Browse files
committed
Just a little Theme refresh :)
1 parent 0bf606f commit e3dcc72

File tree

151 files changed

+8797
-3145
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

151 files changed

+8797
-3145
lines changed

include/config/admin_settings.inc.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,13 @@
238238
'name' => 'statistics_analytics_code', 'value' => $setting->getValue('statistics_analytics_code'),
239239
'tooltip' => '.'
240240
);
241+
$aSettings['acl'][] = array(
242+
'display' => 'Show Menu for logged in users only', 'type' => 'select',
243+
'options' => array( 0 => 'No', 1 => 'Yes' ),
244+
'default' => 0,
245+
'name' => 'acl_show_menu_loggedin', 'value' => $setting->getValue('acl_show_menu_loggedin'),
246+
'tooltip' => 'Should Menu be visible for logged in users only.'
247+
);
241248
$aSettings['acl'][] = array(
242249
'display' => 'Show Stats for logged in users only', 'type' => 'select',
243250
'options' => array( 0 => 'No', 1 => 'Yes' ),

include/pages/api/getdashboarddata.inc.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,9 @@
8484
$iBlocksUntilDiffChange = $statistics->getBlocksUntilDiffChange();
8585

8686
// Block statistics
87+
$now = new DateTime( "now" );
88+
$aLastBlock = $block->getLast();
89+
$dTimeSinceLast = ($now->getTimestamp() - $aLastBlock['time']);
8790
$aLastBlocks = $statistics->getBlocksFound(5);
8891
if (!$user->isAdmin(@$_SESSION['USERDATA']['id'])) {
8992
foreach ($aLastBlocks as $key => $data) {
@@ -107,6 +110,7 @@
107110
'currency' => $config['currency']
108111
),
109112
'esttimeperblock' => round($dPoolExpectedTimePerBlock, 2),
113+
'timesincelastblock' => round($dTimeSinceLast, 2),
110114
'blocks' => $aLastBlocks,
111115
'workers' => $worker->getCountAllActiveWorkers(), 'hashrate' => $dPoolHashrateAdjusted,
112116
'shares' => array( 'valid' => $aRoundShares['valid'], 'invalid' => $aRoundShares['invalid'], 'invalid_percent' => $dPoolInvalidPercent, 'estimated' => $iEstShares, 'progress' => $dEstPercent ),

include/pages/dashboard.inc.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@
3838
$iBlocksUntilDiffChange = $statistics->getBlocksUntilDiffChange();
3939

4040
// Block statistics
41+
$now = new DateTime( "now" );
42+
$aLastBlock = $block->getLast();
43+
$dTimeSinceLast = ($now->getTimestamp() - $aLastBlock['time']);
4144
$aLastBlocks = $statistics->getBlocksFound(5);
4245
if (!$user->isAdmin(@$_SESSION['USERDATA']['id'])) {
4346
foreach ($aLastBlocks as $key => $data) {
@@ -50,6 +53,7 @@
5053

5154
// Make it available in Smarty
5255
$smarty->assign('PRECISION', $coin->getCoinValuePrevision());
56+
$smarty->assign('LASTBLOCKTIME', $dTimeSinceLast);
5357
$smarty->assign('BLOCKSFOUND', $aLastBlocks);
5458
$smarty->assign('DISABLED_DASHBOARD', $setting->getValue('disable_dashboard'));
5559
$smarty->assign('DISABLED_DASHBOARD_API', $setting->getValue('disable_dashboard_api'));

include/smarty_globals.inc.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@
129129
$aGlobal['statistics']['analytics']['code'] = $setting->getValue('statistics_analytics_code');
130130

131131
// ACLs
132+
$aGlobal['acl']['menu']['loggedin'] = $setting->getValue('acl_show_menu_loggedin');
132133
$aGlobal['acl']['statistics']['loggedin'] = $setting->getValue('acl_show_stats_loggedin');
133134
$aGlobal['acl']['help']['loggedin'] = $setting->getValue('acl_show_help_loggedin');
134135
$aGlobal['acl']['pool']['statistics'] = $setting->getValue('acl_pool_statistics');

0 commit comments

Comments
 (0)