diff --git a/module/productplan/control.php b/module/productplan/control.php index 7d529eefee..c371c9b8dd 100644 --- a/module/productplan/control.php +++ b/module/productplan/control.php @@ -490,21 +490,24 @@ class productplan extends control */ public function linkBug($planID = 0, $browseType = '', $param = 0, $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 100, $pageID = 1) { - $projects = $this->app->user->view->projects . ',0'; - if(!empty($_POST['bugs'])) { $this->productplan->linkBug($planID); die(js::locate(inlink('view', "planID=$planID&type=bug&orderBy=$orderBy"), 'parent')); } - $this->session->set('bugList', inlink('view', "planID=$planID&type=bug&orderBy=$orderBy&link=true¶m=" . helper::safe64Encode("&browseType=$browseType&queryID=$param"))); + /* Load module and set session. */ $this->loadModel('bug'); - $plan = $this->productplan->getByID($planID); - $this->commonAction($plan->product, $plan->branch); - $productID = $plan->product; - $productName = $this->dao->findById($productID)->from(TABLE_PRODUCT)->fetch('name'); - $queryID = ($browseType == 'bysearch') ? (int)$param : 0; + $this->session->set('bugList', inlink('view', "planID=$planID&type=bug&orderBy=$orderBy&link=true¶m=" . helper::safe64Encode("&browseType=$browseType&queryID=$param"))); + + /* Init vars. */ + $projects = $this->app->user->view->projects . ',0'; + $plan = $this->productplan->getByID($planID); + $productID = $plan->product; + $queryID = ($browseType == 'bysearch') ? (int)$param : 0; + + /* Set menu. */ + $this->commonAction($productID, $plan->branch); /* Load pager. */ $this->app->loadClass('pager', $static = true); @@ -514,12 +517,13 @@ class productplan extends control $this->config->bug->search['actionURL'] = $this->createLink('productplan', 'view', "planID=$planID&type=bug&orderBy=$orderBy&link=true¶m=" . helper::safe64Encode('&browseType=bySearch&queryID=myQueryID')); $this->config->bug->search['queryID'] = $queryID; $this->config->bug->search['style'] = 'simple'; - $this->config->bug->search['params']['product']['values'] = array($productID => $productName, 'all' => $this->lang->bug->allProduct); - $this->config->bug->search['params']['plan']['values'] = $this->productplan->getForProducts(array($plan->product => $plan->product)); + $this->config->bug->search['params']['plan']['values'] = $this->productplan->getForProducts(array($productID => $productID)); $this->config->bug->search['params']['module']['values'] = $this->loadModel('tree')->getOptionMenu($productID, $viewType = 'bug', $startModuleID = 0); $this->config->bug->search['params']['project']['values'] = $this->product->getExecutionPairsByProduct($productID); $this->config->bug->search['params']['openedBuild']['values'] = $this->loadModel('build')->getProductBuildPairs($productID, $branch = 0, $params = ''); $this->config->bug->search['params']['resolvedBuild']['values'] = $this->build->getProductBuildPairs($productID, $branch = 0, $params = ''); + + unset($this->config->bug->search['fields']['product']); if($this->session->currentProductType == 'normal') { unset($this->config->bug->search['fields']['branch']); @@ -528,7 +532,7 @@ class productplan extends control else { $this->config->bug->search['fields']['branch'] = $this->lang->product->branch; - $branches = array('' => '') + $this->loadModel('branch')->getPairs($plan->product, 'noempty'); + $branches = array('' => '') + $this->loadModel('branch')->getPairs($productID, 'noempty'); if($plan->branch) $branches = array('' => '', $plan->branch => $branches[$plan->branch]); $this->config->bug->search['params']['branch']['values'] = $branches; } @@ -538,7 +542,7 @@ class productplan extends control if($browseType == 'bySearch') { - $allBugs = $this->bug->getBySearch($plan->product, $plan->branch, $queryID, 'id_desc', array_keys($planBugs), $pager); + $allBugs = $this->bug->getBySearch($productID, $plan->branch, $queryID, 'id_desc', array_keys($planBugs), $pager); } else { diff --git a/module/story/lang/zh-cn.php b/module/story/lang/zh-cn.php index c6f9916614..e281a53297 100644 --- a/module/story/lang/zh-cn.php +++ b/module/story/lang/zh-cn.php @@ -89,7 +89,7 @@ $lang->story->program = "所属项目"; $lang->story->branch = "分支/平台"; $lang->story->module = '所属模块'; $lang->story->moduleAB = '模块'; -$lang->story->source = "{$lang->productSRCommon}来源"; +$lang->story->source = "来源"; $lang->story->sourceNote = '来源备注'; $lang->story->fromBug = '来源Bug'; $lang->story->title = "{$lang->productSRCommon}名称"; diff --git a/module/story/lang/zh-tw.php b/module/story/lang/zh-tw.php index fe92eb5267..e62c9ca3be 100644 --- a/module/story/lang/zh-tw.php +++ b/module/story/lang/zh-tw.php @@ -9,7 +9,17 @@ * @version $Id: zh-tw.php 5141 2013-07-15 05:57:15Z chencongzhi520@gmail.com $ * @link http://www.zentao.net */ +global $config; $lang->story->create = "提{$lang->productSRCommon}"; +$lang->story->createStory = "提{$lang->productSRCommon}"; +$lang->story->createRequirement = "提{$lang->productSRCommon}"; + +$lang->story->requirement = zget($lang, 'productURCommon', "用戶需求"); +$lang->story->story = zget($lang, 'productSRCommon', "軟件需求"); +$lang->story->createStory = '添加' . $lang->story->story; +$lang->story->createRequirement = '添加' . $lang->story->requirement; +$lang->story->affectedStories = "影響的{$lang->story->story}"; + $lang->story->batchCreate = "批量創建"; $lang->story->change = "變更"; $lang->story->changeAction = "變更{$lang->productSRCommon}"; @@ -23,6 +33,10 @@ $lang->story->batchReview = '批量評審'; $lang->story->edit = "編輯"; $lang->story->batchEdit = "批量編輯"; $lang->story->subdivide = '細分'; +$lang->story->link = '關聯'; +$lang->story->unlink = '移除'; +$lang->story->track = '跟蹤矩陣'; +$lang->story->processStoryChange= '處理需求變更'; $lang->story->subdivideAction = "細分{$lang->productSRCommon}"; $lang->story->splitRequirent = '拆分'; $lang->story->close = '關閉'; @@ -52,7 +66,7 @@ $lang->story->zeroTask = "只列零任務{$lang->productSRCommon}"; $lang->story->reportChart = "統計報表"; $lang->story->reportAction = "統計報表"; $lang->story->copyTitle = "同{$lang->productSRCommon}名稱"; -$lang->story->batchChangePlan = "批量修改計劃"; +$lang->story->batchChangePlan = "批量修改{$lang->planCommon}"; $lang->story->batchChangeBranch = "批量修改分支"; $lang->story->batchChangeStage = "批量修改階段"; $lang->story->batchAssignTo = "批量指派"; @@ -71,10 +85,11 @@ $lang->story->common = $lang->productSRCommon; $lang->story->id = '編號'; $lang->story->parent = '父需求'; $lang->story->product = "所屬{$lang->productCommon}"; +$lang->story->program = "所屬項目"; $lang->story->branch = "分支/平台"; $lang->story->module = '所屬模組'; $lang->story->moduleAB = '模組'; -$lang->story->source = "{$lang->productSRCommon}來源"; +$lang->story->source = "來源"; $lang->story->sourceNote = '來源備註'; $lang->story->fromBug = '來源Bug'; $lang->story->title = "{$lang->productSRCommon}名稱"; @@ -107,8 +122,8 @@ $lang->story->rejectedReason = '拒絶原因'; $lang->story->reviewedBy = '由誰評審'; $lang->story->reviewedDate = '評審時間'; $lang->story->version = '版本號'; -$lang->story->plan = '所屬計劃'; -$lang->story->planAB = '計劃'; +$lang->story->plan = "所屬{$lang->planCommon}"; +$lang->story->planAB = $lang->planCommon; $lang->story->comment = '備註'; $lang->story->children = "子{$lang->productSRCommon}"; $lang->story->childrenAB = "子"; @@ -127,6 +142,12 @@ $lang->story->allStories = "所有{$lang->productSRCommon}"; $lang->story->unclosed = '未關閉'; $lang->story->deleted = '已刪除'; $lang->story->released = "已發佈{$lang->productSRCommon}數"; +$lang->story->URChanged = '用需變更'; +$lang->story->design = '相關設計'; +$lang->story->case = '相關用例'; +$lang->story->bug = '相關Bug'; +$lang->story->repoCommit = '相關提交'; +$lang->story->noRequirement = '無需求'; $lang->story->one = '一個'; $lang->story->field = '同步的欄位'; @@ -147,7 +168,7 @@ $lang->story->statusList['changed'] = '已變更'; $lang->story->stageList[''] = ''; $lang->story->stageList['wait'] = '未開始'; -$lang->story->stageList['planned'] = '已計劃'; +$lang->story->stageList['planned'] = "已{$lang->planCommon}"; $lang->story->stageList['projected'] = '已立項'; $lang->story->stageList['developing'] = '研發中'; $lang->story->stageList['developed'] = '研發完畢'; @@ -198,6 +219,10 @@ $lang->story->priList[2] = '2'; $lang->story->priList[3] = '3'; $lang->story->priList[4] = '4'; +$lang->story->changeList = array(); +$lang->story->changeList['no'] = '不變更'; +$lang->story->changeList['yes'] = '變更'; + $lang->story->legendBasicInfo = '基本信息'; $lang->story->legendLifeTime = "{$lang->productSRCommon}的一生"; $lang->story->legendRelated = '相關信息'; @@ -237,6 +262,7 @@ $lang->story->noRequirement = "暫時沒有{$lang->productURCommon}。"; $lang->story->ignoreChangeStage = "{$lang->productSRCommon} %s 為草稿狀態或已關閉狀態,沒有修改其階段。"; $lang->story->cannotDeleteParent = "不能刪除父{$lang->productSRCommon}"; $lang->story->moveChildrenTips = "修改父{$lang->productSRCommon}的所屬產品會將其下的子{$lang->productSRCommon}也移動到所選產品下。"; +$lang->story->changeTips = '該軟件需求關聯的用戶需求有變更,點擊“不變更”忽略此條變更,點擊“變更”來進行該軟件需求的變更。'; $lang->story->form = new stdclass(); $lang->story->form->area = "該{$lang->productSRCommon}所屬範圍"; @@ -247,8 +273,8 @@ $lang->story->form->file = "附件,如果該{$lang->productSRCommon}有 $lang->story->action = new stdclass(); $lang->story->action->reviewed = array('main' => '$date, 由 $actor 記錄評審結果,結果為 $extra。', 'extra' => 'reviewResultList'); $lang->story->action->closed = array('main' => '$date, 由 $actor 關閉,原因為 $extra $appendLink。', 'extra' => 'reasonList'); -$lang->story->action->linked2plan = array('main' => '$date, 由 $actor 關聯到計劃 $extra。'); -$lang->story->action->unlinkedfromplan = array('main' => '$date, 由 $actor 從計劃 $extra 移除。'); +$lang->story->action->linked2plan = array('main' => '$date, 由 $actor 關聯到' . $lang->planCommon . ' $extra。'); +$lang->story->action->unlinkedfromplan = array('main' => '$date, 由 $actor 從' . $lang->planCommon . ' $extra 移除。'); $lang->story->action->linked2project = array('main' => '$date, 由 $actor 關聯到' . $lang->projectCommon . ' $extra。'); $lang->story->action->unlinkedfromproject = array('main' => '$date, 由 $actor 從' . $lang->projectCommon . ' $extra 移除。'); $lang->story->action->linked2build = array('main' => '$date, 由 $actor 關聯到版本 $extra。'); @@ -270,7 +296,7 @@ $lang->story->report->value = "{$lang->productSRCommon}數"; $lang->story->report->charts['storysPerProduct'] = $lang->productCommon . "{$lang->productSRCommon}數量"; $lang->story->report->charts['storysPerModule'] = "模組{$lang->productSRCommon}數量"; $lang->story->report->charts['storysPerSource'] = "按{$lang->productSRCommon}來源統計"; -$lang->story->report->charts['storysPerPlan'] = '按計划進行統計'; +$lang->story->report->charts['storysPerPlan'] = "按{$lang->planCommon}進行統計"; $lang->story->report->charts['storysPerStatus'] = '按狀態進行統計'; $lang->story->report->charts['storysPerStage'] = '按所處階段進行統計'; $lang->story->report->charts['storysPerPri'] = '按優先順序進行統計'; @@ -302,7 +328,7 @@ $lang->story->report->storysPerChange = new stdclass(); $lang->story->report->storysPerProduct->item = $lang->productCommon; $lang->story->report->storysPerModule->item = '模組'; $lang->story->report->storysPerSource->item = '來源'; -$lang->story->report->storysPerPlan->item = '計劃'; +$lang->story->report->storysPerPlan->item = $lang->planCommon; $lang->story->report->storysPerStatus->item = '狀態'; $lang->story->report->storysPerStage->item = '階段'; $lang->story->report->storysPerPri->item = '優先順序'; @@ -328,7 +354,7 @@ $lang->story->report->storysPerChange->graph = new stdclass(); $lang->story->report->storysPerProduct->graph->xAxisName = $lang->productCommon; $lang->story->report->storysPerModule->graph->xAxisName = '模組'; $lang->story->report->storysPerSource->graph->xAxisName = '來源'; -$lang->story->report->storysPerPlan->graph->xAxisName = '計劃'; +$lang->story->report->storysPerPlan->graph->xAxisName = $lang->planCommon; $lang->story->report->storysPerStatus->graph->xAxisName = '狀態'; $lang->story->report->storysPerStage->graph->xAxisName = '所處階段'; $lang->story->report->storysPerPri->graph->xAxisName = '優先順序';