This commit is contained in:
tianshujie
2022-07-22 12:03:23 +08:00
parent 5818db887f
commit 29a889ddcf
5 changed files with 11 additions and 11 deletions

View File

@@ -131,7 +131,7 @@ function setStories()
productID = $('#product').val();
branch = $('#branch').val();
if(typeof(branch) == 'undefined') branch = 0;
link = createLink('story', 'ajaxGetProductStories', 'productID=' + productID + '&branch=' + branch + '&moduleID=' + moduleID + '&storyID=0&onlyOption=false&status=noclosed&limit=50&type=full&hasParent=1&executionID=' + executionID);
link = createLink('story', 'ajaxGetProductStories', 'productID=' + productID + '&branch=' + branch + '&moduleID=' + moduleID + '&storyID=0&onlyOption=false&status=noclosed&limit=0&type=full&hasParent=1&executionID=' + executionID);
$.get(link, function(stories)
{
@@ -141,7 +141,7 @@ function setStories()
$('#story').val(value);
$('#story_chosen').remove();
$('#story').next('.picker').remove();
$("#story").chosen();
$("#story").picker();
});
}
@@ -364,7 +364,7 @@ function loadStories(productID, moduleID, num)
{
var branchIDName = (config.currentMethod == 'batchcreate' || config.currentMethod == 'showimport') ? '#branch' : '#branches';
var branchID = $(branchIDName + num).val();
var storyLink = createLink('story', 'ajaxGetProductStories', 'productID=' + productID + '&branch=' + branchID + '&moduleID=' + moduleID + '&storyID=0&onlyOption=false&status=noclosed&limit=50&type=full&hasParent=1&executionID=0&number=' + num);
var storyLink = createLink('story', 'ajaxGetProductStories', 'productID=' + productID + '&branch=' + branchID + '&moduleID=' + moduleID + '&storyID=0&onlyOption=false&status=noclosed&limit=0&type=full&hasParent=1&executionID=0&number=' + num);
$.get(storyLink, function(stories)
{
if(!stories) stories = '<select id="story' + num + '" name="story[' + num + ']" class="form-control"></select>';
@@ -378,7 +378,7 @@ function loadStories(productID, moduleID, num)
$('#story' + i + "_chosen").remove();
$('#story' + i).next('.picker').remove();
$('#story' + i).attr('name', 'story[' + i + ']');
$('#story' + i).chosen();
$('#story' + i).picker();
}
}
else
@@ -387,7 +387,7 @@ function loadStories(productID, moduleID, num)
$('#story' + num + "_chosen").remove();
$('#story' + num).next('.picker').remove();
$('#story' + num).attr('name', 'story[' + num + ']');
$('#story' + num).chosen();
$('#story' + num).picker();
}
});
}

View File

