From 3498c26ed477131a5ec4b75bf40ea967a8b10d8e Mon Sep 17 00:00:00 2001 From: wangchunsheng Date: Wed, 22 Feb 2012 08:13:08 +0000 Subject: [PATCH] * when copy project, copy the name and code also. --- module/project/control.php | 6 ++++++ module/project/view/create.html.php | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/module/project/control.php b/module/project/control.php index 2fbf9140b9..cdbb160b35 100644 --- a/module/project/control.php +++ b/module/project/control.php @@ -730,6 +730,8 @@ class project extends control exit; } + $name = ''; + $code = ''; $team = ''; $products = ''; $whitelist = ''; @@ -738,6 +740,8 @@ class project extends control if($copyProjectID) { $copyProject = $this->dao->select('*')->from(TABLE_PROJECT)->where('id')->eq($copyProjectID)->fetch(); + $name = $copyProject->name; + $code = $copyProject->code; $team = $copyProject->team; $acl = $copyProject->acl; $whitelist = $copyProject->whitelist; @@ -760,6 +764,8 @@ class project extends control $this->view->projects = array('' => '') + $this->projects; $this->view->groups = $this->loadModel('group')->getPairs(); $this->view->allProducts = $this->loadModel('product')->getPairs(); + $this->view->name = $name; + $this->view->code = $code; $this->view->team = $team; $this->view->products = $products ; $this->view->whitelist = $whitelist; diff --git a/module/project/view/create.html.php b/module/project/view/create.html.php index f7e0b00754..8bbc425971 100644 --- a/module/project/view/create.html.php +++ b/module/project/view/create.html.php @@ -36,11 +36,11 @@ $(document).ready(function() project->create;?> project->name;?> - + project->code;?> - + project->begin;?>