Merge branch 'development'
* FIX: Cryptorush API & Wiki Updated * ADDED: mintpal API ticker & Wiki Updated * UPDATE: MPOS template updates - Thanks SamuelNZ * CLEANUP: Dynamic table references in classes - Thanks @barrybingo
This commit is contained in:
commit
b2d8c18def
@ -462,7 +462,7 @@ class Statistics extends Base {
|
|||||||
id,
|
id,
|
||||||
IF(difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty) AS difficulty,
|
IF(difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty) AS difficulty,
|
||||||
username
|
username
|
||||||
FROM shares
|
FROM " . $this->share->getTableName() . "
|
||||||
WHERE time > DATE_SUB(now(), INTERVAL ? SECOND) AND our_result = 'Y'
|
WHERE time > DATE_SUB(now(), INTERVAL ? SECOND) AND our_result = 'Y'
|
||||||
UNION
|
UNION
|
||||||
SELECT
|
SELECT
|
||||||
@ -533,7 +533,7 @@ class Statistics extends Base {
|
|||||||
SELECT
|
SELECT
|
||||||
id, our_result, IF(difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty) AS difficulty
|
id, our_result, IF(difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty) AS difficulty
|
||||||
FROM
|
FROM
|
||||||
shares
|
" . $this->share->getTableName() . "
|
||||||
WHERE username LIKE ?
|
WHERE username LIKE ?
|
||||||
AND time > DATE_SUB(now(), INTERVAL ? SECOND)
|
AND time > DATE_SUB(now(), INTERVAL ? SECOND)
|
||||||
AND our_result = 'Y'
|
AND our_result = 'Y'
|
||||||
@ -541,7 +541,7 @@ class Statistics extends Base {
|
|||||||
SELECT
|
SELECT
|
||||||
share_id, our_result, IF(difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty) AS difficulty
|
share_id, our_result, IF(difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty) AS difficulty
|
||||||
FROM
|
FROM
|
||||||
shares_archive
|
" . $this->share->getArchiveTableName() . "
|
||||||
WHERE username LIKE ?
|
WHERE username LIKE ?
|
||||||
AND time > DATE_SUB(now(), INTERVAL ? SECOND)
|
AND time > DATE_SUB(now(), INTERVAL ? SECOND)
|
||||||
AND our_result = 'Y'
|
AND our_result = 'Y'
|
||||||
|
|||||||
@ -57,6 +57,8 @@ class Tools extends Base {
|
|||||||
return 'cryptsy';
|
return 'cryptsy';
|
||||||
} else if (preg_match('/cryptorush.in/', $url)) {
|
} else if (preg_match('/cryptorush.in/', $url)) {
|
||||||
return 'cryptorush';
|
return 'cryptorush';
|
||||||
|
} else if (preg_match('/mintpal.com/', $url)) {
|
||||||
|
return 'mintpal';
|
||||||
}
|
}
|
||||||
$this->setErrorMessage("API URL unknown");
|
$this->setErrorMessage("API URL unknown");
|
||||||
return false;
|
return false;
|
||||||
@ -87,7 +89,10 @@ class Tools extends Base {
|
|||||||
return @$aData['return']['markets'][$strCurrency]['lasttradeprice'];
|
return @$aData['return']['markets'][$strCurrency]['lasttradeprice'];
|
||||||
break;
|
break;
|
||||||
case 'cryptorush':
|
case 'cryptorush':
|
||||||
return @$aData["$strCurrency/" . $this->config['price']['target']]['last_trade'];
|
return @$aData["$strCurrency/" . $this->config['price']['currency']]['last_trade'];
|
||||||
|
break;
|
||||||
|
case 'mintpal':
|
||||||
|
return @$aData['0']['last_price'];
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@ -70,8 +70,8 @@ class Transaction extends Base {
|
|||||||
$sql = "
|
$sql = "
|
||||||
SELECT
|
SELECT
|
||||||
SUM(t.amount) AS total, t.type AS type
|
SUM(t.amount) AS total, t.type AS type
|
||||||
FROM transactions AS t
|
FROM $this->table AS t
|
||||||
LEFT OUTER JOIN blocks AS b
|
LEFT OUTER JOIN " . $this->block->getTableName() . " AS b
|
||||||
ON b.id = t.block_id
|
ON b.id = t.block_id
|
||||||
WHERE ( b.confirmations > 0 OR b.id IS NULL )";
|
WHERE ( b.confirmations > 0 OR b.id IS NULL )";
|
||||||
if (!empty($account_id)) {
|
if (!empty($account_id)) {
|
||||||
@ -211,7 +211,7 @@ class Transaction extends Base {
|
|||||||
FROM $this->table AS t
|
FROM $this->table AS t
|
||||||
LEFT JOIN " . $this->user->getTableName() . " AS a
|
LEFT JOIN " . $this->user->getTableName() . " AS a
|
||||||
ON t.account_id = a.id
|
ON t.account_id = a.id
|
||||||
LEFT JOIN blocks AS b
|
LEFT JOIN " . $this->block->getTableName() . " AS b
|
||||||
ON t.block_id = b.id
|
ON t.block_id = b.id
|
||||||
WHERE
|
WHERE
|
||||||
(
|
(
|
||||||
@ -306,9 +306,9 @@ class Transaction extends Base {
|
|||||||
), 0
|
), 0
|
||||||
) AS confirmed
|
) AS confirmed
|
||||||
FROM $this->table AS t
|
FROM $this->table AS t
|
||||||
LEFT JOIN blocks AS b
|
LEFT JOIN " . $this->block->getTableName() . " AS b
|
||||||
ON t.block_id = b.id
|
ON t.block_id = b.id
|
||||||
LEFT JOIN accounts AS a
|
LEFT JOIN " . $this->user->getTableName() . " AS a
|
||||||
ON t.account_id = a.id
|
ON t.account_id = a.id
|
||||||
WHERE t.archived = 0 AND a.ap_threshold > 0 AND a.coin_address IS NOT NULL AND a.coin_address != ''
|
WHERE t.archived = 0 AND a.ap_threshold > 0 AND a.coin_address IS NOT NULL AND a.coin_address != ''
|
||||||
GROUP BY t.account_id
|
GROUP BY t.account_id
|
||||||
|
|||||||
@ -55,7 +55,7 @@
|
|||||||
<li class="icon-pencil"><a href="{$smarty.server.SCRIPT_NAME}?page=register">Sign Up</a></li>
|
<li class="icon-pencil"><a href="{$smarty.server.SCRIPT_NAME}?page=register">Sign Up</a></li>
|
||||||
{/if}
|
{/if}
|
||||||
{acl_check icon='icon-mail' page='contactform' action='' name='Contact' acl=$GLOBAL.acl.contactform}
|
{acl_check icon='icon-mail' page='contactform' action='' name='Contact' acl=$GLOBAL.acl.contactform}
|
||||||
<li class="icon-doc"><a href="{$smarty.server.SCRIPT_NAME}?page=tac">Terms and Conditions</a></li>
|
<li class="icon-doc"><a href="{$smarty.server.SCRIPT_NAME}?page=tac">Terms & Conditions</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
<ul>
|
<ul>
|
||||||
<hr/>
|
<hr/>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user