";
echo "
Transactions from $renter->address
";
diff --git a/web/yaamp/modules/site/SiteController.php b/web/yaamp/modules/site/SiteController.php
index b6a336b..ba51ace 100644
--- a/web/yaamp/modules/site/SiteController.php
+++ b/web/yaamp/modules/site/SiteController.php
@@ -2,24 +2,24 @@
class SiteController extends CommonController
{
- public $defaultAction='index';
-
+ public $defaultAction='index';
+
///////////////////////////////////////////////////
- public function actionfrottedessus()
+ public function actionAdmintest()
{
debuglog("admin login {$_SERVER['REMOTE_ADDR']}");
-
+
user()->setState('yaamp_admin', true);
$this->redirect("/site/common");
}
-
+
/////////////////////////////////////////////////
-
+
public function actionCreate()
{
if(!$this->admin) return;
-
+
$coin = new db_coins;
$coin->txmessage = true;
$coin->created = time();
@@ -27,17 +27,17 @@ class SiteController extends CommonController
$coin->difficulty = 1;
$coin->installed = 1;
$coin->visible = 1;
-
+
// $coin->deposit_minimum = 1;
$coin->lastblock = '';
-
+
if(isset($_POST['db_coins']))
{
$coin->attributes = $_POST['db_coins'];
if($coin->save())
$this->redirect(array('admin'));
}
-
+
$this->render('coin_form', array('update'=>false, 'coin'=>$coin));
}
@@ -46,7 +46,7 @@ class SiteController extends CommonController
if(!$this->admin) return;
$coin = getdbo('db_coins', getiparam('id'));
$txfee = $coin->txfee;
-
+
if(isset($_POST['db_coins']))
{
$coin->attributes = $_POST['db_coins'];
@@ -57,17 +57,17 @@ class SiteController extends CommonController
$remote = new Bitcoin($coin->rpcuser, $coin->rpcpasswd, $coin->rpchost, $coin->rpcport);
$remote->settxfee($coin->txfee);
}
-
+
// $this->redirect(array('admin'));
$this->goback();
}
}
-
+
$this->render('coin_form', array('update'=>true, 'coin'=>$coin));
}
/////////////////////////////////////////////////
-
+
public function actionIndex()
{
if(isset($_GET['address']))
@@ -102,87 +102,87 @@ class SiteController extends CommonController
}
/////////////////////////////////
-
+
public function actionCurrent_results()
{
$this->renderPartial('results/current_results');
}
-
+
public function actionHistory_results()
{
$this->renderPartial('results/history_results');
}
-
+
public function actionMining_results()
{
$this->renderPartial('results/mining_results');
}
-
+
public function actionMiners_results()
{
$this->renderPartial('results/miners_results');
}
-
+
public function actionWallet_results()
{
$this->renderPartial('results/wallet_results');
}
-
+
public function actionWallet_miners_results()
{
$this->renderPartial('results/wallet_miners_results');
}
-
+
public function actionWallet_graphs_results()
{
$this->renderPartial('results/wallet_graphs_results');
}
-
+
public function actionGraph_earnings_results()
{
$this->renderPartial('results/graph_earnings_results');
}
-
+
public function actionFound_results()
{
$this->renderPartial('results/found_results');
}
-
+
public function actionUser_earning_results()
{
$this->renderPartial('results/user_earning_results');
}
-
+
public function actionGraph_hashrate_results()
{
$this->renderPartial('results/graph_hashrate_results');
}
-
+
public function actionGraph_user_results()
{
$this->renderPartial('results/graph_user_results');
}
-
+
public function actionGraph_price_results()
{
$this->renderPartial('results/graph_price_results');
}
-
+
public function actionGraph_assets_results()
{
$this->renderPartial('results/graph_assets_results');
}
-
+
public function actionGraph_negative_results()
{
$this->renderPartial('results/graph_negative_results');
}
-
+
public function actionGraph_profit_results()
{
$this->renderPartial('results/graph_profit_results');
}
-
+
public function actionTitle_results()
{
$user = getuserparam(getparam('address'));
@@ -190,30 +190,30 @@ class SiteController extends CommonController
{
$balance = bitcoinvaluetoa($user->balance);
$coin = getdbo('db_coins', $user->coinid);
-
+
if($coin)
- echo "$balance $coin->symbol - yaamp.com";
+ echo "$balance $coin->symbol - yiimp";
else
- echo "$balance - yaamp.com";
+ echo "$balance - yiimp";
}
else
- echo "yaamp.com";
+ echo YAAMP_SITE_URL;
}
-
+
/////////////////////////////////////////////////
-
+
public function actionAbout()
{
$this->render('about');
}
-
+
public function actionTerms()
{
$this->render('terms');
}
/////////////////////////////////////////////////
-
+
public function actionAdmin()
{
if(!$this->admin) return;
@@ -225,9 +225,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('admin_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionConnections()
{
if(!$this->admin) return;
@@ -239,9 +239,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('connections_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionBlock()
{
$this->render('block');
@@ -251,9 +251,9 @@ class SiteController extends CommonController
{
$this->renderPartial('block_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionEarning()
{
if(!$this->admin) return;
@@ -265,9 +265,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('earning_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionPayments()
{
if(!$this->admin) return;
@@ -279,9 +279,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('payments_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionUser()
{
if(!$this->admin) return;
@@ -293,9 +293,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('user_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionWorker()
{
if(!$this->admin) return;
@@ -307,9 +307,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('worker_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionVersion()
{
if(!$this->admin) return;
@@ -321,9 +321,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('version_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionCommon()
{
if(!$this->admin) return;
@@ -335,9 +335,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('common_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionExchange()
{
if(!$this->admin) return;
@@ -349,9 +349,9 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('exchange_results');
}
-
+
/////////////////////////////////////////////////
-
+
public function actionCoin()
{
if(!$this->admin) return;
@@ -363,46 +363,46 @@ class SiteController extends CommonController
if(!$this->admin) return;
$this->renderPartial('coin_results');
}
-
+
public function actionMemcached()
{
if(!$this->admin) return;
$this->render('memcached');
}
-
+
public function actionMonsters()
{
if(!$this->admin) return;
$this->render('monsters');
}
-
+
public function actionEmptyMarkets()
{
if(!$this->admin) return;
$this->render('emptymarkets');
}
-
+
//////////////////////////////////////////////////////////////////////////////////////
-
+
public function actionTx()
{
$this->renderPartial('tx');
}
//////////////////////////////////////////////////////////////////////////////////////
-
+
public function actionResetBlockchain()
{
if(!$this->admin) return;
$coin = getdbo('db_coins', $_GET['id']);
$coin->action = 3;
$coin->save();
-
+
$this->redirect("/site/coin?id=$coin->id");
}
-
+
//////////////////////////////////////////////////////////////////////////////////////
-
+
public function actionRestartCoin()
{
if(!$this->admin) return;
@@ -414,11 +414,11 @@ class SiteController extends CommonController
$coin->installed = true;
$coin->connections = 0;
$coin->save();
-
+
$this->redirect('/site/admin');
// $this->goback();
}
-
+
public function actionStartCoin()
{
if(!$this->admin) return;
@@ -430,16 +430,16 @@ class SiteController extends CommonController
$coin->installed = true;
$coin->connections = 0;
$coin->save();
-
+
$this->redirect('/site/admin');
// $this->goback();
}
-
+
public function actionStopCoin()
{
if(!$this->admin) return;
$coin = getdbo('db_coins', $_GET['id']);
-
+
$coin->action = 2;
$coin->enable = false;
$coin->auto_ready = false;
@@ -449,12 +449,12 @@ class SiteController extends CommonController
$this->redirect('/site/admin');
// $this->goback();
}
-
+
public function actionMakeConfigfile()
{
if(!$this->admin) return;
$coin = getdbo('db_coins', $_GET['id']);
-
+
$coin->action = 5;
$coin->installed = true;
$coin->save();
@@ -462,79 +462,79 @@ class SiteController extends CommonController
$this->redirect('/site/admin');
// $this->goback();
}
-
+
//////////////////////////////////////////////////////////////////////////////////////
-
+
public function actionSetauto()
{
if(!$this->admin) return;
$coin = getdbo('db_coins', $_GET['id']);
-
+
$coin->auto_ready = true;
$coin->save();
-
+
$this->redirect('/site/admin');
// $this->goback();
}
-
+
public function actionUnsetauto()
{
if(!$this->admin) return;
$coin = getdbo('db_coins', $_GET['id']);
-
+
$coin->auto_ready = false;
$coin->save();
-
+
$this->redirect('/site/admin');
// $this->goback();
}
-
+
public function actionSellBalance()
{
if(!$this->admin) return;
$coin = getdbo('db_coins', getiparam('id'));
$amount = getparam('amount');
-
+
$res = $this->doSellBalance($coin, $amount);
-
+
if(!$res)
$this->redirect('/site/admin');
else
$this->redirect('/site/exchange');
}
-
+
//////////////////////////////////////////////////////////////////////////////////////////////////
public function actionBlockuser()
{
if(!$this->admin) return;
-
+
$wallet = getparam('wallet');
$user = getuserparam($wallet);
-
+
$user->is_locked = true;
$user->save();
-
+
$this->redirect('/site/monsters');
}
-
+
public function actionUnblockuser()
{
if(!$this->admin) return;
-
+
$wallet = getparam('wallet');
$user = getuserparam($wallet);
-
+
$user->is_locked = false;
$user->save();
-
+
$this->redirect('/site/monsters');
}
-
+
public function actionPayuserscoin()
{
if(!$this->admin) return;
-
+
$coin = getdbo('db_coins', getiparam('id'));
if(!$coin)
{
@@ -545,13 +545,13 @@ class SiteController extends CommonController
BackendCoinPayments($coin);
$this->goback();
}
-
+
////
-
+
public function actionDeleteEarnings()
{
if(!$this->admin) return;
-
+
$coin = getdbo('db_coins', getiparam('id'));
if(!$coin)
{
@@ -565,37 +565,37 @@ class SiteController extends CommonController
dborun("delete from earnings where coinid=$coin->id");
$this->redirect("/site/admin");
}
-
+
public function actionDeleteEarning()
{
if(!$this->admin) return;
$earning = getdbo('db_earnings', $_GET['id']);
$earning->delete();
-
+
$this->redirect('/site/earning');
}
-
+
//////////////////////////////////////////////////////////////////////////////////////////////////
public function actionDeleteExchange()
{
$exchange = getdbo('db_exchange', getiparam('id'));
$unspent = $exchange->quantity;
-
+
$exchange->status = 'deleted';
$exchange->price = 0;
$exchange->receive_time = time();
$exchange->save();
-
+
// $earnings = getdbolist('db_earnings', "coinid=$exchange->coinid and not cleared order by create_time");
// foreach($earnings as $earning)
// {
// $unspent -= $earning->amount;
// $earning->delete();
-
+
// if($unspent <= 0) break;
// }
-
+
$this->redirect('/site/exchange');
}
@@ -603,16 +603,16 @@ class SiteController extends CommonController
{
$id = getiparam('id');
$market = getdbo('db_markets', $id);
-
+
if($market)
{
$market->lastsent = null;
$market->save();
}
-
+
$this->redirect('/site/common');
}
-
+
////////////////////////////////////////////////////////////////////////////////////////
public function actionAlgo()
@@ -627,7 +627,7 @@ class SiteController extends CommonController
$this->goback();
}
-
+
public function actionGomining()
{
user()->setState('yaamp-algo', getparam('algo'));
@@ -640,11 +640,11 @@ class SiteController extends CommonController
BackendPricesUpdate();
$this->goback();
}
-
+
public function actionUninstallCoin()
{
if(!$this->admin) return;
-
+
$coin = getdbo('db_coins', getiparam('id'));
if($coin)
{
@@ -654,7 +654,7 @@ class SiteController extends CommonController
// dborun("delete from markets where coinid=$coin->id");
dborun("delete from orders where coinid=$coin->id");
dborun("delete from shares where coinid=$coin->id");
-
+
$coin->enable = false;
$coin->installed = false;
$coin->auto_ready = false;
@@ -663,14 +663,14 @@ class SiteController extends CommonController
$coin->balance = 0;
$coin->save();
}
-
+
$this->redirect("/site/admin");
}
public function actionBanUser()
{
if(!$this->admin) return;
-
+
$user = getdbo('db_accounts', getiparam('id'));
if($user)
{
@@ -678,60 +678,60 @@ class SiteController extends CommonController
$user->balance = 0;
$user->save();
}
-
+
$this->goback();
}
-
+
public function actionOptimize()
{
BackendOptimizeTables();
$this->goback();
}
-
+
public function actionRunExchange()
{
$id = getiparam('id');
$balance = getdbo('db_balances', $id);
-
+
if($balance) switch($balance->name)
{
case 'cryptsy':
doCryptsyTrading(true);
updateCryptsyMarkets();
-
+
break;
-
+
case 'bittrex':
doBittrexTrading(true);
updateBittrexMarkets();
-
+
break;
-
+
case 'c-cex':
doCCexTrading(true);
updateCCexMarkets();
-
+
break;
-
+
case 'yobit':
doYobitTrading(true);
updateYobitMarkets();
-
+
break;
-
+
case 'bleutrade':
doBleutradeTrading(true);
updateBleutradeMarkets();
-
+
break;
case 'poloniex':
doPoloniexTrading(true);
updatePoloniexMarkets();
-
+
break;
}
-
+
debuglog("runexchange done");
$this->redirect("/site/common");
}
@@ -743,7 +743,7 @@ class SiteController extends CommonController
// $param = getparam('param');
// if($param) eval($param);
// else $param = '';
-
+
// $this->render('eval', array('param'=>$param));
}
@@ -752,7 +752,7 @@ class SiteController extends CommonController
debuglog(__METHOD__);
setcookie('mainbtc', '1', time()+60*60*24, '/');
}
-
+
public function actionTest()
{
// if(!$this->admin) return;
@@ -760,13 +760,8 @@ class SiteController extends CommonController
$ticker = jubi_api_query('ticker', "?coin=sak");
debuglog($ticker);
-
+
debuglog("action test end");
}
}
-
-
-
-
-
diff --git a/web/yaamp/modules/site/common_results.php b/web/yaamp/modules/site/common_results.php
index b03a30e..8b3bbfb 100644
--- a/web/yaamp/modules/site/common_results.php
+++ b/web/yaamp/modules/site/common_results.php
@@ -478,8 +478,10 @@ $immature = bitcoinvaluetoa($immature);
$mints = bitcoinvaluetoa($mints);
$off = bitcoinvaluetoa($off);
+$btcaddr = YAAMP_BTCADDRESS; //'14LS7Uda6EZGXLtRrFEZ2kWmarrxobkyu9';
+
echo "
Bitstamp $mining->usdbtc, ";
-echo "
wallet $btc->balance, next payout $topay2
";
+echo "
wallet $btc->balance, next payout $topay2
";
echo "pay $topay, renter $renter, marg $margin, $margin2
";
echo "mint $mints immature $immature off $off
";
diff --git a/web/yaamp/modules/site/diff.php b/web/yaamp/modules/site/diff.php
index 8357082..054c83c 100644
--- a/web/yaamp/modules/site/diff.php
+++ b/web/yaamp/modules/site/diff.php
@@ -11,7 +11,7 @@ you have from 5 to 15 submits per minute. It's a good trade off between bandwidt
if you want to set the difficulty to 64, you would use:
--o stratum+tcp://yaamp.com:3433 -u wallet_adress -p d=64
+-o stratum+tcp://yiimp.ccminer.org:3433 -u wallet_adress -p d=64
Here are the accepted values for the custom diff:
diff --git a/web/yaamp/modules/site/index.php b/web/yaamp/modules/site/index.php
index dd27542..2260f9b 100644
--- a/web/yaamp/modules/site/index.php
+++ b/web/yaamp/modules/site/index.php
@@ -24,12 +24,12 @@ echo <<
-
YET ANOTHER ANONYMOUS MINING POOL
+
YII MINING POOL
";
echo "
";
@@ -122,7 +122,7 @@ function showPageFooter()
echo "";