|
|
|
@ -626,7 +626,7 @@ class FinancialSummarySetController extends \Think\Controller
|
|
|
|
|
|
|
|
|
|
$sql = "{$data} UNION ALL {$coinData} UNION ALL {$officalData} UNION ALL {$spreadData} UNION ALL {$superSignData} UNION ALL {$testOrder}";
|
|
|
|
|
|
|
|
|
|
$data = M()->table("({$sql})a")
|
|
|
|
|
$data = M()->db(0)->table("({$sql})a")
|
|
|
|
|
->field("sum(cash_amount) cash_amount,sum(test_amount) test_amount,
|
|
|
|
|
sum(coin_amount) coin_amount,sum(offcial_amount) offcial_amount,
|
|
|
|
|
sum(spread_amount) spread_amount,sum(supersign_amount) supersign_amount,
|
|
|
|
@ -635,9 +635,7 @@ class FinancialSummarySetController extends \Think\Controller
|
|
|
|
|
->where("name is not null")
|
|
|
|
|
->group("merchant_id")
|
|
|
|
|
->select();
|
|
|
|
|
|
|
|
|
|
foreach ($data as $key => $value) {
|
|
|
|
|
|
|
|
|
|
$sum = $value['cash_amount']+$value['test_amount']+$value['coin_amount']+
|
|
|
|
|
$value['offcial_amount']+$value['spread_amount']+$value['supersign_amount']+$value['test_order_amount'];
|
|
|
|
|
$this->adddata[] = array(
|
|
|
|
|