* adjust the all projects page.

This commit is contained in:
wangchunsheng
2012-12-15 01:34:09 +00:00
parent dc0a46bb3a
commit a2720b5fe0
4 changed files with 13 additions and 11 deletions
+1 -1
View File
@@ -198,7 +198,7 @@ $lang->project->menu->product = array('link' => 'Product|project|manageproduct
$lang->project->menu->view = 'Manage|project|view|projectID=%s';
$lang->project->menu->order = 'Order|project|order|projectID=%s';
$lang->project->menu->create = array('link' => '<span class="icon-add1">&nbsp;</span>New|project|create', 'float' => 'right');
$lang->project->menu->all = array('link' => '<span class="icon-all">&nbsp;</span>Projects|project|index|locate=no', 'float' => 'right');
$lang->project->menu->all = array('link' => '<span class="icon-all">&nbsp;</span>Projects|project|index|locate=no&projectID=%s', 'float' => 'right');
$lang->task = new stdclass();
$lang->build = new stdclass();
+1 -1
View File
@@ -198,7 +198,7 @@ $lang->project->menu->product = '产品|project|manageproducts|projectID=%s';
$lang->project->menu->view = array('link' => '维护|project|view|projectID=%s', 'alias' => 'edit');
$lang->project->menu->order = '排序|project|order|projectID=%s';
$lang->project->menu->create = array('link' => '<span class="icon-addProject">&nbsp;</span>新增项目|project|create', 'float' => 'right');
$lang->project->menu->all = array('link' => '<span class="icon-allProjects">&nbsp;</span>所有项目|project|index|locate=false', 'float' => 'right');
$lang->project->menu->all = array('link' => '<span class="icon-allProjects">&nbsp;</span>所有项目|project|index|locate=no&status=undone&projectID=%s', 'float' => 'right');
$lang->task = new stdclass();
$lang->build = new stdclass();
+7 -4
View File
@@ -31,15 +31,18 @@ class project extends control
/**
* The index page.
*
* @param string $locate yes|no locate to the browse page or not.
* @param string $status the projects status, if locate is no, then get projects by the $status.
* @param string $locate yes|no locate to the browse page or not.
* @param string $status the projects status, if locate is no, then get projects by the $status.
* @param int $projectID
* @access public
* @return void
*/
public function index($locate = 'yes', $status = 'undone')
public function index($locate = 'yes', $status = 'undone', $projectID = 0)
{
if(empty($this->projects)) $this->locate($this->createLink('project', 'create'));
if($locate == 'yes') $this->locate($this->createLink('project', 'browse'));
if($locate == 'yes') $this->locate($this->createLink('project', 'task'));
$this->commonAction($projectID);
$this->app->loadLang('my');
$this->view->projectStats = $this->project->getProjectStats($status);
+4 -5
View File
@@ -9,12 +9,11 @@
* @version $Id$
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/sparkline.html.php';?>
<?php include '../../common/view/colorize.html.php';?>
<h3>
<?php echo html::a(inlink("index", "locate=no&status=undone"), $lang->project->unDoneProjects);?>
<?php echo html::a(inlink("index", "locate=no&status=done"), $lang->project->doneProjects);?>
<?php echo html::a(inlink("index", "locate=no&status=undone&projectID=$project->id"), $lang->project->unDoneProjects);?>
<?php echo html::a(inlink("index", "locate=no&status=done&projectID=$project->id"), $lang->project->doneProjects);?>
</h3>
<table class='table-1 fixed colored'>
<tr class='colhead'>
@@ -45,4 +44,4 @@
</tr>
<?php endforeach;?>
</table>
<?php include '../../common/view/footer.lite.html.php';?>
<?php include '../../common/view/footer.html.php';?>