* finish task #4725.

This commit is contained in:
wangyidong
2018-09-12 15:00:21 +08:00
parent 39afe7c3fc
commit 2d30ee8a97
4 changed files with 11 additions and 10 deletions

View File

@@ -383,7 +383,7 @@ class product extends control
$this->product->setMenu($this->products, $productID);
$releases = $this->dao->select('*')->from(TABLE_RELEASE)->where('deleted')->eq(0)->andWhere('product')->eq($productID)->orderBy('date')->fetchAll();
$plans = $this->loadModel('productplan')->getList($productID, 0, 'unexpired', null, 'begin');
$this->view->title = $product->name . $this->lang->colon . $this->lang->product->view;
$this->view->position[] = html::a($this->createLink($this->moduleName, 'browse'), $product->name);
@@ -395,7 +395,7 @@ class product extends control
$this->view->lines = array('') + $this->loadModel('tree')->getLinePairs();
$this->view->branches = $this->loadModel('branch')->getPairs($productID);
$this->view->dynamics = $this->loadModel('action')->getDynamic('all', 'all', 'date_desc', $pager = null, $productID);
$this->view->releases = $releases;
$this->view->plans = $plans;
$this->display();
}

View File

@@ -17,21 +17,20 @@
<div class="col-sm-6">
<div class="panel block-release">
<div class="panel-heading">
<div class="panel-title"><?php echo $lang->product->plan;?> <span class="label label-badge label-light"><?php printf($lang->product->iterationInfo, count($releases));?></span></div>
<div class="panel-title"><?php echo $lang->productplan->unexpired;?> <span class="label label-badge label-light"><?php printf($lang->product->iterationInfo, count($plans));?></span></div>
</div>
<div class="panel-body">
<div class="release-path">
<ul class="release-line">
<?php $i = 0;?>
<?php foreach($releases as $release):?>
<?php foreach($plans as $plan):?>
<?php $i++;?>
<?php if($i > 6) break;?>
<li <?php if(date('Y-m-d') < $release->date) echo "class='active'";?>>
<a href="<?php echo $this->createLink('release', 'view', "releaseID={$release->id}");?>">
<?php if(!empty($release->marker)) echo "<i class='icon icon-flag text-primary'></i>";?>
<span class="title"><?php echo $release->name;?></span>
<span class="date"><?php echo $release->date;?></span>
<span class="info text-ellipsis" title="<?php echo strip_tags($release->desc);?>"><?php echo $release->desc;?></span>
<li <?php if(date('Y-m-d') < $plan->begin) echo "class='active'";?>>
<a href="<?php echo $this->createLink('plan', 'view', "planID={$plan->id}");?>">
<span class="title"><?php echo $plan->title;?></span>
<span class="date"><?php echo $plan->begin;?></span>
<span class="info text-ellipsis" title="<?php echo strip_tags($plan->desc);?>"><?php echo $plan->desc;?></span>
</a>
</li>
<?php endforeach;?>

View File

@@ -33,6 +33,7 @@ $lang->productplan->unlinkBug = "Unlink Bug";
$lang->productplan->batchUnlinkBug = "Batch Unlink Bug";
$lang->productplan->linkedBugs = 'Linked Bug';
$lang->productplan->unlinkedBugs = 'Unlinked';
$lang->productplan->unexpired = 'Unexpired Plan';
$lang->productplan->confirmDelete = "Do you want to delete this Plan?";
$lang->productplan->confirmUnlinkStory = "Do you want to unlink this Story?";

View File

@@ -33,6 +33,7 @@ $lang->productplan->unlinkBug = "移除Bug";
$lang->productplan->batchUnlinkBug = "批量移除Bug";
$lang->productplan->linkedBugs = 'Bug';
$lang->productplan->unlinkedBugs = '未关联Bug';
$lang->productplan->unexpired = '未过期计划';
$lang->productplan->confirmDelete = "您确认删除该计划吗?";
$lang->productplan->confirmUnlinkStory = "您确认移除该需求吗?";