From 176b8a57ef4796b40d55e1c815027c0dd44cb292 Mon Sep 17 00:00:00 2001 From: wangchunsheng Date: Sat, 24 Apr 2010 15:12:29 +0000 Subject: [PATCH] * when create bug, pass the product param. --- trunk/module/project/control.php | 5 ++++- trunk/module/project/view/bug.html.php | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/trunk/module/project/control.php b/trunk/module/project/control.php index 69a7b79e64..18da5c9556 100644 --- a/trunk/module/project/control.php +++ b/trunk/module/project/control.php @@ -236,7 +236,9 @@ class project extends control $this->session->set('bugList', $this->app->getURI(true)); /* 公共的操作。*/ - $project = $this->commonAction($projectID); + $project = $this->commonAction($projectID); + $products = $this->project->getProducts($project->id); + $productID = key($products); // 取第一个产品,用来提交Bug。 /* 设定header和position信息。*/ $header['title'] = $project->name . $this->lang->colon . $this->lang->project->bug; @@ -257,6 +259,7 @@ class project extends control $this->assign('pager', $pager); $this->assign('orderBy', $orderBy); $this->assign('users', $users); + $this->assign('productID',$productID); $this->display(); } diff --git a/trunk/module/project/view/bug.html.php b/trunk/module/project/view/bug.html.php index bc1f9f2462..fdf7d3511b 100644 --- a/trunk/module/project/view/bug.html.php +++ b/trunk/module/project/view/bug.html.php @@ -28,7 +28,7 @@
project->bug;?>
-
id", $lang->bug->create);?>
+
id", $lang->bug->create);?>