Browse Source

修正任务列表分页只能显示10条的bug

修正任务列表分页只能显示10条的bug
mylxsw 9 years ago
parent
commit
02e7b8cc0d
1 changed files with 1 additions and 1 deletions
  1. 1 1
      controllers/TaskController.php

+ 1 - 1
controllers/TaskController.php

@@ -33,7 +33,7 @@ class TaskController extends Controller {
             $list->andWhere(['or', "commit_id like '%" . $kw . "%'", "title like '%" . $kw . "%'"]);
         }
         $tasks = $list->orderBy('id desc');
-        $list = $tasks->offset(($page - 1) * $size)->limit(10)
+        $list = $tasks->offset(($page - 1) * $size)->limit($size)
             ->asArray()->all();
 
         $pages = new Pagination(['totalCount' => $tasks->count(), 'pageSize' => 10]);