修正测试服订单检索错误问题

master
chenzhi 5 years ago
parent 33be2ba05b
commit f3a662324d

@ -22,7 +22,7 @@ class TestOrderController extends ThinkController
$map['1'] = "1";
if (!empty($_REQUEST['server_type'])) {
$map['server_type'] = $_REQUEST['server_type'];
$map['t.server_type'] = $_REQUEST['server_type'];
}
if (!empty($_REQUEST['order_type'])||$_REQUEST['order_type'] == '0') {
$map['order_type'] = $_REQUEST['order_type'];
@ -55,8 +55,8 @@ class TestOrderController extends ThinkController
$v['game_name'] =clearGameNameType($v['game_name']);
$v['sdk_version'] =getGameTypeName($v['sdk_version']);
}
$sum_order_amount = M('test_order', 'tab_')->where($map)->field('sum(order_amount) as sum_order_amount,count(1) as count')->find();
$sum_pay_amount = M('test_order', 'tab_')->where($map)->field('sum(pay_amount) as sum_order_amount')->find();
$sum_order_amount = M('test_order', 'tab_')->alias("t")->where($map)->field('sum(order_amount) as sum_order_amount,count(1) as count')->find();
$sum_pay_amount = M('test_order', 'tab_')->alias("t")->where($map)->field('sum(pay_amount) as sum_order_amount')->find();
$count = $sum_order_amount['count'];
$page = set_pagination($count, $row);

Loading…
Cancel
Save