diff --git a/module/story/control.php b/module/story/control.php index 1ea55fed84..62e802784b 100644 --- a/module/story/control.php +++ b/module/story/control.php @@ -49,6 +49,11 @@ class story extends control $actionID = $this->action->create('story', $storyID, 'Frombug', '', $bugID); } $this->sendMail($storyID, $actionID); + if($this->post->newStory) + { + echo js::alert($this->lang->story->successSaved . $this->lang->story->newStory); + die(js::locate($this->createLink('story', 'create', "productID=$productID&moduleID=$moduleID&story=$storyID&projectID=$projectID&bugID=$bugID"), 'parent')); + } if($projectID == 0) { die(js::locate($this->createLink('story', 'view', "storyID=$storyID"), 'parent')); diff --git a/module/story/lang/en.php b/module/story/lang/en.php index 9f8d464017..73022f9999 100644 --- a/module/story/lang/en.php +++ b/module/story/lang/en.php @@ -70,6 +70,7 @@ $lang->story->duplicateStory = 'Duplicate story'; $lang->story->reviewResult = 'Reviewed result'; $lang->story->preVersion = 'Pre version'; $lang->story->keywords = 'Keyword'; +$lang->story->newStory = 'Continue to add story.'; $lang->story->same = 'The same as above'; @@ -160,6 +161,8 @@ $lang->story->affectedCases = 'Affected cases'; $lang->story->specTemplate = "Recommend template::As <a type of user>,I want <some goals>,so that <some reason>."; $lang->story->notes = "(notes:if the title is empty, it is no use)"; $lang->story->needNotReview = "needn't review"; +$lang->story->afterSubmit = "After created"; +$lang->story->successSaved = "Successfully saved"; $lang->story->confirmDelete = "Are you sure to delete this story?"; $lang->story->errorFormat = 'Error format'; $lang->story->errorEmptyTitle = "Title can't be empty"; diff --git a/module/story/lang/zh-cn.php b/module/story/lang/zh-cn.php index bdb87e07e2..5e9d951219 100644 --- a/module/story/lang/zh-cn.php +++ b/module/story/lang/zh-cn.php @@ -70,6 +70,7 @@ $lang->story->duplicateStory = '重复需求'; $lang->story->reviewResult = '评审结果'; $lang->story->preVersion = '之前版本'; $lang->story->keywords = '关键词'; +$lang->story->newStory = '继续添加需求'; $lang->story->same = '同上'; @@ -160,6 +161,8 @@ $lang->story->affectedCases = '影响的用例'; $lang->story->specTemplate = "建议参考的模板:作为一名<某种类型的用户>,我希望<达成某些目的>,这样可以<开发的价值>。"; $lang->story->notes = '(注:如果“需求标题”为空,则表示不使用此行)'; $lang->story->needNotReview = '不需要评审'; +$lang->story->afterSubmit = "添加之后"; +$lang->story->successSaved = "需求成功添加,"; $lang->story->confirmDelete = "您确认删除该需求吗?"; $lang->story->errorFormat = '需求数据有误'; $lang->story->errorEmptyTitle = '标题不能为空'; diff --git a/module/story/model.php b/module/story/model.php index e5cb6e1102..41dd224c3c 100644 --- a/module/story/model.php +++ b/module/story/model.php @@ -116,7 +116,7 @@ class storyModel extends model ->setIF($this->post->plan > 0, 'stage', 'planned') ->setIF($projectID > 0, 'stage', 'projected') ->setIF($bugID > 0, 'fromBug', $bugID) - ->remove('files,labels,spec,verify,needNotReview') + ->remove('files,labels,spec,verify,needNotReview,newStory') ->get(); $this->dao->insert(TABLE_STORY)->data($story)->autoCheck()->batchCheck($this->config->story->create->requiredFields, 'notempty')->exec(); diff --git a/module/story/view/create.html.php b/module/story/view/create.html.php index c088e2edfd..d1443ce744 100644 --- a/module/story/view/create.html.php +++ b/module/story/view/create.html.php @@ -58,15 +58,18 @@ story->mailto;?> - story->keywords;?> - + story->legendAttatch;?> fetch('file', 'buildform');?> + + story->afterSubmit;?> + story->newStory);?> +