From 656f5e39f6537d9660838969ed6c1955c3ad78fa Mon Sep 17 00:00:00 2001 From: tianshujie Date: Fri, 3 Nov 2023 13:28:14 +0800 Subject: [PATCH] * Fix issues of the batch review stories. --- module/story/model.php | 2 +- module/story/ui/affected.html.php | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/module/story/model.php b/module/story/model.php index 9631588c1b..c11e7063bd 100644 --- a/module/story/model.php +++ b/module/story/model.php @@ -1133,7 +1133,7 @@ class storyModel extends model } $this->dao->update(TABLE_STORY)->data($story, 'finalResult')->autoCheck()->where('id')->eq($storyID)->exec(); - $this->setStage($storyID); + $this->setStage((int)$storyID); $story->id = $storyID; $this->recordReviewAction($story, $result, $reason); diff --git a/module/story/ui/affected.html.php b/module/story/ui/affected.html.php index 06b6518075..009db2cc6e 100644 --- a/module/story/ui/affected.html.php +++ b/module/story/ui/affected.html.php @@ -10,7 +10,11 @@ $getAffectedTabs = function($story, $users) foreach($story->executions as $executionID => $execution) { $teams = ''; - foreach($story->teams[$executionID] as $member) $teams .= zget($users, $member) . ' '; + if(isset($story->teams[$executionID])) + { + foreach($story->teams[$executionID] as $member) $teams .= zget($users, $member) . ' '; + } + $affectedTaskCount += count(zget($story->tasks, $executionID, array())); $affectedProjects[] = h6 (