1
This commit is contained in:
commit
9c3a61daa4
@ -101,7 +101,7 @@ class RankingController extends BaseAuthedController {
|
||||
);
|
||||
$rankingList = array();
|
||||
$meta = mt\RankActivity::get($type);
|
||||
if ($meta && mt\RankActivity::isActivityPeriod($meta)) {
|
||||
if ($meta) {
|
||||
$row = myself()->_getSelfMysql()->execQueryOne(
|
||||
'SELECT COUNT(*) AS row_count FROM t_rank_activity ' .
|
||||
'WHERE type=:type AND channel=:channel AND value>:value;',
|
||||
@ -125,6 +125,22 @@ class RankingController extends BaseAuthedController {
|
||||
)
|
||||
);
|
||||
$ranked = 1;
|
||||
foreach ($rows as $row) {
|
||||
$user = User::find($row['account_id']);
|
||||
if ($user) {
|
||||
if ($user['account_id'] == $myRanked['user']['account_id']) {
|
||||
$myRanked['ranked'] = $ranked;
|
||||
$myRanked['value'] = $row['value'];
|
||||
$myRanked['modifytime'] = $row['modifytime'];
|
||||
}
|
||||
array_push($rankingList, array(
|
||||
'ranked' => $ranked++,
|
||||
'user' => User::toSimple($user),
|
||||
'value' => $row['value'],
|
||||
'modifytime' => $row['modifytime'],
|
||||
));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
{
|
||||
|
@ -66,6 +66,7 @@ class TempToolsController extends BaseController {
|
||||
));
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
public function exportRankActivity()
|
||||
{
|
||||
$type = getReqVal('type', '');
|
||||
@ -113,6 +114,8 @@ class TempToolsController extends BaseController {
|
||||
}
|
||||
}
|
||||
|
||||
=======
|
||||
>>>>>>> master
|
||||
public function getRiskAccounts()
|
||||
{
|
||||
$accounts = array();
|
||||
|
@ -135,7 +135,7 @@ class Gun extends BaseModel {
|
||||
}
|
||||
$todayGetGold = $row['today_get_gold'];
|
||||
$lastGetGoldTime = $row['last_get_gold_time'];
|
||||
if (myself()->_getDaySeconds($lastGetGoldTime) > myself()->_getNowDaySeconds()) {
|
||||
if (myself()->_getDaySeconds($lastGetGoldTime) < myself()->_getNowDaySeconds()) {
|
||||
$todayGetGold = 0;
|
||||
}
|
||||
$dto = array(
|
||||
|
@ -123,7 +123,7 @@ class Hero extends BaseModel {
|
||||
}
|
||||
$todayGetGold = $row['today_get_gold'];
|
||||
$lastGetGoldTime = $row['last_get_gold_time'];
|
||||
if (myself()->_getDaySeconds($lastGetGoldTime) > myself()->_getNowDaySeconds()) {
|
||||
if (myself()->_getDaySeconds($lastGetGoldTime) < myself()->_getNowDaySeconds()) {
|
||||
$todayGetGold = 0;
|
||||
}
|
||||
$dto = array(
|
||||
|
Loading…
x
Reference in New Issue
Block a user