This commit is contained in:
Yagami
2020-08-26 13:10:11 +08:00
4 changed files with 25 additions and 46 deletions

View File

@@ -262,7 +262,7 @@ function reloadRoadmap(productID)
{
$("#roadMap").html('');
$("#roadMap").html(data);
$("#createPlanLink").attr('href',createLink('productplan', 'create', 'id=' + productID) );
$('#productID').chosen();
}
})
}

View File

@@ -483,7 +483,6 @@ $lang->block->modules['program']->moreLinkList->cmmiestimate = 'workestimation|
$lang->block->modules['program']->moreLinkList->cmmiissue = 'issue|browse|';
$lang->block->modules['program']->moreLinkList->cmmirisk = 'risk|browse|';
$lang->block->modules['program']->moreLinkList->scrumlist = 'project|all|';
$lang->block->modules['program']->moreLinkList->scrumroadmap = 'product|all|';
$lang->block->modules['program']->moreLinkList->scrumtest = 'testtask|browse|';
$lang->block->modules['program']->moreLinkList->scrumproduct = 'product|all|';
$lang->block->modules['program']->moreLinkList->scrumproject = 'project|all|';

View File

@@ -10,21 +10,27 @@
* @link http://www.zentao.net
*/
?>
<?php if($sync === 1):?>
<?php echo $sync ? '<div id="roadMap">' : '';?>
<style>
.release-line>li:nth-child(even)>a{height:92px;}
.release-line>li:nth-child(even)>a{height: 92px;}
.release-line>li:nth-child(odd){padding-top: 87px;}
.release-line>li>a .title {overflow: hidden; width:150%; text-overflow: ellipsis;}
#dashboard .panel-move-handler{right:78px}
#dashboard .panel-move-handler{right: 30px}
#productList{width:32%; position: absolute; top: 6px; left: 96px;}
#createPlan{position: absolute; top: 3px; right:0px;}
#createPlan{position: absolute; top: 6px; right: 50px;}
#createPlan a{padding: 0 5px;line-height: 24px;margin: 3px;color: #3C4353;}
#roadMapMore{position: absolute; top: 0px; right: 0px;}
</style>
<div class="panel-move-handler">
<div id="productList"><?php echo html::select('productID', $products, '', 'class="form-control chosen" onchange="reloadRoadmap(this.options[this.options.selectedIndex].value)"');?></div>
<div id="createPlan"><?php echo html::a($this->createLink('productplan', 'create', 'productID=' . $productID), '<i class="icon icon-sm icon-plus"></i>'. $lang->productplan->create, '', 'class="btn btn-mini" id="createPlanLink"');?></div>
<div id="productList"><?php echo html::select('productID', $products, $productID, 'class="form-control chosen" onchange="reloadRoadmap(this.options[this.options.selectedIndex].value)"');?></div>
<div id="createPlan"><?php echo html::a($this->createLink('productplan', 'create', 'productID=' . $productID), '<i class="icon icon-sm icon-plus"></i>'. $lang->productplan->create, '', 'class="btn btn-mini" id="createPlanLink"');?></div>
<nav class="panel-actions nav nav-default" id="roadMapMore">
<li>
<?php echo html::a($this->createLink('product', 'roadmap', 'productID=' . $productID), '<i class="icon icon-more"></i>', '', 'title="'. $lang->more .'" id="roadMapMoreLink"');?>
</li>
</nav>
</div>
<div class="panel-body conatiner-fluid" id="roadMap">
<div class="panel-body conatiner-fluid">
<?php if(empty($roadmaps)):?>
<div class='empty-tip'><?php echo $lang->block->emptyTip;?></div>
<?php else:?>
@@ -37,41 +43,11 @@
<li <?php if(date('Y-m-d') < $plan->begin) echo 'class="active"';?>>
<a href="<?php echo $this->createLink('productplan', 'view', "planID={$plan->id}");?>">
<span class="title" title="<?php echo $plan->title;?>"><?php echo $plan->title;?></span>
<span class="date" title="<?php echo $plan->begin;?>"><?php echo $plan->begin;?></span>
<span class="date"><?php echo $lang->block->estimatedHours;?> <?php echo $plan->hour;?> h</span>
</a>
</li>
<?php else:?>
<li>
<a href="<?php echo $this->createLink('release', 'view', "releaseID={$plan->id}");?>">
<span class="title" title="<?php echo $plan->name . " ($plan->buildName)";?>"><?php echo $plan->name . "($plan->buildName)";?></span>
<span class="date" title="<?php echo $plan->date;?>"><?php echo $plan->date;?></span>
<?php $estimate = empty($plan->stories) ? 0 : $this->block->getStorysEstimateHours(explode(',', $plan->stories));?>
<span class="date"><?php echo $lang->block->consumedHours;?> <?php echo empty($estimate) ? 0 : $estimate;?> h</span>
</a>
</li>
<?php endif;?>
<?php endforeach;?>
<?php endforeach;?>
<?php endforeach;?>
</ul>
</div>
<?php endif;?>
</div>
<?php else:?>
<?php if(empty($roadmaps)):?>
<div class='empty-tip'><?php echo $lang->block->emptyTip;?></div>
<?php else:?>
<div class="release-path">
<ul class="release-line">
<?php foreach($roadmaps as $year => $mapBranches):?>
<?php foreach($mapBranches as $plans):?>
<?php foreach($plans as $plan):?>
<?php if(isset($plan->begin)):?>
<li <?php if(date('Y-m-d') < $plan->begin) echo 'class="active"';?>>
<a href="<?php echo $this->createLink('productplan', 'view', "planID={$plan->id}");?>">
<span class="title" title="<?php echo $plan->title;?>"><?php echo $plan->title;?></span>
<span class="date" title="<?php echo $plan->begin;?>"><?php echo $plan->begin;?></span>
<?php
$plan->begin = date('Y/m/d', strtotime($plan->begin));
$plan->end = '-' . date('m/d', strtotime($plan->end));
?>
<span class="date" title="<?php echo $plan->begin . $plan->end;?>"><?php echo $plan->begin . $plan->end;?></span>
<span class="date"><?php echo $lang->block->estimatedHours;?> <?php echo $plan->hour;?> h</span>
</a>
</li>
@@ -79,6 +55,9 @@
<li>
<a href="<?php echo $this->createLink('release', 'view', "releaseID={$plan->id}");?>">
<span class="title" title="<?php echo $plan->name;?>"><?php echo $plan->name . "($plan->buildName)";?></span>
<?php
$plan->date = date('Y/m/d', strtotime($plan->date));
?>
<span class="date" title="<?php echo $plan->date;?>"><?php echo $plan->date;?></span>
<?php $estimate = empty($plan->stories) ? 0 : $this->block->getStorysEstimateHours(explode(',', $plan->stories));?>
<span class="date"><?php echo $lang->block->consumedHours;?> <?php echo empty($estimate) ? 0 : $estimate;?> h</span>
@@ -91,4 +70,5 @@
</ul>
</div>
<?php endif;?>
<?php endif;?>
</div>
<?php echo $sync ? '</div>' : '';?>

View File

@@ -64,7 +64,7 @@
<td></td>
</tr>
<?php endif;?>
<?php if(isset($activityID) && $activityID):?>
<?php if(isset($owner) && $owner):?>
<tr>
<th><?php echo $lang->issue->activity;?></th>
<td><?php echo html::select('activity', $activity, $activityID, 'class="form-control chosen"');?></td>