@ -164,6 +164,12 @@ class FinanceController extends ThinkController
$sum = D('spend')->sumSpend($map,'pay_amount');
$count = D("spend")->getSpendData($map,$field,$group,$order);
$count = count($count);
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
$this->assign('data',$data);
$this->assign('sum_amount',$sum);
@ -755,6 +755,7 @@ protected function _after_select(&$result,$options){
public function sumSpend($map=[],$field='') {
$sum = $this->where($map)->sum($field);
return $sum;
}