修改bugt

master
ELF 5 years ago
parent 4c4d3255d7
commit 24cbe37faa

@ -65,8 +65,8 @@ class SpendRepository {
$map['promote_id'] = ['in', $ids];
$map['pay_way'] = $isBan ? ['neq', '-10'] : ['neq', '-1'];
$field = 'FROM_UNIXTIME(pay_time,"%Y-%m-%d") as day,sum(pay_amount) as amount';
$items = M('spend', 'tab_')->field($field)->where($map)->group('FROM_UNIXTIME(day, "%Y-%m-%d")')->select();
$field = 'FROM_UNIXTIME(pay_time,"%Y-%m-%d") as day, sum(pay_amount) as amount';
$items = M('spend', 'tab_')->field($field)->where($map)->group('day')->select();
return $this->assembleDayRecords($items, $dayList, 'amount');
}

@ -711,8 +711,8 @@ class QueryController extends BaseController
'registerCount' => $registerCountList[$day],
'payRate' => $loginCountList[$day] == 0 ? '--' : round($payUserCountList[$day]/$loginCountList[$day]*100, 2) . '%',
'ratentionOneDay' => '--',
'arpu' => $loginCountList[$day] == 0 ? '0.00' : number_format(round($payAmount[$day]/$loginCountList[$day], 2), 2),
'arppu' => $payUserCount[$day] == 0 ? '0.00' : number_format(round($payAmount[$day]/$payUserCount[$day], 2), 2),
'arpu' => $loginCountList[$day] == 0 ? '0.00' : number_format(round($payAmountList[$day]/$loginCountList[$day], 2), 2),
'arppu' => $payUserCountList[$day] == 0 ? '0.00' : number_format(round($payAmountList[$day]/$payUserCountList[$day], 2), 2),
];
}
} else {
@ -1852,7 +1852,7 @@ class QueryController extends BaseController
$promotes = $this->getNormalPromotes($promote);
}
$map = $spendMap = ['promote_id' => ['in' => $ids]];
$map = $spendMap = ['promote_id' => ['in', $ids]];
if ($gameId != 0) {
$map['game_id'] = $gameId;
}
@ -1966,7 +1966,7 @@ class QueryController extends BaseController
public function getGameServers()
{
$gameId = I('game_id', 0);
$servers = M('server', 'tab_')->field(['id', 'server_name'])->where(['game_id' => $gameId])->select();
$servers = M('server', 'tab_')->field(['id', 'server_id', 'server_name'])->where(['game_id' => $gameId])->select();
$this->ajaxReturn([
'status' => 1,
'msg' => '成功',

@ -178,7 +178,7 @@ $(function() {
if (defaultServerId > 0 && server.id==defaultServerId) {
selected = 'selected'
}
options += '<option value="' + server.id + '"' + selected + '>' + server.server_name + '</option>'
options += '<option value="' + server.server_id + '"' + selected + '>' + server.server_name + '</option>'
}
$('#server-select').html(options)
$("#server-select").val(defaultServerId).trigger("change")

@ -166,7 +166,7 @@ $(function(){
if (defaultServerId > 0 && server.id==defaultServerId) {
selected = 'selected'
}
options += '<option value="' + server.id + '"' + selected + '>' + server.server_name + '</option>'
options += '<option value="' + server.server_id + '"' + selected + '>' + server.server_name + '</option>'
}
$('#server-select').html(options)
$("#server-select").val(defaultServerId).trigger("change")

@ -170,7 +170,7 @@ $(function() {
if (defaultServerId > 0 && server.id==defaultServerId) {
selected = 'selected'
}
options += '<option value="' + server.id + '"' + selected + '>' + server.server_name + '</option>'
options += '<option value="' + server.server_id + '"' + selected + '>' + server.server_name + '</option>'
}
$('#server-select').html(options)
$("#server-select").val(defaultServerId).trigger("change")

@ -137,3 +137,4 @@ CREATE TABLE `tab_test_resource` (
alter table tab_user_play_info add column `create_time` int(11) NOT NULL DEFAULT '0' COMMENT '角色创建时间';
alter table tab_user_play_info add column `create_ip` varchar(16) NOT NULL DEFAULT '' COMMENT '角色创建IP';
alter table tab_user_play_info add column `create_device_number` varchar(50) NOT NULL DEFAULT '' COMMENT '角色创建设备号';
alter table tab_server add column `server_id` varchar(50) not NULL default '' COMMENT '对接区服id';

Loading…
Cancel
Save