mirror of
https://github.com/LBRYFoundation/pool.git
synced 2025-08-23 17:37:25 +00:00
57 lines
2 KiB
PHP
57 lines
2 KiB
PHP
<?php
|
|
|
|
// Functions commonly used in admin pages
|
|
|
|
function getAdminSideBarLinks()
|
|
{
|
|
$links = <<<end
|
|
<a href="/site/exchange">Exchanges</a>
|
|
<a href="/site/user">Users</a>
|
|
<a href="/site/worker">Workers</a>
|
|
<a href="/site/version">Version</a>
|
|
<a href="/site/earning">Earnings</a>
|
|
<a href="/site/payments">Payments</a>
|
|
<a href="/site/monsters">Big Miners</a>
|
|
end;
|
|
return $links;
|
|
}
|
|
|
|
// shared by wallet "tabs", to move in another php file...
|
|
function getAdminWalletLinks($coin, $info=NULL, $src='wallet')
|
|
{
|
|
$html = CHtml::link("<b>COIN PROPERTIES</b>", '/site/update?id='.$coin->id);
|
|
if($info) {
|
|
$html .= ' || '.$coin->createExplorerLink("<b>EXPLORER</b>");
|
|
$html .= ' || '.CHtml::link("<b>PEERS</b>", '/site/peers?id='.$coin->id);
|
|
if (YAAMP_ADMIN_WEBCONSOLE)
|
|
$html .= ' || '.CHtml::link("<b>CONSOLE</b>", '/site/console?id='.$coin->id);
|
|
$html .= ' || '.CHtml::link("<b>TRIGGERS</b>", '/site/triggers?id='.$coin->id);
|
|
if ($src != 'wallet')
|
|
$html .= ' || '.CHtml::link("<b>{$coin->symbol}</b>", '/site/coin?id='.$coin->id);
|
|
}
|
|
|
|
if(!$info && $coin->enable)
|
|
$html .= '<br/>'.CHtml::link("<b>STOP COIND</b>", '/site/stopcoin?id='.$coin->id);
|
|
|
|
if($coin->auto_ready)
|
|
$html .= '<br/>'.CHtml::link("<b>UNSET AUTO</b>", '/site/unsetauto?id='.$coin->id);
|
|
else
|
|
$html .= '<br/>'.CHtml::link("<b>SET AUTO</b>", '/site/setauto?id='.$coin->id);
|
|
|
|
$html .= '<br/>';
|
|
|
|
if(!empty($coin->link_bitcointalk))
|
|
$html .= CHtml::link('forum', $coin->link_bitcointalk, array('target'=>'_blank')).' ';
|
|
|
|
if(!empty($coin->link_github))
|
|
$html .= CHtml::link('git', $coin->link_github, array('target'=>'_blank')).' ';
|
|
|
|
if(!empty($coin->link_site))
|
|
$html .= CHtml::link('site', $coin->link_site, array('target'=>'_blank')).' ';
|
|
|
|
$html .= CHtml::link('google', 'http://google.com/search?q='.urlencode($coin->name.' '.$coin->symbol.' bitcointalk'), array('target'=>'_blank'));
|
|
|
|
return $html;
|
|
}
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////////////////
|