1
This commit is contained in:
parent
00a7f944d7
commit
c0a0d28474
@ -114,17 +114,51 @@ class RankBattle extends BaseModel
|
||||
if (!self::inspectType($type)){
|
||||
return array();
|
||||
}
|
||||
$row = SqlHelper::ormSelectOne
|
||||
(myself()->_getSelfMysql(),
|
||||
't_rank_battle',
|
||||
array(
|
||||
'account_id' => myself()->_getAccountId(),
|
||||
'type' => $type,
|
||||
'mode' => $mode,
|
||||
'class' => $class,
|
||||
)
|
||||
);
|
||||
return $row ? $row : null;
|
||||
|
||||
$row = array();
|
||||
switch ($class) {
|
||||
case self::OVERALL_CHARTS : {
|
||||
$row = SqlHelper::ormSelectOne
|
||||
(myself()->_getSelfMysql(),
|
||||
't_rank_battle',
|
||||
array(
|
||||
'account_id' => myself()->_getAccountId(),
|
||||
'type' => $type,
|
||||
'mode' => $mode,
|
||||
'class' => $class,
|
||||
)
|
||||
);
|
||||
}
|
||||
break;
|
||||
case self::DAILY_CHARTS :{
|
||||
$row = SqlHelper::ormSelectOne
|
||||
(myself()->_getSelfMysql(),
|
||||
't_rank_battle',
|
||||
array(
|
||||
'account_id' => myself()->_getAccountId(),
|
||||
'type' => $type,
|
||||
'mode' => $mode,
|
||||
'class' => $class,
|
||||
"writetime" => myself()->_getNowDaySeconds(),
|
||||
)
|
||||
);
|
||||
}
|
||||
break;
|
||||
case self::WEEKLY_CHARTS:{
|
||||
$row = SqlHelper::ormSelectOne
|
||||
(myself()->_getSelfMysql(),
|
||||
't_rank_battle',
|
||||
array(
|
||||
'account_id' => myself()->_getAccountId(),
|
||||
'type' => $type,
|
||||
'mode' => $mode,
|
||||
'class' => $class,
|
||||
"writetime" => myself()->_getMondaySeconds(),
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
return $row ;
|
||||
}
|
||||
|
||||
public static function upsert($account,$mode,$type,$val){
|
||||
|
Loading…
x
Reference in New Issue
Block a user