作者 王智

baoxiu22

@@ -107,7 +107,6 @@ class Dashboard extends Backend @@ -107,7 +107,6 @@ class Dashboard extends Backend
107 } 107 }
108 108
109 109
110 -  
111 public function exportDayInner() 110 public function exportDayInner()
112 { 111 {
113 //月 起止时间戳 112 //月 起止时间戳
@@ -156,7 +155,7 @@ class Dashboard extends Backend @@ -156,7 +155,7 @@ class Dashboard extends Backend
156 $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(12); 155 $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(12);
157 //输出表格 156 //输出表格
158 foreach ($data as $key => &$val) { 157 foreach ($data as $key => &$val) {
159 - $count = Db::name('applet_answer')->where(['uid' => $val['id'], 'isdelete' => 0])->count(); 158 + $count = count($data);
160 $i = $key + 2;//表格是从2开始的 159 $i = $key + 2;//表格是从2开始的
161 if ($count >= 1) { 160 if ($count >= 1) {
162 $objPHPExcel->getActiveSheet()->setCellValue('A' . $i, $val['zhandian_name']); 161 $objPHPExcel->getActiveSheet()->setCellValue('A' . $i, $val['zhandian_name']);