wzh 5 år sedan
förälder
incheckning
1e6d3367f3
1 ändrade filer med 1 tillägg och 1 borttagningar
  1. 1 1
      api/application/controllers/Home.php

+ 1 - 1
api/application/controllers/Home.php

@@ -369,7 +369,7 @@ class Home extends Base_Controller {
         $where1 = $where;
         $where1[] = 'L.netstatus = 1 AND L.lighteness > 0';
         $where1 = 'where '.implode(' AND ', $where1);
-        if ($type == 7) {
+        if ($type == 5) {
             $query = 'select t1.total,t1.id from (select count(*) as total,'.$fields.' from lampinfo AS L left join project AS P on P.id = L.projectid left join global_location G on P.cityid = G.id '.$where1.' '.$group.') as t1 order by total DESC limit 10';
         }else{
             $query = 'select t1.total,C.id from (select count(*) as total,'.$fields.' from lampinfo AS L left join project AS P on P.id = L.projectid left join global_location G on P.cityid = G.id '.$where1.' '.$group.') as t1 left join company as C on t1.company = C.id order by total DESC limit 10';