* Do task #69018.
This commit is contained in:
@@ -309,6 +309,11 @@ class product extends control
|
||||
|
||||
$productName = ($this->app->rawModule == 'projectstory' and empty($productID)) ? $this->lang->product->all : $this->products[$productID];
|
||||
|
||||
$project = $this->loadModel('project')->getByID($projectID);
|
||||
|
||||
if(empty($project->hasProduct)) unset($this->config->product->search['fields']['product']);
|
||||
var_dump(empty($project->hasProduct));
|
||||
|
||||
/* Assign. */
|
||||
$this->view->title = $productName . $this->lang->colon . $this->lang->product->browse;
|
||||
$this->view->position[] = $productName;
|
||||
@@ -347,7 +352,7 @@ class product extends control
|
||||
$this->view->storyType = $storyType;
|
||||
$this->view->from = $this->app->tab;
|
||||
$this->view->modulePairs = $showModule ? $this->tree->getModulePairs($productID, 'story', $showModule) : array();
|
||||
$this->view->project = $this->loadModel('project')->getByID($projectID);
|
||||
$this->view->project = $project;
|
||||
$this->display();
|
||||
}
|
||||
|
||||
|
||||
@@ -59,6 +59,7 @@ $projectIDParam = $isProjectStory ? "projectID=$projectID&" : '';
|
||||
<?php endif;?>
|
||||
<div class="btn-toolbar pull-left">
|
||||
<?php if($isProjectStory): ?>
|
||||
<?php if(!empty($project->hasProduct)):?>
|
||||
<div class='btn-group'>
|
||||
<a href='javascript:;' class='btn btn-link btn-limit text-ellipsis' data-toggle='dropdown' style="max-width: 120px;"><span class='text' title='<?php echo $productName;?>'><?php echo $productName;?></span> <span class='caret'></span></a>
|
||||
<ul class='dropdown-menu' style='max-height:240px; max-width: 300px; overflow-y:auto'>
|
||||
@@ -71,6 +72,7 @@ $projectIDParam = $isProjectStory ? "projectID=$projectID&" : '';
|
||||
?>
|
||||
</ul>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
<div class="btn-group">
|
||||
<a href="javascript:;" class="btn btn-link" style="padding-right: 0;"> <?php echo $moduleName;?> </a>
|
||||
<?php
|
||||
|
||||
Reference in New Issue
Block a user