From ece1f6540cb042f67a470837486078338de41d4c Mon Sep 17 00:00:00 2001 From: mkm <727897186@qq.com> Date: Tue, 9 Jan 2024 11:38:20 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/common/Model/TaskStages.php | 2 +- application/project/controller/Task.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/application/common/Model/TaskStages.php b/application/common/Model/TaskStages.php index c23fde2..72f26a8 100755 --- a/application/common/Model/TaskStages.php +++ b/application/common/Model/TaskStages.php @@ -82,7 +82,7 @@ class TaskStages extends CommonModel !$joinTaskMember && $taskModel->leftJoin('task_member tm', 't.code = tm.task_code'); $taskModel = $taskModel->whereIn('tm.member_code', $joiner); } - $list = $taskModel->order('t.sort asc,t.id asc')->field('id', true)->select(); + $list = $taskModel->order('t.sort asc,t.id asc')->field('id', true)->select(); if ($list) { $taskMemberList = []; foreach ($list as &$task) { diff --git a/application/project/controller/Task.php b/application/project/controller/Task.php index 66fed00..3d93e10 100755 --- a/application/project/controller/Task.php +++ b/application/project/controller/Task.php @@ -97,7 +97,7 @@ class Task extends BasicApi $taskInfo = \app\common\Model\Task::get($task['id']); $task['parentDone'] = $taskInfo['parentDone']; $task['hasUnDone'] = $taskInfo['hasUnDone']; - $task['priText'] = $status[$task['pri']]; + $task['priText'] = $status[$task['pri']??0]; $task['executor'] = Member::where(['code' => $task['assign_to']])->field('name,avatar')->find(); $task['projectInfo'] = \app\common\Model\Project::where(['code' => $task['project_code']])->field('name,code')->find(); }