From a9fb429c6e1f445158a8c5cd663d297b269eeab5 Mon Sep 17 00:00:00 2001 From: sunguangming Date: Fri, 7 Nov 2025 08:54:29 +0800 Subject: [PATCH] * [bug#66932,done,0.2h] fix bug. --- module/upgrade/tao.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/module/upgrade/tao.php b/module/upgrade/tao.php index 7253c79a39..a68a73101d 100644 --- a/module/upgrade/tao.php +++ b/module/upgrade/tao.php @@ -1131,10 +1131,17 @@ class upgradeTao extends upgradeModel $deliverableID = $this->dao->lastInsertID(); $idMap[$output->id] = $deliverableID; - $this->dao->update(TABLE_PROGRAMOUTPUT)->set('output')->eq($deliverableID)->set('activity')->eq($output->activity)->where('id')->eq($output->id)->exec(); } $projectIdList = $this->dao->select('id')->from(TABLE_PROJECT)->where('workflowGroup')->eq($group->id)->fetchPairs(); + + $projectOutputList = $this->dao->select('id,output')->from(TABLE_PROGRAMOUTPUT)->where('project')->in($projectIdList)->andWhere('output')->in(array_keys($idMap))->fetchPairs(); + foreach($projectOutputList as $id => $outputID) + { + $newID = $idMap[$outputID]; + $this->dao->update(TABLE_PROGRAMOUTPUT)->set('output')->eq($newID)->where('id')->eq($id)->exec(); + } + $auditplans = $this->dao->select('id,objectID')->from(TABLE_AUDITPLAN) ->where('objectType')->eq('zoutput') ->andWhere('objectID')->in(array_keys($idMap))