perf: 优化离职数据移交

This commit is contained in:
kuaifan
2024-05-31 08:54:39 +08:00
parent 6cdcd4e0dc
commit 13edea3449
8 changed files with 84 additions and 7 deletions

View File

@@ -2492,7 +2492,7 @@ class ProjectController extends AbstractController
$builder->whereTaskId($task->id);
} else {
$project = Project::userProject($project_id);
$builder->with(['projectTask:id,parent_id,name'])->whereProjectId($project->id);
$builder->with(['projectTask:id,parent_id,name'])->whereProjectId($project->id)->whereTaskOnly(0);
}
//
$list = $builder->orderByDesc('created_at')->paginate(Base::getPaginate(100, 20));