getState('yaamp-deposit');
echo "refresh
";
////////////////////////////////////////////////////////////////////////////////////////////////////////
$list = getdbolist('db_rentertxs', "1 order by time desc limit 10");
if(count($list) == 0) return;
echo "
";
echo "";
echo "";
echo "ID | ";
echo "Address | ";
echo "Time | ";
echo "Type | ";
echo "Amount | ";
echo "Tx | ";
echo "
";
echo "";
foreach($list as $tx)
{
$d = datetoa2($tx->time);
$amount = bitcoinvaluetoa($tx->amount);
$renter = getdbo('db_renters', $tx->renterid);
if(!$renter) continue;
echo "";
echo "$renter->id | ";
echo "$renter->address | ";
echo "$d ago | ";
echo "$tx->type | ";
echo "$amount | ";
if(strlen($tx->tx) > 32)
{
$tx_show = substr($tx->tx, 0, 36).'...';
$txurl = "https://blockchain.info/tx/$tx->tx";
echo "$tx_show | ";
}
else
echo "$tx->tx | ";
echo "
";
}
echo "
";
/////////////////////////////////////////////////////////////////////////////////////////////////////////
echo "
";
echo "";
echo "";
echo "Renter | ";
echo "Address | ";
echo "Email | ";
echo "Spent | ";
echo "Balance | ";
echo "Unconfirmed | ";
echo "Jobs | ";
echo "Active | ";
echo "
";
echo "";
$list = getdbolist('db_renters', "balance>0 order by balance desc");
foreach($list as $renter)
{
$count = dboscalar("select count(*) from jobs where renterid=$renter->id");
$active = dboscalar("select count(*) from jobs where renterid=$renter->id and active");
if($deposit == $renter->address)
echo "";
else
echo "
";
echo "$renter->id | ";
echo "$renter->address | ";
echo "$renter->email | ";
echo "$renter->spent | ";
echo "$renter->balance | ";
echo "$renter->unconfirmed | ";
echo "$count | ";
echo "$active | ";
echo "
";
}
echo "
";
/////////////////////////////////////////////////////////////////////////////
echo "
";
echo "";
echo "";
echo "Renter | ";
echo "Job | ";
echo "Address | ";
echo "Algo | ";
echo "Host | ";
echo "Max Price | ";
echo "Max Hash | ";
echo "Current Hash | ";
echo "Difficulty | ";
echo "Ready | ";
echo "Active | ";
echo "
";
echo "";
$list = getdbolist('db_jobs', "ready");
foreach($list as $job)
{
$hashrate = yaamp_job_rate($job->id);
$hashrate = $hashrate? Itoa2($hashrate).'h/s': '';
$speed = Itoa2($job->speed).'h/s';
$renter = getdbo('db_renters', $job->renterid);
if(!$renter) continue;
if($deposit == $renter->address)
echo "";
else
echo "
";
echo "$job->renterid | ";
echo "$job->id | ";
echo "$renter->address | ";
echo "$job->algo | ";
echo "$job->host:$job->port | ";
echo "$job->price | ";
echo "$speed | ";
echo "$hashrate | ";
echo "$job->difficulty | ";
echo "$job->ready | ";
echo "$job->active | ";
echo "
";
}
echo "
";
echo "
";