@@ -90,7 +90,7 @@
<td class="text-center"><?php echo $i;?></td>
<td class='text-left<?php echo zget($visibleFields, $product->type, ' hidden')?> branchBox'><?php echo html::select("branch[$i]", $branches, $branch, "class='form-control' onchange='setModules(this.value, $productID, $i)'");?></td>
<td class='text-left<?php echo zget($visibleFields, 'module', ' hidden')?> moduleBox' style='overflow:visible'><?php echo html::select("module[$i]", $moduleOptionMenu, $currentModuleID, "class='form-control chosen' onchange='loadStories($productID, this.value, $i)' data-drop_direction='down'");?></td>
<td class='text-left<?php echo zget($visibleFields, 'story', ' hidden'); echo $hiddenStory;?> storyBox' style='overflow:visible'> <?php echo html::select("story[$i]", $storyPairs, $story ? $story->id : '', 'class="form-control chosen"');?></td>
<td class='text-left<?php echo zget($visibleFields, 'story', ' hidden'); echo $hiddenStory;?> storyBox' style='overflow:visible'> <?php echo html::select("story[$i]", $storyPairs, $story ? $story->id : '', 'class="form-control picker-select"');?></td>
<td style='overflow:visible'>
<div class="input-control has-icon-right">
<?php echo html::input("title[$i]", '', "class='form-control title-import'");?>
@@ -141,7 +141,7 @@
<td class="text-center">%s</td>
<td class='text-left<?php echo zget($visibleFields, $product->type, ' hidden')?> branchBox'><?php echo html::select("branch[%s]", $branches, $branch, "class='form-control chosen' onchange='setModules(this.value, $productID, \"%s\")'");?></td>
<td class='text-left<?php echo zget($visibleFields, 'module', ' hidden')?> moduleBox' style='overflow:visible'><?php echo html::select("module[%s]", $moduleOptionMenu, $currentModuleID, "class='form-control chosen' onchange='loadStories($productID, this.value, \"%s\")' data-drop_direction='down'");?></td>
<td class='text-left<?php echo zget($visibleFields, 'story', ' hidden'); echo $hiddenStory;?> storyBox' style='overflow:visible'> <?php echo html::select("story[%s]", $storyPairs, '', 'class="form-control chosen"');?></td>
<td class='text-left<?php echo zget($visibleFields, 'story', ' hidden'); echo $hiddenStory;?> storyBox' style='overflow:visible'> <?php echo html::select("story[%s]", $storyPairs, '', 'class="form-control picker-select"');?></td>
<td style='overflow:visible'>
<div class="input-control has-icon-right">
<?php echo html::input("title[%s]", '', "class='form-control title-import'");?>
@@ -180,7 +180,7 @@
<td class="text-center"><?php echo $i;?></td>
<td class='text-left<?php echo zget($visibleFields, $product->type, ' hidden')?> branchBox'><?php echo html::select("branch[$i]", $branches, $branch, "class='form-control' onchange='setModules(this.value, $productID, $i)'");?></td>
<td class='text-left<?php echo zget($visibleFields, 'module', ' hidden')?> moduleBox' style='overflow:visible'><?php echo html::select("module[$i]", $moduleOptionMenu, $currentModuleID, "class='form-control chosen' onchange='loadStories($productID, this.value, $i)' data-drop_direction='down'");?></td>
<td class='text-left<?php echo zget($visibleFields, 'story', ' hidden'); echo $hiddenStory;?> storyBox' style='overflow:visible'> <?php echo html::select("story[$i]", $storyPairs, $story ? $story->id : '', 'class="form-control chosen"');?></td>
<td class='text-left<?php echo zget($visibleFields, 'story', ' hidden'); echo $hiddenStory;?> storyBox' style='overflow:visible'> <?php echo html::select("story[$i]", $storyPairs, $story ? $story->id : '', 'class="form-control picker-select"');?></td>
<td style='overflow:visible'>
<div class="input-control has-icon-right">
<?php echo html::input("title[$i]", '', "class='form-control title-import'");?>

View File

@@ -97,7 +97,7 @@
</td>
<?php endif;?>
<td class='text-left<?php echo zget($visibleFields, 'module', ' hidden')?>' style='overflow:visible'><?php echo html::select("modules[$caseID]", zget($modulePairs, $caseID, array(0 => '/')), $cases[$caseID]->module, "class='form-control chosen' onchange='loadStories($productID, this.value, $caseID)'");?></td>
<td class='text-left<?php echo zget($visibleFields, 'story', ' hidden')?>' style='overflow:visible'><?php echo html::select("story[$caseID]", $stories, $cases[$caseID]->story, "class='form-control chosen'");?></td>
<td class='text-left<?php echo zget($visibleFields, 'story', ' hidden')?>' style='overflow:visible'><?php echo html::select("story[$caseID]", $stories, $cases[$caseID]->story, "class='form-control picker-select'");?></td>
<td style='overflow:visible' title='<?php echo $cases[$caseID]->title?>'>
<div class='input-group'>
<div class="input-control has-icon-right">

View File

@@ -84,7 +84,7 @@ foreach(explode(',', $config->testcase->create->requiredFields) as $field)
<th><?php echo $lang->testcase->lblStory;?></th>
<td colspan='2'>
<div class='input-group' id='storyIdBox'>
<?php echo html::select('story', $stories, $storyID, 'class="form-control chosen" onchange="setPreview();" data-no_results_text="' . $lang->searchMore . '"');?>
<?php echo html::select('story', $stories, $storyID, 'class="form-control picker-select" onchange="setPreview();" data-no_results_text="' . $lang->searchMore . '"');?>
<span class='input-group-btn' style='width: 0.01%'>
<?php if($storyID == 0): ?>
<a href='' id='preview' class='btn hidden'><?php echo $lang->preview;?></a>

View File

@@ -204,7 +204,7 @@
<?php if(!$isLibCase):?>
<tr>
<th><?php echo $lang->testcase->story;?></th>
<td class='text-left'><div id='storyIdBox'><?php echo html::select('story', $stories, $case->story, 'class="form-control chosen"');?></div>
<td class='text-left'><div id='storyIdBox'><?php echo html::select('story', $stories, $case->story, 'class="form-control picker-select"');?></div>
</td>
</tr>
<?php endif;?>