作者 开飞机的舒克

后台大屏管理功能优化

@@ -85,9 +85,8 @@ class Screen extends Backend @@ -85,9 +85,8 @@ class Screen extends Backend
85 } 85 }
86 $data = $row->toArray(); 86 $data = $row->toArray();
87 $res = db('study_score_log l') 87 $res = db('study_score_log l')
88 - ->join('team t', 'l.team = t.title')  
89 ->where('campus_id', $data['campus_id']) 88 ->where('campus_id', $data['campus_id'])
90 - ->field('l.team,sum(l.score) as sum_score,t.title') 89 + ->field('l.team,sum(l.score) as sum_score')
91 ->group('l.team') 90 ->group('l.team')
92 ->order('sum_score', 'desc') 91 ->order('sum_score', 'desc')
93 ->limit(4) 92 ->limit(4)
@@ -95,7 +94,7 @@ class Screen extends Backend @@ -95,7 +94,7 @@ class Screen extends Backend
95 $list = []; 94 $list = [];
96 foreach ($res as $k => $v) { 95 foreach ($res as $k => $v) {
97 $list[] = [ 96 $list[] = [
98 - 'title' => $v['title'], 97 + 'title' => $v['team'],
99 'score' => $v['sum_score'], 98 'score' => $v['sum_score'],
100 ]; 99 ];
101 } 100 }
@@ -6197,7 +6197,7 @@ @@ -6197,7 +6197,7 @@
6197 6197
6198 </div> 6198 </div>
6199 <div class="col-md-6" align="right"> 6199 <div class="col-md-6" align="right">
6200 - Generated on 2023-04-08 11:05:06 <a href="./" target="_blank">校园活动</a> 6200 + Generated on 2023-04-08 14:15:12 <a href="./" target="_blank">校园活动</a>
6201 </div> 6201 </div>
6202 </div> 6202 </div>
6203 6203