This commit is contained in:
zhouxin
2022-04-08 07:33:19 +00:00
parent a56b1a77c9
commit 30af3cd8ee
3 changed files with 12 additions and 0 deletions
+1
View File
@@ -284,6 +284,7 @@ $lang->story->estimateMustBeNumber = 'Estimate value must be number.';
$lang->story->estimateMustBePlus = 'Estimated value cannot be negative';
$lang->story->confirmChangeBranch = $lang->SRCommon . ' %s is linked to the plan of its linked branch. If the branch is edited, ' . $lang->SRCommon . ' will be removed from the plan of its linked branch. Do you want to continue edit ' . $lang->SRCommon . '?';
$lang->story->confirmChangePlan = $lang->SRCommon . ' %s is linked to the branch of its plan. If the branch is edited, ' . $lang->SRCommon . ' will be removed from the plan. Do you want to continue edit branch ?';
$lang->story->errorDuplicateStory = $lang->SRCommon . '%s not exist';
$lang->story->form = new stdclass();
$lang->story->form->area = 'Scope';
+1
View File
@@ -284,6 +284,7 @@ $lang->story->estimateMustBeNumber = '估算值必须是数字';
$lang->story->estimateMustBePlus = '估算值不能是负数';
$lang->story->confirmChangeBranch = $lang->SRCommon . '%s已关联在之前所属分支的计划中,调整分支后,' . $lang->SRCommon . '将从之前所属分支的计划中移除,请确认是否继续修改上述' . $lang->SRCommon . '的分支。';
$lang->story->confirmChangePlan = $lang->SRCommon . '%s已关联在之前计划的所属分支中,调整分支后,' . $lang->SRCommon . '将会从计划中移除,请确认是否继续修改计划的所属分支。';
$lang->story->errorDuplicateStory = $lang->SRCommon . '%s不存在';
$lang->story->form = new stdclass();
$lang->story->form->area = "{$lang->SRCommon}所属范围";
+10
View File
@@ -1553,6 +1553,16 @@ class storyModel extends model
->removeIF($this->post->closedReason != 'subdivided', 'childStories')
->get();
if(!empty($story->duplicateStory))
{
$duplicateStoryID = $this->dao->select('id')->from(TABLE_STORY)->where('id')->eq($story->duplicateStory)->fetch();
if(empty($duplicateStoryID))
{
dao::$errors[] = sprintf($this->lang->story->errorDuplicateStory, $story->duplicateStory);
return false;
}
}
$this->lang->story->comment = $this->lang->comment;
$this->dao->update(TABLE_STORY)->data($story, 'comment')
->autoCheck()