diff --git a/module/common/lang/zh-cn.php b/module/common/lang/zh-cn.php index 8ab4a363ce..2293baa619 100755 --- a/module/common/lang/zh-cn.php +++ b/module/common/lang/zh-cn.php @@ -549,7 +549,6 @@ $lang->menugroup->branch = 'product'; $lang->menugroup->productplan = 'product'; $lang->menugroup->task = 'project'; $lang->menugroup->build = 'project'; -$lang->menugroup->product = 'projectstory'; $lang->menugroup->convert = 'admin'; $lang->menugroup->upgrade = 'admin'; $lang->menugroup->user = 'company'; diff --git a/module/issue/control.php b/module/issue/control.php index 5a663800d3..4384512d62 100644 --- a/module/issue/control.php +++ b/module/issue/control.php @@ -363,7 +363,7 @@ class issue extends control $this->loadModel('task'); $this->loadModel('tree'); $this->loadModel('project')->getLimitedExecution(); - $projects = $this->project->getExecutionPairs($this->session->PRJ); + $projects = $this->project->getExecutionsByProject($this->session->PRJ, 'all', 0, true); $projectID = $this->session->project; $projectID = isset($projects[$projectID]) ? $projectID : key($projects); diff --git a/module/program/js/common.js b/module/program/js/common.js index ee9f05be02..9c2b61b283 100644 --- a/module/program/js/common.js +++ b/module/program/js/common.js @@ -1,9 +1,10 @@ -function setProgramType(type) -{ - $.cookie('programType', type, {expires:config.cookieLife, path:config.webRoot}); - location.href = location.href; -} - +/** + * Access rights are equal to private, and the white list settings are displayed. + * + * @param string acl + * @access public + * @return void + */ function setWhite(acl) { acl != 'open' ? $('#whitelistBox').removeClass('hidden') : $('#whitelistBox').addClass('hidden'); @@ -12,7 +13,7 @@ function setWhite(acl) /** * Convert a date string like 2011-11-11 to date object in js. * - * @param string $date + * @param string dateString * @access public * @return date */ @@ -25,8 +26,8 @@ function convertStringToDate(dateString) /** * Compute delta of two days. * - * @param string $date1 - * @param string $date1 + * @param string date1 + * @param string date2 * @access public * @return int */ @@ -50,6 +51,7 @@ function computeDaysDelta(date1, date2) /** * Compute work days. * + * @param string currentID * @access public * @return void */ @@ -124,12 +126,15 @@ function computeEndDate(delta) /** * Load branches. * - * @param int $product + * @param object product * @access public * @return void */ function loadBranches(product) { + /* When selecting a product, delete a plan that is empty by default. */ + $("#planDefault").remove(); + $('#productsBox select').each(function() { var $product = $(product); @@ -196,7 +201,12 @@ function loadPlans(product, branchID) } } - +/** + * Adjust the layout of product selection. + * + * @access public + * @return void + */ function adjustProductBoxMargin() { var productRows = Math.ceil($('#productsBox > .row > .col-sm-4').length / 3); @@ -209,6 +219,12 @@ function adjustProductBoxMargin() } } +/** + * Adjust the layout of the plan selection. + * + * @access public + * @return void + */ function adjustPlanBoxMargin() { var planRows = Math.ceil($('#plansBox > .row > .col-sm-4').length / 3); @@ -221,6 +237,12 @@ function adjustPlanBoxMargin() } } +/** + * Initialization operation. + * + * @access public + * @return void + */ $(function() { $('#privList > tbody > tr > th input[type=checkbox]').change(function() diff --git a/module/program/view/prjedit.html.php b/module/program/view/prjedit.html.php index 7446aa4449..6649ed9801 100644 --- a/module/program/view/prjedit.html.php +++ b/module/program/view/prjedit.html.php @@ -63,7 +63,7 @@ -