增加注释

master
liuweiwen 5 years ago
parent 7f57b53646
commit 4ed57dcda1

@ -982,6 +982,7 @@ class FinanceController extends ThinkController
*/
public function payTypeStatistics()
{
//获取现金充值
$cashStatistics = M('spend', 'tab_')
->field('pay_way,SUM(pay_amount) AS pay_amount')
->where(['pay_status' => 1])
@ -993,6 +994,7 @@ class FinanceController extends ThinkController
}
$cashStatistics = array_column($cashStatistics, null, 'pay_way');
// dd($cashStatistics);
//获取平台币充值
$deposit = M('deposit', 'tab_')->where([
'deposit' => 2,
'pay_status' => 1,
@ -1004,9 +1006,9 @@ class FinanceController extends ThinkController
if (!array_key_exists($value['pay_way'], $cashStatistics)) {
$cashStatistics[$value['pay_way']] = $value;
$cashStatistics[$value['pay_way']]['pay_amount'] = '0.00';
$cashStatistics[$value['pay_way']]['pay_type'] = getPayType($value['pay_way']);
$cashStatistics[$value['pay_way']]['pay_type'] = getPayType($value['pay_way']);//充值方式文字影视
}
$cashStatistics[$value['pay_way']]['balance'] = $value['balance'];
$cashStatistics[$value['pay_way']]['balance'] = $value['balance'];//别表的平台币充值
}
foreach ($cashStatistics as $key => $value) {
$cashStatistics[$key]['total'] = $value['pay_amount'] + $value['balance'];//添加列表合计

Loading…
Cancel
Save