name : (isset($branch) ? $branch : $module->name);
$removeType = isset($product) ? 'byproduct' : (isset($branch) ? 'bybranch' : 'bymodule');
$removeLink = inlink('story', "executionID=$execution->id&storyType=$storyType&orderBy=$orderBy&type=$removeType¶m=0&recTotal=0&recPerPage={$pager->recPerPage}");
$removeBtn = html::a($removeLink, "", '', "class='text-muted'");
}
?>
execution->featureBar['story'] as $featureType => $label):?>
$label";?>
{$pager->recTotal}";?>
id&storyType=$storyType&orderBy=order_desc&type=$featureType"), $label, '', "class='btn btn-link $active'");?>
product->searchStory;?>
createLink('execution', 'story', "executionID=$execution->id&storyType=$storyType&orderBy=order_desc&type=all"), " ", '', "class='btn btn-icon text-primary switchBtn' title='{$lang->execution->list}' data-type='bylist'");?>
createLink('execution', 'storykanban', "executionID=$execution->id"), " ", '', "class='btn btn-icon switchBtn' title='{$lang->execution->kanban}' data-type='bykanban'");?>
id", '', 'button', 'bar-chart muted');
common::printLink('story', 'export', "productID=$productID&orderBy=id_desc&executionID=$execution->id&browseType=$type&storyType=$storyType", " " . $lang->story->export, '', "class='btn btn-link export iframe' data-width=620");
$canLinkStory = ($execution->hasProduct or $execution->multiple);
if(common::canModify('execution', $execution))
{
$this->lang->story->create = $this->lang->execution->createStory;
if($productID)
{
$storyModuleID = (int)$this->cookie->storyModuleParam;
$createStoryLink = $this->createLink('story', 'create', "productID=$productID&branch=0&moduleID={$storyModuleID}&story=0&execution=$execution->id&bugID=0&planID=0&todoID=0&extra=&storyType=$storyType");
$batchCreateLink = $this->createLink('story', 'batchCreate', "productID=$productID&branch=0&moduleID={$storyModuleID}&story=0&execution=$execution->id&plan=0&storyType=$storyType");
$buttonLink = '';
$buttonTitle = '';
if(common::hasPriv('story', 'batchCreate'))
{
$buttonLink = $batchCreateLink;
$buttonTitle = $lang->story->batchCreate;
}
if(common::hasPriv('story', 'create'))
{
$buttonLink = $createStoryLink;
$buttonTitle = $lang->story->create;
}
$hidden = empty($buttonLink) ? 'hidden' : '';
echo "";
echo html::a($buttonLink, " $buttonTitle", '', "class='btn btn-secondary $hidden' data-app='$app->tab'");
if($common::hasPriv('story', 'create') and common::hasPriv('story', 'batchCreate'))
{
if(!($isAllProduct and count($products) > 1)) echo "";
echo "
';
}
if(commonModel::isTutorialMode())
{
$wizardParams = helper::safe64Encode("execution=$execution->id");
echo html::a($this->createLink('tutorial', 'wizard', "module=execution&method=linkStory¶ms=$wizardParams"), " {$lang->execution->linkStory}",'', "class='btn btn-link link-story-btn'");
}
elseif($canLinkStory) // The none-product and single execution cann't link stories.
{
echo "- ";
echo '
- ' . html::a($createStoryLink, $lang->story->create, '', "data-app=$app->tab") . ' '; echo '
- ' . html::a($batchCreateLink, $lang->story->batchCreate, '', "data-app=$app->tab") . ' '; echo '
";
$buttonLink = '';
$buttonTitle = '';
$dataToggle = '';
if(common::hasPriv('execution', 'importPlanStories'))
{
$buttonLink = '#linkStoryByPlan';
$buttonTitle = $lang->execution->linkStoryByPlan;
$dataToggle = 'data-toggle="modal"';
}
if(common::hasPriv('execution', 'linkStory'))
{
$buttonLink = inlink('linkStory', "execution=$execution->id");
$buttonTitle = $lang->execution->linkStory;
$dataToggle = '';
}
$hidden = empty($buttonLink) ? 'hidden' : '';
echo html::a($buttonLink, " $buttonTitle", '', "class='btn btn-primary $hidden' $dataToggle");
if(common::hasPriv('execution', 'linkStory') and common::hasPriv('execution', 'importPlanStories') and ($execution->hasProduct or $execution->type == 'sprint'))
{
echo "";
echo "
';
}
}
?>
- ";
echo '
- ' . html::a(inlink('linkStory', "execution=$execution->id"), $lang->execution->linkStory). " "; echo '
- ' . html::a('#linkStoryByPlan', $lang->execution->linkStoryByPlan, '', 'data-toggle="modal"') . " "; echo '