fix bugs for task #610 and task #619.

This commit is contained in:
shiyangyangwork@yahoo.cn
2011-12-05 09:23:40 +00:00
parent 93c38e29d2
commit 34f44000cd
4 changed files with 15 additions and 1 deletions

View File

@@ -63,6 +63,7 @@ $lang->action->desc->activated = '$date, Activated by <strong>$actor</strong>.
$lang->action->desc->moved = '$date, Moved by <strong>$actor</strong>, previouse is "$extra"';
$lang->action->desc->confirmed = '$date, Confirmed by <strong>$actor</strong>, version is<strong>#$extra</strong>';
$lang->action->desc->bugconfirmed= '$date, Confirmed by <strong>$actor</strong>';
$lang->action->desc->frombug = '$date, From Bug by <strong>$actor</strong> BugID:<strong>$extra</strong>。';
$lang->action->desc->started = '$date, Started by <strong>$actor</strong>.';
$lang->action->desc->canceled = '$date, Canceled by <strong>$actor</strong>.';
$lang->action->desc->svncommited = '$date, <strong>$actor</strong> commited to svnrevision is <strong>#$extra</strong>' . "\n";

View File

@@ -63,6 +63,7 @@ $lang->action->desc->activated = '$date, 由 <strong>$actor</strong> 激活。
$lang->action->desc->moved = '$date, 由 <strong>$actor</strong> 移动,之前为 "$extra"' . "\n";
$lang->action->desc->confirmed = '$date, 由 <strong>$actor</strong> 确认需求变动,最新版本为<strong>#$extra</strong>' . "\n";
$lang->action->desc->bugconfirmed= '$date, 由 <strong>$actor</strong> 确认Bug' . "\n";
$lang->action->desc->frombug = '$date, 由 <strong>$actor</strong> Bug转化而来Bug编号为 <strong>$extra</strong>。';
$lang->action->desc->started = '$date, 由 <strong>$actor</strong> 启动。' . "\n";
$lang->action->desc->canceled = '$date, 由 <strong>$actor</strong> 取消。' . "\n";
$lang->action->desc->svncommited = '$date, <strong>$actor</strong> 提交代码,版本为<strong>#$extra</strong>' . "\n";

View File

@@ -242,6 +242,14 @@ class bugModel extends model
$storySpec->title = $oldBug->title;
$storySpec->spec = $oldBug->steps;
$this->dao->insert(TABLE_STORYSPEC)->data($storySpec)->exec();
$actionID = $this->loadModel('action')->create('story', $storyID, 'Frombug', '', $bugID);
$file = $this->dao->select('*')->from(TABLE_FILE)->where('objectType')->eq('bug')->andWhere('objectID')->eq($bugID)->fetch();
$file->objectType = 'story';
$file->objectID = $storyID;
unset($file->id);
$this->dao->insert(TABLE_FILE)->data($file)->exec();
}
$bug = fixer::input('post')

View File

@@ -42,7 +42,11 @@ $(function(){
<th class='rowhead'><?php echo $lang->testcase->lblStory;?></th>
<td>
<?php echo html::select('story', $stories, $storyID, 'class="text-1" onchange=setPreview();');?>
<?php if($storyID == 0): ?>
<a href='' id='preview' class='iframe'><?php echo $lang->preview;?></a>
<?php else:?>
<?php echo html::a($this->createLink('story', 'view', "storyID=$storyID"), $lang->preview, '', "class='iframe' id='preview'");?>
<?php endif;?>
</td>
</tr>
<tr>
@@ -51,7 +55,7 @@ $(function(){
</tr>
<tr>
<th class='rowhead'><?php echo $lang->testcase->precondition;?></th>
<td><?php echo html::textarea('precondition', $precondition, " rows='4' class='w-p100'");?></td>
<td><?php echo html::textarea('precondition', $precondition, " rows='4' class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->testcase->steps;?></th>