+ add the summary of stories of a project.

This commit is contained in:
wangchunsheng
2010-04-05 02:27:57 +00:00
parent c0ffc39469
commit b6d5241fa5
2 changed files with 6 additions and 0 deletions

View File

@@ -100,6 +100,7 @@ $lang->project->beginAndEnd = '起止时间';
$lang->project->lblStats = '工时统计';
$lang->project->stats = '总共预计『%s』工时<br />已经消耗『%s』工时<br />预计剩余『%s』工时';
$lang->project->oneLineStats = "项目『%s』, 代号为『%s』, 相关产品为『%s』『%s』开始『%s』结束总预计『%s』工时已消耗『%s』工时预计剩余『%s』工时。";
$lang->project->storySummary = "共『%s』个需求预计『%s』个工时。";
$lang->project->statusList->wait = '未开始';
$lang->project->statusList->doing = '进行中';

View File

@@ -57,10 +57,12 @@ $(document).ready(function()
</tr>
</thead>
<tbody>
<?php $totalEstimate = 0;?>
<?php foreach($stories as $key => $story):?>
<?php
$viewLink = $this->createLink('story', 'view', "storyID=$story->id");
$canView = common::hasPriv('story', 'view');
$totalEstimate += $story->estimate;
?>
<tr class='a-center'>
<td><?php if($canView) echo html::a($viewLink, sprintf('%03d', $story->id)); else printf('%03d', $story->id);?></td>
@@ -90,6 +92,9 @@ $(document).ready(function()
</tr>
<?php endforeach;?>
</tbody>
<tfoot>
<tr><td colspan='9' class='a-right'><?php printf($lang->project->storySummary, count($stories), $totalEstimate);?></td></tr>
</tfoot>
</table>
</div>
<?php include '../../common/view/footer.html.php';?>