Merge branch 'master' of github.com:easysoft/zentaopms

This commit is contained in:
wangyidong
2016-04-01 16:25:17 +08:00
3 changed files with 22 additions and 1 deletions
+5
View File
@@ -24,6 +24,11 @@ $config->testcase->exportFields = '
pri, type, stage, status, lastRunResult, openedBy, openedDate,
lastEditedBy, lastEditedDate, version,linkCase';
$config->testcase->customCreateFields = 'stage,story,keywords';
$config->testcase->custom = new stdclass();
$config->testcase->custom->create = $config->testcase->customCreateFields;
global $lang;
$config->testcase->search['module'] = 'testcase';
$config->testcase->search['fields']['title'] = $lang->testcase->title;
+5
View File
@@ -286,6 +286,11 @@ class testcase extends control
}
$stories = $this->story->getProductStoryPairs($productID, $branch, $modules, array_keys($storyStatus), 'id_desc', 50);
/* Set custom. */
foreach(explode(',', $this->config->testcase->customCreateFields) as $field) $customFields[$field] = $this->lang->testcase->$field;
$this->view->customFields = $customFields;
$this->view->showFields = $this->config->testcase->custom->create;
$this->view->title = $title;
$this->view->caseTitle = $caseTitle;
$this->view->position = $position;
+12 -1
View File
@@ -21,6 +21,9 @@
<span class='prefix'><?php echo html::icon($lang->icons['testcase']);?></span>
<strong><small class='text-muted'><?php echo html::icon($lang->icons['create']);?></small> <?php echo $lang->testcase->create;?></strong>
</div>
<div class='actions'>
<button type='button' class='btn btn-default' data-toggle='customModal'><i class='icon icon-cog'></i></button>
</div>
</div>
<form class='form-condensed' method='post' enctype='multipart/form-data' id='dataform' data-type='ajax'>
<table class='table table-form'>
@@ -51,13 +54,16 @@
<tr>
<th><?php echo $lang->testcase->type;?></th>
<td><?php echo html::select('type', $lang->testcase->typeList, $type, "class='form-control chosen'");?></td>
<?php if(strpos(",$showFields,", 'stage') !== false):?>
<td style='padding-left:15px'>
<div class='input-group'>
<span class='input-group-addon'><?php echo $lang->testcase->stage?></span>
<?php echo html::select('stage[]', $lang->testcase->stageList, $stage, "class='form-control chosen' multiple='multiple'");?>
</div>
</td>
</tr>
<?php endif;?>
</tr>
<?php if(strpos(",$showFields,", ',story,') !== false):?>
<tr>
<th><?php echo $lang->testcase->lblStory;?></th>
<td colspan='2'>
@@ -73,6 +79,7 @@
</div>
</td>
</tr>
<?php endif;?>
<tr>
<th><?php echo $lang->testcase->title;?></th>
<td colspan='2'>
@@ -133,10 +140,12 @@
</table>
</td>
</tr>
<?php if(strpos(",$showFields,", ',keywords,') !== false):?>
<tr>
<th><?php echo $lang->testcase->keywords;?></th>
<td colspan='2'><?php echo html::input('keywords', $keywords, "class='form-control'");?></td>
</tr>
<?php endif;?>
<tr>
<th><?php echo $lang->testcase->files;?></th>
<td colspan='2'><?php echo $this->fetch('file', 'buildform');?></td>
@@ -164,5 +173,7 @@
</div>
</div>
</div>
<?php $customLink = $this->createLink('custom', 'ajaxSaveCustom', 'module=testcase&section=custom&key=create');?>
<?php include '../../common/view/customfield.html.php';?>
<?php js::set('caseModule', $lang->testcase->module)?>
<?php include '../../common/view/footer.html.php';?>