From c3d8ef7a4b20122f30dd1fba201e269a96bf9ba0 Mon Sep 17 00:00:00 2001 From: sunguangming Date: Sun, 18 Feb 2024 15:19:35 +0800 Subject: [PATCH] * Fix notice bug. --- module/story/control.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/module/story/control.php b/module/story/control.php index 8d6b30065a..2c52a22144 100755 --- a/module/story/control.php +++ b/module/story/control.php @@ -173,6 +173,13 @@ class story extends control $product = $this->product->getByID($productID); if($product) $this->lang->product->branch = sprintf($this->lang->product->branch, $this->lang->product->branchName[$product->type]); + if($storyID) + { + $story = $this->story->getByID($storyID); + $this->view->storyTitle = isset($story->title) ? $story->title : ''; + if(!$this->story->checkCanSubdivide($story, !empty($product->shadow))) return $this->send(array('result' => 'fail', 'load' => array('alert' => $this->lang->story->errorNotSubdivide))); + } + /* The 'batchCreateFields' of global variable $config will be changed and used by the following business logic. */ $customFields = $this->storyZen->getCustomFields($this->config, $storyType, $this->view->hiddenPlan, $product); $showFields = $this->storyZen->getShowFields($this->config->story->custom->batchCreateFields, $storyType, $product);