正在显示
1 个修改的文件
包含
8 行增加
和
2 行删除
@@ -34,8 +34,14 @@ class AdminStatisticsController extends AdminBaseController{ | @@ -34,8 +34,14 @@ class AdminStatisticsController extends AdminBaseController{ | ||
34 | ->field('b.hospital,count(*) as num') | 34 | ->field('b.hospital,count(*) as num') |
35 | ->join('equipment b','a.eq_name=b.name') | 35 | ->join('equipment b','a.eq_name=b.name') |
36 | ->group('b.hospital') | 36 | ->group('b.hospital') |
37 | - ->select(); | ||
38 | - dump($data); | 37 | + ->select()->toArray(); |
38 | + $hospital=array(); | ||
39 | + $num=array(); | ||
40 | + foreach ($data as $k=>$v){ | ||
41 | + $hospital[]=$v['hospital']; | ||
42 | + $num[]=$v['num']; | ||
43 | + } | ||
44 | + dump($hospital,$num); | ||
39 | 45 | ||
40 | 46 | ||
41 | //周统计 | 47 | //周统计 |
-
请 注册 或 登录 后发表评论