* adjust code.
This commit is contained in:
@@ -1537,10 +1537,10 @@ class project extends control
|
||||
|
||||
$queryID = ($browseType == 'bySearch') ? (int)$param : 0;
|
||||
|
||||
$allBranches = $this->loadModel('branch')->getByProducts(array_keys($products), 'noempty');
|
||||
$branchPairs = array();
|
||||
$productType = 'normal';
|
||||
$productNum = count($products);
|
||||
$branchGroups = $this->loadModel('branch')->getByProducts(array_keys($products), 'noempty');
|
||||
$branchPairs = array();
|
||||
$productType = 'normal';
|
||||
$productNum = count($products);
|
||||
foreach($products as $product)
|
||||
{
|
||||
$productPairs[$product->id] = $product->name;
|
||||
@@ -1550,11 +1550,11 @@ class project extends control
|
||||
$productType = $product->type;
|
||||
if($product->branch)
|
||||
{
|
||||
$branchPairs[$product->branch] = ($productNum > 1 ? $product->name . '/' : '') . $allBranches[$product->id][$product->branch];
|
||||
$branchPairs[$product->branch] = ($productNum > 1 ? $product->name . '/' : '') . $branchGroups[$product->id][$product->branch];
|
||||
}
|
||||
else
|
||||
{
|
||||
$productBranches = $allBranches[$product->id];
|
||||
$productBranches = $branchGroups[$product->id];
|
||||
if($productNum > 1)
|
||||
{
|
||||
foreach($productBranches as $branchID => $branchName) $productBranches[$branchID] = $product->name . '/' . $branchName;
|
||||
@@ -1606,8 +1606,9 @@ class project extends control
|
||||
$this->view->allStories = $allStories;
|
||||
$this->view->prjStories = $prjStories;
|
||||
$this->view->browseType = $browseType;
|
||||
$this->view->productType = $productType;
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter');
|
||||
$this->view->branchGroups = $this->loadModel('branch')->getByProducts(array_keys($products), 'noempty');
|
||||
$this->view->branchGroups = $branchGroups;
|
||||
$this->display();
|
||||
}
|
||||
|
||||
|
||||
@@ -29,7 +29,9 @@
|
||||
<th><?php echo $lang->story->product;?></th>
|
||||
<th><?php echo $lang->story->title;?></th>
|
||||
<th><?php echo $lang->story->plan;?></th>
|
||||
<th><?php echo $lang->branch->common;?></th>
|
||||
<?php if($productType != 'normal'):?>
|
||||
<th><?php echo $lang->product->branchName[$productType];?></th>
|
||||
<?php endif;?>
|
||||
<th class='w-user'><?php echo $lang->openedByAB;?></th>
|
||||
<th class='w-80px'><?php echo $lang->story->estimateAB;?></th>
|
||||
</tr>
|
||||
@@ -49,7 +51,9 @@
|
||||
<td><?php echo html::a($this->createLink('product', 'browse', "productID=$story->product&branch=$story->branch"), $products[$story->product]->name, '_blank');?></td>
|
||||
<td class='text-left nobr' title="<?php echo $story->title?>"><?php echo html::a($storyLink, $story->title);?></td>
|
||||
<td><?php echo $story->planTitle;?></td>
|
||||
<?php if($productType != 'normal'):?>
|
||||
<td><?php if(isset($branchGroups[$story->product][$story->branch])) echo $branchGroups[$story->product][$story->branch];?></td>
|
||||
<?php endif;?>
|
||||
<td><?php echo $users[$story->openedBy];?></td>
|
||||
<td><?php echo $story->estimate;?></td>
|
||||
</tr>
|
||||
@@ -58,7 +62,7 @@
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan='8' class='text-left'>
|
||||
<td colspan='<?php echo $productType == 'normal' ? '7' :'8';?>' class='text-left'>
|
||||
<div class='table-actions clearfix'>
|
||||
|
||||
<?php
|
||||
|
||||
Reference in New Issue
Block a user