移除historyRecord
This commit is contained in:
parent
240831aea6
commit
1b08f10475
24
doc/Role.py
24
doc/Role.py
@ -19,7 +19,7 @@ class Role(object):
|
||||
]
|
||||
},
|
||||
{
|
||||
'desc': 'clientBattleReport',
|
||||
'desc': '客户端战报clientBattleReport',
|
||||
'group': 'Role',
|
||||
'url': 'webapp/index.php?c=Role&a=clientBattleReport',
|
||||
'params': [
|
||||
@ -40,28 +40,6 @@ class Role(object):
|
||||
_common.RspHead(),
|
||||
]
|
||||
},
|
||||
{
|
||||
'desc': 'bioBattleReport',
|
||||
'group': 'Role',
|
||||
'url': 'webapp/index.php?c=Role&a=bioBattleReport',
|
||||
'params': [
|
||||
_common.ReqHead(),
|
||||
],
|
||||
'response': [
|
||||
_common.RspHead(),
|
||||
]
|
||||
},
|
||||
{
|
||||
'desc': 'oldBattleReport',
|
||||
'group': 'Role',
|
||||
'url': 'webapp/index.php?c=Role&a=oldBattleReport',
|
||||
'params': [
|
||||
_common.ReqHead(),
|
||||
],
|
||||
'response': [
|
||||
_common.RspHead(),
|
||||
]
|
||||
},
|
||||
{
|
||||
'desc': 'historyRecord',
|
||||
'group': 'Role',
|
||||
|
@ -164,23 +164,23 @@ class RoleController extends BaseAuthedController {
|
||||
public function battleReport()
|
||||
{
|
||||
$taskObj = new NTaskController();
|
||||
$taskObj->updateTaskToDB(PLAY_GAME,1);
|
||||
$taskObj->updateTaskToDB(PLAY_GAME, 1);
|
||||
|
||||
$alive_time = $_REQUEST["alive_time"];
|
||||
$tmpAlive_time = floor($alive_time/1000);
|
||||
$taskObj->updateTaskToDB(ALIVE_TIME,$tmpAlive_time);
|
||||
$taskObj->updateTaskToDB(ALIVE_TIME, $tmpAlive_time);
|
||||
|
||||
$killNum = $_REQUEST['kills'];
|
||||
$taskObj->updateTaskToDB(KILL_NUM,$killNum);
|
||||
$taskObj->updateTaskToDB(KILL_NUM, $killNum);
|
||||
$damageNum = $_REQUEST['harm'];
|
||||
$taskObj->updateTaskToDB(DAMAGE_NUM70006,$damageNum);
|
||||
$taskObj->updateTaskToDB(DAMAGE_NUM70006, $damageNum);
|
||||
|
||||
$helpOtherPlayer = $_REQUEST['rescue_member'];
|
||||
$taskObj->updateTaskToDB(HELP_OP70008,$helpOtherPlayer);
|
||||
$taskObj->updateTaskToDB(HELP_OP70008, $helpOtherPlayer);
|
||||
$this->oldBattleReport();
|
||||
}
|
||||
|
||||
public function oldBattleReport()
|
||||
private function oldBattleReport()
|
||||
{
|
||||
$account_id = $_REQUEST['account_id']; //账号
|
||||
$conn = $this->getMysql($account_id);
|
||||
@ -402,39 +402,6 @@ class RoleController extends BaseAuthedController {
|
||||
));
|
||||
}
|
||||
|
||||
public function historyRecord()
|
||||
{
|
||||
$account_id = $_REQUEST['account_id'];
|
||||
$conn = $this->getMysql($account_id);
|
||||
$record_list = array();
|
||||
$rowCount = $conn->execQueryRowCount('SELECT * FROM history_record WHERE accountid=:accountid;',
|
||||
array(
|
||||
':accountid' => $account_id
|
||||
));
|
||||
if ($rowCount != 0) {
|
||||
$rows = $conn->execQuery('SELECT * FROM history_record WHERE accountid=:account_id order by game_time desc limit 0,10;',
|
||||
array(
|
||||
':account_id' => $account_id
|
||||
));
|
||||
foreach ($rows as $row) {
|
||||
array_push($record_list, array(
|
||||
'map_name' => $row['map_name'],
|
||||
'game_time' => $row['game_time'],
|
||||
'rank' => $row['rank'],
|
||||
'kills' => $row['kills'],
|
||||
'harms' => $row['harms'],
|
||||
'hurts' => $row['hurts'],
|
||||
'alive_time' => $row['alive_time']
|
||||
));
|
||||
}
|
||||
}
|
||||
echo json_encode(array(
|
||||
'errcode' => 0,
|
||||
'errmsg' => '',
|
||||
'record_list' => $record_list
|
||||
));
|
||||
}
|
||||
|
||||
public function shareGame()
|
||||
{
|
||||
$account_id = $_REQUEST['account_id'];
|
||||
|
Loading…
x
Reference in New Issue
Block a user