From c6512b3b8d16b976346dd61b4fceedb0f713d71f Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 13 Apr 2023 08:41:27 +0800 Subject: [PATCH] * fix bug #33722. --- module/doc/control.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/module/doc/control.php b/module/doc/control.php index dfe377cb29..f77ebd5068 100755 --- a/module/doc/control.php +++ b/module/doc/control.php @@ -540,9 +540,11 @@ class doc extends control } $link = $this->session->docList ? $this->session->docList : $this->createLink('doc', 'index'); + $oldLib = $doc->lib; $doc = $this->doc->getById($docID); $lib = $this->doc->getLibById($doc->lib); $objectID = zget($lib, $lib->type, 0); + if($oldLib != $doc->lib) $link = $this->createLink('doc', 'view', "docID={$docID}"); if(!empty($objectType) and $objectType != 'doc' and $doc->type != 'chapter' and $doc->type != 'article') {