diff --git a/module/bug/config.php b/module/bug/config.php index 5ac6e7d586..a2dc0c6292 100644 --- a/module/bug/config.php +++ b/module/bug/config.php @@ -24,7 +24,7 @@ $config->bug->list->allFields = 'id, module, execution, story, task, lastEditedBy, lastEditedDate'; -$config->bug->list->defaultFields = 'id,severity,pri,title,openedBy,assignedTo,resolvedBy,resolution'; +$config->bug->list->defaultFields = 'id,title,severity,pri,openedBy,assignedTo,resolvedBy,resolution'; $config->bug->exportFields = 'id, product, branch, module, project, execution, story, task, title, keywords, severity, pri, type, os, browser, @@ -159,7 +159,7 @@ $config->bug->search['params']['deadline'] = array('operator' => '=', $config->bug->search['params']['activatedDate'] = array('operator' => '=', 'control' => 'input', 'values' => '', 'class' => 'date'); $config->bug->datatable = new stdclass(); -$config->bug->datatable->defaultField = array('id', 'severity', 'pri', 'confirmed', 'title', 'status', 'openedBy', 'openedDate', 'assignedTo', 'resolution', 'actions'); +$config->bug->datatable->defaultField = array('id', 'title', 'severity', 'pri', 'status', 'openedBy', 'openedDate', 'confirmed', 'assignedTo', 'resolution', 'actions'); $config->bug->datatable->fieldList['id']['title'] = 'idAB'; $config->bug->datatable->fieldList['id']['fixed'] = 'left'; @@ -174,6 +174,12 @@ $config->bug->datatable->fieldList['module']['control'] = 'select'; $config->bug->datatable->fieldList['module']['title'] = 'module'; $config->bug->datatable->fieldList['module']['dataSource'] = array('module' => 'tree', 'method' => 'getOptionMenu', 'params' => '$productID&bug'); +$config->bug->datatable->fieldList['title']['title'] = 'title'; +$config->bug->datatable->fieldList['title']['fixed'] = 'left'; +$config->bug->datatable->fieldList['title']['width'] = 'auto'; +$config->bug->datatable->fieldList['title']['required'] = 'yes'; +$config->bug->datatable->fieldList['title']['minWidth'] = '200'; + $config->bug->datatable->fieldList['severity']['title'] = 'severityAB'; $config->bug->datatable->fieldList['severity']['fixed'] = 'left'; $config->bug->datatable->fieldList['severity']['width'] = '50'; @@ -186,16 +192,10 @@ $config->bug->datatable->fieldList['pri']['width'] = '50'; $config->bug->datatable->fieldList['pri']['required'] = 'no'; $config->bug->datatable->fieldList['pri']['name'] = $lang->bug->pri; -$config->bug->datatable->fieldList['confirmed']['title'] = 'confirmedAB'; -$config->bug->datatable->fieldList['confirmed']['fixed'] = 'left'; -$config->bug->datatable->fieldList['confirmed']['width'] = '100'; -$config->bug->datatable->fieldList['confirmed']['required'] = 'no'; - -$config->bug->datatable->fieldList['title']['title'] = 'title'; -$config->bug->datatable->fieldList['title']['fixed'] = 'left'; -$config->bug->datatable->fieldList['title']['width'] = 'auto'; -$config->bug->datatable->fieldList['title']['required'] = 'yes'; -$config->bug->datatable->fieldList['title']['minWidth'] = '200'; +$config->bug->datatable->fieldList['status']['title'] = 'statusAB'; +$config->bug->datatable->fieldList['status']['fixed'] = 'left'; +$config->bug->datatable->fieldList['status']['width'] = '80'; +$config->bug->datatable->fieldList['status']['required'] = 'no'; $config->bug->datatable->fieldList['branch']['title'] = 'branch'; $config->bug->datatable->fieldList['branch']['fixed'] = 'left'; @@ -230,10 +230,66 @@ $config->bug->datatable->fieldList['plan']['fixed'] = 'no'; $config->bug->datatable->fieldList['plan']['width'] = '120'; $config->bug->datatable->fieldList['plan']['required'] = 'no'; -$config->bug->datatable->fieldList['status']['title'] = 'statusAB'; -$config->bug->datatable->fieldList['status']['fixed'] = 'no'; -$config->bug->datatable->fieldList['status']['width'] = '80'; -$config->bug->datatable->fieldList['status']['required'] = 'no'; +$config->bug->datatable->fieldList['openedBy']['title'] = 'openedByAB'; +$config->bug->datatable->fieldList['openedBy']['fixed'] = 'no'; +$config->bug->datatable->fieldList['openedBy']['width'] = '80'; +$config->bug->datatable->fieldList['openedBy']['required'] = 'no'; + +$config->bug->datatable->fieldList['openedDate']['title'] = 'openedDateAB'; +$config->bug->datatable->fieldList['openedDate']['fixed'] = 'no'; +$config->bug->datatable->fieldList['openedDate']['width'] = '90'; +$config->bug->datatable->fieldList['openedDate']['required'] = 'no'; + +$config->bug->datatable->fieldList['openedBuild']['title'] = 'openedBuild'; +$config->bug->datatable->fieldList['openedBuild']['fixed'] = 'no'; +$config->bug->datatable->fieldList['openedBuild']['width'] = '120'; +$config->bug->datatable->fieldList['openedBuild']['required'] = 'no'; +$config->bug->datatable->fieldList['openedBuild']['control'] = 'multiple'; +$config->bug->datatable->fieldList['openedBuild']['dataSource'] = array('module' => 'build', 'method' =>'getBuildPairs', 'params' => '$productID&$branch&noempty,noterminate,nodone,withbranch'); + +$config->bug->datatable->fieldList['confirmed']['title'] = 'confirmedAB'; +$config->bug->datatable->fieldList['confirmed']['fixed'] = 'no'; +$config->bug->datatable->fieldList['confirmed']['width'] = '100'; +$config->bug->datatable->fieldList['confirmed']['required'] = 'no'; + +$config->bug->datatable->fieldList['assignedTo']['title'] = 'assignedToAB'; +$config->bug->datatable->fieldList['assignedTo']['fixed'] = 'no'; +$config->bug->datatable->fieldList['assignedTo']['width'] = '120'; +$config->bug->datatable->fieldList['assignedTo']['required'] = 'no'; +$config->bug->datatable->fieldList['assignedTo']['dataSource'] = array('module' => 'user', 'method' =>'getPairs', 'params' => 'noclosed|noletter'); + +$config->bug->datatable->fieldList['assignedDate']['title'] = 'assignedDate'; +$config->bug->datatable->fieldList['assignedDate']['fixed'] = 'no'; +$config->bug->datatable->fieldList['assignedDate']['width'] = '90'; +$config->bug->datatable->fieldList['assignedDate']['required'] = 'no'; + +$config->bug->datatable->fieldList['deadline']['title'] = 'deadline'; +$config->bug->datatable->fieldList['deadline']['fixed'] = 'no'; +$config->bug->datatable->fieldList['deadline']['width'] = '90'; +$config->bug->datatable->fieldList['deadline']['required'] = 'no'; +$config->bug->datatable->fieldList['deadline']['control'] = 'date'; + +$config->bug->datatable->fieldList['resolvedBy']['title'] = 'resolvedBy'; +$config->bug->datatable->fieldList['resolvedBy']['fixed'] = 'no'; +$config->bug->datatable->fieldList['resolvedBy']['width'] = '100'; +$config->bug->datatable->fieldList['resolvedBy']['required'] = 'no'; + +$config->bug->datatable->fieldList['resolution']['title'] = 'resolutionAB'; +$config->bug->datatable->fieldList['resolution']['fixed'] = 'no'; +$config->bug->datatable->fieldList['resolution']['width'] = '110'; +$config->bug->datatable->fieldList['resolution']['required'] = 'no'; + +$config->bug->datatable->fieldList['resolvedDate']['title'] = 'resolvedDateAB'; +$config->bug->datatable->fieldList['resolvedDate']['fixed'] = 'no'; +$config->bug->datatable->fieldList['resolvedDate']['width'] = '120'; +$config->bug->datatable->fieldList['resolvedDate']['required'] = 'no'; + +$config->bug->datatable->fieldList['resolvedBuild']['title'] = 'resolvedBuild'; +$config->bug->datatable->fieldList['resolvedBuild']['fixed'] = 'no'; +$config->bug->datatable->fieldList['resolvedBuild']['width'] = '120'; +$config->bug->datatable->fieldList['resolvedBuild']['required'] = 'no'; +$config->bug->datatable->fieldList['resolvedBuild']['control'] = 'select'; +$config->bug->datatable->fieldList['resolvedBuild']['dataSource'] = array('module' => 'bug', 'method' =>'getRelatedObjects', 'params' => 'resolvedBuild&id,name'); $config->bug->datatable->fieldList['activatedCount']['title'] = 'activatedCountAB'; $config->bug->datatable->fieldList['activatedCount']['fixed'] = 'no'; @@ -283,62 +339,6 @@ $config->bug->datatable->fieldList['mailto']['fixed'] = 'no'; $config->bug->datatable->fieldList['mailto']['width'] = '100'; $config->bug->datatable->fieldList['mailto']['required'] = 'no'; -$config->bug->datatable->fieldList['openedBy']['title'] = 'openedByAB'; -$config->bug->datatable->fieldList['openedBy']['fixed'] = 'no'; -$config->bug->datatable->fieldList['openedBy']['width'] = '80'; -$config->bug->datatable->fieldList['openedBy']['required'] = 'no'; - -$config->bug->datatable->fieldList['openedDate']['title'] = 'openedDateAB'; -$config->bug->datatable->fieldList['openedDate']['fixed'] = 'no'; -$config->bug->datatable->fieldList['openedDate']['width'] = '90'; -$config->bug->datatable->fieldList['openedDate']['required'] = 'no'; - -$config->bug->datatable->fieldList['openedBuild']['title'] = 'openedBuild'; -$config->bug->datatable->fieldList['openedBuild']['fixed'] = 'no'; -$config->bug->datatable->fieldList['openedBuild']['width'] = '120'; -$config->bug->datatable->fieldList['openedBuild']['required'] = 'no'; -$config->bug->datatable->fieldList['openedBuild']['control'] = 'multiple'; -$config->bug->datatable->fieldList['openedBuild']['dataSource'] = array('module' => 'build', 'method' =>'getBuildPairs', 'params' => '$productID&$branch&noempty,noterminate,nodone,withbranch'); - -$config->bug->datatable->fieldList['assignedTo']['title'] = 'assignedToAB'; -$config->bug->datatable->fieldList['assignedTo']['fixed'] = 'no'; -$config->bug->datatable->fieldList['assignedTo']['width'] = '120'; -$config->bug->datatable->fieldList['assignedTo']['required'] = 'no'; -$config->bug->datatable->fieldList['assignedTo']['dataSource'] = array('module' => 'user', 'method' =>'getPairs', 'params' => 'noclosed|noletter'); - -$config->bug->datatable->fieldList['assignedDate']['title'] = 'assignedDate'; -$config->bug->datatable->fieldList['assignedDate']['fixed'] = 'no'; -$config->bug->datatable->fieldList['assignedDate']['width'] = '90'; -$config->bug->datatable->fieldList['assignedDate']['required'] = 'no'; - -$config->bug->datatable->fieldList['deadline']['title'] = 'deadline'; -$config->bug->datatable->fieldList['deadline']['fixed'] = 'no'; -$config->bug->datatable->fieldList['deadline']['width'] = '90'; -$config->bug->datatable->fieldList['deadline']['required'] = 'no'; -$config->bug->datatable->fieldList['deadline']['control'] = 'date'; - -$config->bug->datatable->fieldList['resolvedBy']['title'] = 'resolvedByAB'; -$config->bug->datatable->fieldList['resolvedBy']['fixed'] = 'no'; -$config->bug->datatable->fieldList['resolvedBy']['width'] = '100'; -$config->bug->datatable->fieldList['resolvedBy']['required'] = 'no'; - -$config->bug->datatable->fieldList['resolution']['title'] = 'resolutionAB'; -$config->bug->datatable->fieldList['resolution']['fixed'] = 'no'; -$config->bug->datatable->fieldList['resolution']['width'] = '110'; -$config->bug->datatable->fieldList['resolution']['required'] = 'no'; - -$config->bug->datatable->fieldList['resolvedDate']['title'] = 'resolvedDateAB'; -$config->bug->datatable->fieldList['resolvedDate']['fixed'] = 'no'; -$config->bug->datatable->fieldList['resolvedDate']['width'] = '120'; -$config->bug->datatable->fieldList['resolvedDate']['required'] = 'no'; - -$config->bug->datatable->fieldList['resolvedBuild']['title'] = 'resolvedBuild'; -$config->bug->datatable->fieldList['resolvedBuild']['fixed'] = 'no'; -$config->bug->datatable->fieldList['resolvedBuild']['width'] = '120'; -$config->bug->datatable->fieldList['resolvedBuild']['required'] = 'no'; -$config->bug->datatable->fieldList['resolvedBuild']['control'] = 'select'; -$config->bug->datatable->fieldList['resolvedBuild']['dataSource'] = array('module' => 'bug', 'method' =>'getRelatedObjects', 'params' => 'resolvedBuild&id,name'); - $config->bug->datatable->fieldList['closedBy']['title'] = 'closedBy'; $config->bug->datatable->fieldList['closedBy']['fixed'] = 'no'; $config->bug->datatable->fieldList['closedBy']['width'] = '80'; diff --git a/module/bug/control.php b/module/bug/control.php index 1463d145f1..bad730430a 100755 --- a/module/bug/control.php +++ b/module/bug/control.php @@ -1148,6 +1148,12 @@ class bug extends control $assignedToList = array_filter($assignedToList); if(empty($assignedToList)) $assignedToList = $this->user->getPairs('devfirst|noclosed'); } + if($bug->assignedTo and !isset($assignedToList[$bug->assignedTo])) + { + /* Fix bug #28378. */ + $assignedTo = $this->user->getById($bug->assignedTo); + $assignedToList[$bug->assignedTo] = $assignedTo->realname; + } if($bug->status == 'closed') $assignedToList['closed'] = 'Closed'; $branch = $product->type == 'branch' ? ($bug->branch > 0 ? $bug->branch . ',0' : '0') : ''; diff --git a/module/bug/css/browse.css b/module/bug/css/browse.css index 55068d74be..8d9aac8543 100644 --- a/module/bug/css/browse.css +++ b/module/bug/css/browse.css @@ -2,7 +2,6 @@ .closed, .closed a {color: gray; text-decoration:line-through;} .resolved, .resolved a {color: #8EC21F; text-decoration: none;} .tree .closed, .tree .closed a {color: #003366; text-decoration: none;} -td.delayed {color: #fff; background: #e84e0f !important;} #bugForm .setting {height: 25px;} .datatable-wrapper .table-datatable .datatable-row td {height: 37px;} diff --git a/module/bug/model.php b/module/bug/model.php index 6a4c7ef4d4..7679e599ae 100644 --- a/module/bug/model.php +++ b/module/bug/model.php @@ -3297,6 +3297,9 @@ class bugModel extends model $class .= ' text-ellipsis'; $title = "title='" . $browser . "'"; break; + case 'deadline': + $class .= ' text-center'; + break; } if($id == 'deadline' && isset($bug->delay) && $bug->status == 'active') $class .= ' delayed'; @@ -3440,7 +3443,7 @@ class bugModel extends model echo helper::isZeroDate($bug->assignedDate) ? '' : substr($bug->assignedDate, 5, 11); break; case 'deadline': - echo helper::isZeroDate($bug->deadline) ? '' : substr($bug->deadline, 5, 11); + echo helper::isZeroDate($bug->deadline) ? '' : '' . substr($bug->deadline, 5, 11) . ''; break; case 'resolvedBy': echo zget($users, $bug->resolvedBy, $bug->resolvedBy); diff --git a/module/common/lang/zh-cn.php b/module/common/lang/zh-cn.php index a27488d59e..f601c2df79 100644 --- a/module/common/lang/zh-cn.php +++ b/module/common/lang/zh-cn.php @@ -146,7 +146,7 @@ $lang->workingHour = '工时'; $lang->idAB = 'ID'; $lang->priAB = 'P'; $lang->statusAB = '状态'; -$lang->openedByAB = '创建'; +$lang->openedByAB = '创建者'; $lang->assignedToAB = '指派'; $lang->typeAB = '类型'; $lang->nameAB = '名称'; diff --git a/module/common/lang/zh-tw.php b/module/common/lang/zh-tw.php index efb472f9ac..5330154fde 100644 --- a/module/common/lang/zh-tw.php +++ b/module/common/lang/zh-tw.php @@ -136,7 +136,7 @@ $lang->workingHour = '工時'; $lang->idAB = 'ID'; $lang->priAB = 'P'; $lang->statusAB = '狀態'; -$lang->openedByAB = '創建'; +$lang->openedByAB = '創建者'; $lang->assignedToAB = '指派'; $lang->typeAB = '類型'; $lang->nameAB = '名稱'; diff --git a/module/execution/css/bug.css b/module/execution/css/bug.css index 095e852326..e48d410a58 100644 --- a/module/execution/css/bug.css +++ b/module/execution/css/bug.css @@ -6,7 +6,7 @@ .dropdown-list > li > a {display: block; padding: 3px 20px; clear: both; font-weight: normal; line-height: 1.53846154; color: #141414; white-space: nowrap;} .dropdown-list > li > a:hover, .dropdown-list > li > a:focus {color: #1a4f85; text-decoration: none; background-color: #ddd;} -td.delayed {color: #fff; background: #e84e0f !important;} .c-severity {width: 80px;} .c-confirmed {overflow: hidden;} +.c-deadline {text-align: center;} diff --git a/module/execution/css/grouptask.css b/module/execution/css/grouptask.css index ff7b32c085..2e54857cc4 100644 --- a/module/execution/css/grouptask.css +++ b/module/execution/css/grouptask.css @@ -27,4 +27,3 @@ .c-hours {white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: right;} .c-user, .c-type {width: 70px;} .c-progress {width: 60px;} -.delayed {background: #e84e0f !important; color: white;} diff --git a/module/execution/css/task.css b/module/execution/css/task.css index 20d6b20df0..f9081b4a59 100644 --- a/module/execution/css/task.css +++ b/module/execution/css/task.css @@ -1,4 +1,3 @@ -td.delayed {background: #e84e0f !important; color: white;} #int-dropdown {margin-left: -8px; border-radius: 4px; border: 1px solid #0c64eb;} #projectTaskForm table tbody tr td {overflow: hidden; text-overflow: ellipsis; white-space: nowrap;} .table td.c-estimate, .table td.c-consumed, .table td.c-left {padding-right: 12px;} diff --git a/module/execution/lang/de.php b/module/execution/lang/de.php index 12ce2c0a86..7dd60f3ce2 100644 --- a/module/execution/lang/de.php +++ b/module/execution/lang/de.php @@ -419,7 +419,7 @@ $lang->execution->storyDragError = "The {$lang->SRCommon} is not ac $lang->execution->countTip = ' (%s member)'; $lang->execution->pleaseInput = "Enter"; $lang->execution->week = 'week'; -$lang->execution->checkedExecutions = 'Seleted %s executions.'; +$lang->execution->checkedExecutions = "Seleted %s {$lang->executionCommon}."; /* Statistics. */ $lang->execution->charts = new stdclass(); diff --git a/module/execution/lang/en.php b/module/execution/lang/en.php index 9f155eb2aa..8befda23c8 100644 --- a/module/execution/lang/en.php +++ b/module/execution/lang/en.php @@ -342,8 +342,8 @@ $lang->execution->stats = 'Available: %s(h). Est $lang->execution->taskSummary = "Total tasks on this page:%s. Waiting: %s. Doing: %s.     Estimates: %s(h). Cost: %s(h). Left: %s(h)."; $lang->execution->pageSummary = "Total tasks: %total%. Waiting: %wait%. Doing: %doing%. Estimates: %estimate%(h). Cost: %consumed%(h). Left: %left%(h)."; $lang->execution->checkedSummary = "Selected: %total%. Waiting: %wait%. Doing: %doing%. Estimates: %estimate%(h). Cost: %consumed%(h). Left: %left%(h)."; -$lang->execution->executionSummary = "Total executions: %s."; -$lang->execution->pageExecSummary = "Total executions: %total%. Waiting: %wait%. Doing: %doing%."; +$lang->execution->executionSummary = "Total {$lang->executionCommon}: %s."; +$lang->execution->pageExecSummary = "Total {$lang->executionCommon}: %total%. Waiting: %wait%. Doing: %doing%."; $lang->execution->checkedExecSummary = "Selected: %total%. Waiting: %wait%. Doing: %doing%."; $lang->execution->memberHoursAB = "%s has %s hours."; $lang->execution->memberHours = '
%s Available Hours
%s
'; @@ -419,7 +419,7 @@ $lang->execution->storyDragError = "The {$lang->SRCommon} is not ac $lang->execution->countTip = ' (%s member)'; $lang->execution->pleaseInput = "Enter"; $lang->execution->week = 'week'; -$lang->execution->checkedExecutions = 'Seleted %s executions.'; +$lang->execution->checkedExecutions = "Seleted %s {$lang->executionCommon}."; /* Statistics. */ $lang->execution->charts = new stdclass(); diff --git a/module/execution/lang/zh-cn.php b/module/execution/lang/zh-cn.php index e2b6c7b3c3..12a9d17a87 100644 --- a/module/execution/lang/zh-cn.php +++ b/module/execution/lang/zh-cn.php @@ -419,7 +419,7 @@ $lang->execution->storyDragError = "该{$lang->SRCommon}不是激 $lang->execution->countTip = '(%s人)'; $lang->execution->pleaseInput = "请输入"; $lang->execution->week = '周'; -$lang->execution->checkedExecutions = "共选中%s个{$lang->execution->common}。"; +$lang->execution->checkedExecutions = "共选中%s个{$lang->executionCommon}。"; /* 统计。*/ $lang->execution->charts = new stdclass(); diff --git a/module/execution/model.php b/module/execution/model.php index 8259a1d99c..76fd53a28a 100644 --- a/module/execution/model.php +++ b/module/execution/model.php @@ -4603,7 +4603,8 @@ class executionModel extends model $burns = join(',', $execution->burns); echo ""; - echo "id class='table-nest-icon icon table-nest-toggle'>"; + echo ""; + if(common::hasPriv('execution', 'batchEdit')) echo "id class='table-nest-icon icon table-nest-toggle'>"; if($this->config->systemMode == 'new') { $spanClass = $execution->type == 'stage' ? 'label-warning' : 'label-info'; diff --git a/module/execution/view/all.html.php b/module/execution/view/all.html.php index b072f3a78e..0e1283510f 100644 --- a/module/execution/view/all.html.php +++ b/module/execution/view/all.html.php @@ -16,13 +16,17 @@ $datatableId = $this->moduleName . ucfirst($this->methodName); $useDatatable = (isset($config->datatable->$datatableId->mode) and $config->datatable->$datatableId->mode == 'datatable'); ?> - - - -execution->checkedExecSummary);?> -execution->pageExecSummary);?> -execution->executionSummary);?> -execution->checkedExecutions);?> +executionCommon, $lang->execution->common, $lang->execution->checkedExecSummary)); +js::set('pageSummary', str_replace($lang->executionCommon, $lang->execution->common, $lang->execution->pageExecSummary)); +js::set('executionSummary', str_replace($lang->executionCommon, $lang->execution->common, $lang->execution->executionSummary)); +js::set('checkedExecutions', str_replace($lang->executionCommon, $lang->execution->common, $lang->execution->checkedExecutions)); +?> execution->treeLevel['all']); diff --git a/module/execution/view/grouptask.html.php b/module/execution/view/grouptask.html.php index 7e107fb0fa..87dc3aa96f 100644 --- a/module/execution/view/grouptask.html.php +++ b/module/execution/view/grouptask.html.php @@ -122,7 +122,7 @@ task->leftAB;?> task->progressAB;?> typeAB;?> - task->deadlineAB;?> + task->deadlineAB;?> actions;?> @@ -207,7 +207,7 @@ left . $lang->execution->workHourUnit;?> progress . '%';?> task->typeList, $task->type);?> - '>deadline, 0, 4) > 0) echo substr($task->deadline, 5, 6);?> + '>deadline, 0, 4) > 0) echo '' . substr($task->deadline, 5, 6) . '';?> execution&taskID=$task->id", $task, 'list', '', '', 'iframe', true);?> diff --git a/module/execution/view/importtask.html.php b/module/execution/view/importtask.html.php index 3eb2618aad..6c46acd740 100644 --- a/module/execution/view/importtask.html.php +++ b/module/execution/view/importtask.html.php @@ -42,7 +42,7 @@ task->assignedTo;?> task->leftAB;?> - task->deadlineAB;?> + task->deadlineAB;?> statusAB;?> task->story;?> @@ -63,7 +63,7 @@ id", $task->name, '', "class='preview iframe' data-width='90%'", true, true)) echo $task->name;?> >assignedToRealName;?> left . ' ' . $lang->execution->workHourUnit;?> - delay)) echo 'delayed';?>>deadline, 0, 4) > 0) echo $task->deadline;?> + deadline, 0, 4) > 0) echo '' . $task->deadline . '';?> processStatus('task', $task);?> tr.table-children > td:first-child::before {width: 3px;} @-moz-document url-prefix() {.main-table tbody > tr.table-children > td:first-child::before {width: 4px;};} .c-span {margin-left: 22px;} +[lang^=de] .c-hours{width: 105px;} diff --git a/module/my/css/story.css b/module/my/css/story.css index 58b9c22c7d..be4c747589 100644 --- a/module/my/css/story.css +++ b/module/my/css/story.css @@ -11,3 +11,4 @@ .main-table tbody > tr.table-children > td:first-child::before {width: 3px;} @-moz-document url-prefix() {.main-table tbody > tr.table-children > td:first-child::before {width: 4px;};} .c-actions-6 {width: 185px;} +[lang^=de] .c-hours {width: 105px;} diff --git a/module/my/css/task.css b/module/my/css/task.css index 4869f718b7..742b4ff517 100644 --- a/module/my/css/task.css +++ b/module/my/css/task.css @@ -1,5 +1,3 @@ -td.delayed {background: #e84e0f !important; color: white;} - .table-children {border-left: 2px solid #cbd0db; border-right: 2px solid #cbd0db;} .table tbody > tr.table-children.table-child-top {border-top: 2px solid #cbd0db;} .table tbody > tr.table-children.table-child-bottom {border-bottom: 2px solid #cbd0db;} @@ -28,7 +26,7 @@ html[lang="en"] .c-user-short {width: 88px;} [lang^=de] #taskTable .c-date {width: 78px;} [lang^=de] #taskTable .assigned-title {width: 123px !important;} [lang^=de] #taskTable .c-user {width: 118px;} -[lang^=de] #taskTable .c-hours {width: 86px;} +[lang^=de] #taskTable .estimate, [lang^=de] #taskTable .consumed {width: 86px;} [lang^=de] #taskTable .c-user-short {width: 75px;} [lang^=fr] #taskTable .c-name {width: 120px;} [lang^=fr] #taskTable .c-project {width: 100px;} diff --git a/module/my/css/todo.css b/module/my/css/todo.css index 73c3524397..6ee004343a 100644 --- a/module/my/css/todo.css +++ b/module/my/css/todo.css @@ -10,3 +10,4 @@ .panel-actions .btn-icon {padding-left: 7px;} [lang^=de] .c-pri {width: 69px;} [lang^=fr] .c-pri {width: 82px;} +[lang^=en] .c-user, [lang^=fr] .c-user {width: 100px !important;} diff --git a/module/my/view/bug.html.php b/module/my/view/bug.html.php index 8872cc6b46..599914d144 100644 --- a/module/my/view/bug.html.php +++ b/module/my/view/bug.html.php @@ -62,24 +62,24 @@ idAB);?> + bug->title);?> bug->severityAB);?> priAB);?> - bug->confirmedAB);?> - bug->title);?> + bug->type);?> bug->product);?> - typeAB);?> - openedByAB);?> + bug->openedByAB);?> + bug->confirmedAB);?> rawMethod == 'work'):?> - bug->deadlineAB);?> + bug->deadline);?> bug->assignedTo);?> - bug->resolvedByAB);?> + bug->resolvedBy);?> bug->resolutionAB);?> actions;?> @@ -109,6 +109,10 @@ id);?> + + createLink('bug', 'view', "bugID=$bug->id"), $bug->title, null, "style='color: $bug->color' title='{$bug->title}'");?> + case) echo html::a(helper::createLink('testcase', 'view', "caseID=$bug->case&version=$bug->caseVersion"), "[" . $this->lang->testcase->common . "#$bug->case]", '', "class='bug' title='$bug->case'");?> + ' title='bug->severityList, $bug->severity);?>' data-severity='severity;?>'>bug->severityList, $bug->severity, $bug->severity);?> @@ -117,24 +121,20 @@ pri?>' title='bug->priList, $bug->pri);?>'>bug->priList, $bug->pri)?> - ' title='bug->confirmedList, $bug->confirmed);?>'>bug->confirmedList, $bug->confirmed)?> - - createLink('bug', 'view', "bugID=$bug->id"), $bug->title, null, "style='color: $bug->color' title='{$bug->title}'");?> - case) echo html::a(helper::createLink('testcase', 'view', "caseID=$bug->case&version=$bug->caseVersion"), "[" . $this->lang->testcase->common . "#$bug->case]", '', "class='bug' title='$bug->case'");?> - productLink == 'product-all' ? '' : "productID=$bug->product";?> + bug->typeList, $bug->type, '');?> productLink); echo html::a($this->createLink('product', $productLink[1], $param), $bug->productName, null, "title={$bug->productName}"); ?> - bug->typeList, $bug->type, '');?> openedBy);?> + ' title='bug->confirmedList, $bug->confirmed);?>'>bug->confirmedList, $bug->confirmed)?> rawMethod == 'work'):?> - deadline, 0, 4) > 0) echo substr($bug->deadline, 5, 6);?> + deadline, 0, 4) > 0) echo '' . substr($bug->deadline, 5, 6) . '';?> bug->printAssignedHtml($bug, $users);?> diff --git a/module/my/view/project.html.php b/module/my/view/project.html.php index 2fc86b3206..d8fc5f84e7 100644 --- a/module/my/view/project.html.php +++ b/module/my/view/project.html.php @@ -47,7 +47,17 @@ + + status == 'wait') $waitCount ++;?> + status == 'doing') $doingCount ++;?> + status == 'suspended') $suspendedCount ++;?> + status == 'closed') $closedCount ++;?> id);?> @@ -101,6 +111,7 @@ diff --git a/module/my/view/requirement.html.php b/module/my/view/requirement.html.php index da432d2e25..4072cb4d9f 100644 --- a/module/my/view/requirement.html.php +++ b/module/my/view/requirement.html.php @@ -50,6 +50,7 @@ $canBatchReview = common::hasPriv('requirement', 'batchReview'); $canBatchAssignTo = common::hasPriv('requirement', 'batchAssignTo'); $canBatchAction = ($canBatchEdit or $canBatchClose or $canBatchReview or $canBatchAssignTo); + $URTitle = common::checkNotCN() ? $lang->URCommon . ' ' . $lang->my->name : $lang->URCommon . $lang->my->name; ?> @@ -61,12 +62,12 @@ idAB);?> + pri;?>>priAB);?> - my->name);?> - story->product);?> - openedByAB);?> - story->estimateAB);?> statusAB);?> + story->product);?> + story->openedByAB);?> + story->estimateAB);?> story->stageAB);?> actions;?> @@ -88,15 +89,15 @@ id);?> - pri;?>' title='story->priList, $story->pri, $story->pri);?>'>story->priList, $story->pri, $story->pri);?> title, null, "style='color: $story->color' data-group='product' title='$story->title'") : "$story->title";?> children)) echo '';?> + pri;?>' title='story->priList, $story->pri, $story->pri);?>'>story->priList, $story->pri, $story->pri);?> + processStatus('story', $story);?> productTitle;?> openedBy);?> estimate . $config->hourUnit;?> - processStatus('story', $story);?> story->stageList, $story->stage);?> "> id);?> - pri;?>' title='story->priList, $child->pri, $child->pri);?>'>story->priList, $child->pri, $child->pri);?> lang->story->children .'">SR ' . (common::hasPriv('story', 'view') ? html::a($storyLink, $child->title, null, "style='color: $child->color' data-group='product' title='$child->title'") : $child->title);?> + pri;?>' title='story->priList, $child->pri, $child->pri);?>'>story->priList, $child->pri, $child->pri);?> + URChanged ? "{$this->lang->story->URChanged}" : "" . $this->processStatus('story', $child) . ''?> productTitle;?> openedBy);?> estimate . $config->hourUnit;?> - URChanged ? "{$this->lang->story->URChanged}" : "" . $this->processStatus('story', $child) . ''?> story->stageList, $child->stage);?> SRCommon . ' ' . $lang->my->name : $lang->SRCommon . $lang->my->name; ?> @@ -66,13 +67,13 @@ idAB);?> + my->pri;?>>priAB);?> - my->name);?> + statusAB);?> story->product);?> story->plan);?> - openedByAB);?> + story->openedByAB);?> story->estimateAB);?> - statusAB);?> story->stageAB);?> actions;?> @@ -93,16 +94,16 @@ id);?> - pri;?>' title='story->priList, $story->pri, $story->pri);?>'>story->priList, $story->pri, $story->pri);?> title, null, "style='color: $story->color' data-group='product'") : $story->title;?> children)) echo '';;?> + pri;?>' title='story->priList, $story->pri, $story->pri);?>'>story->priList, $story->pri, $story->pri);?> + processStatus('story', $story);?> productTitle;?> planTitle;?> openedBy);?> estimate . $config->hourUnit;?> - processStatus('story', $story);?> story->stageList, $story->stage);?> id);?> - pri;?>' title='story->priList, $child->pri, $child->pri);?>'>story->priList, $child->pri, $child->pri);?> lang->story->children .'">' . $this->lang->story->childrenAB . ' ' . html::a($storyLink, $child->title, null, "style='color: $child->color' data-group='product' title='$child->title'");?> + pri;?>' title='story->priList, $child->pri, $child->pri);?>'>story->priList, $child->pri, $child->pri);?> + processStatus('story', $child);?> productTitle;?> planTitle;?> openedBy);?> estimate . $config->hourUnit;?> - processStatus('story', $child);?> story->stageList, $child->stage);?> idAB);?> - task->pri;?>>priAB);?> task->name);?> + task->pri;?>>priAB);?> + statusAB);?> systemMode == 'new'):?> my->projects);?> task->execution);?> my->executions);?> - - openedByAB);?> - - task->deadlineAB);?> task->assignedTo);?> - - task->finishedBy);?> - + task->deadlineAB);?> task->estimateAB);?> task->consumedAB);?> task->leftAB);?> - statusAB);?> + + task->openedByAB);?> + + + task->finishedByAB);?> + actions;?> @@ -105,7 +105,6 @@ id);?> - pri;?>' title='task->priList, $task->pri);?>'>task->priList, $task->pri);?> ' title='name?>'> team)) echo '' . $this->lang->task->multipleAB . ' ';?> children)) echo '';?> + pri;?>' title='task->priList, $task->pri);?>'>task->priList, $task->pri);?> + + storyStatus) and $task->storyStatus == 'active' and $task->latestStoryVersion > $task->storyVersion and !in_array($task->status, array('cancel', 'closed')));?> + {$this->lang->my->storyChanged}") : print(" " . $this->processStatus('task', $task) . "");?> + + pri;?>' title='task->priList, $task->pri);?>'>task->priList, $task->pri);?> + + storyStatus) and $task->storyStatus == 'active' and $task->latestStoryVersion > $task->storyVersion and !in_array($task->status, array('cancel', 'closed')));?> + {$this->lang->my->storyChanged}") : print(" " . $this->processStatus('task', $task) . "");?> + systemMode == 'new'):?> execution]->name) ? $projects[$task->execution]->name : '';?> execution]->id) ? $projects[$task->execution]->id : 0;?> @@ -130,23 +139,19 @@ createLink('execution', 'task', "executionID=$task->execution"), $task->executionName, '');?> - - openedBy);?> - - deadline, 0, 4) > 0) echo substr($task->deadline, 5, 6);?> task->printAssignedHtml($task, $users);?> + deadline, 0, 4) > 0) echo '' . substr($task->deadline, 5, 6) . '';?> + estimate, 1) . $lang->execution->workHourUnit;?> + consumed, 1) . $lang->execution->workHourUnit;?> + left, 1) . $lang->execution->workHourUnit;?> + + openedBy);?> + finishedBy);?> - estimate, 1) . $lang->execution->workHourUnit;?> - consumed, 1) . $lang->execution->workHourUnit;?> - left, 1) . $lang->execution->workHourUnit;?> - - storyStatus) and $task->storyStatus == 'active' and $task->latestStoryVersion > $task->storyVersion and !in_array($task->status, array('cancel', 'closed')));?> - {$this->lang->my->storyChanged}") : print(" " . $this->processStatus('task', $task) . "");?> - id);?> - pri;?>' title='task->priList, $child->pri);?>'>task->priList, $child->pri);?> parent > 0) echo '' . $this->lang->task->childrenAB . ' ';?> createLink('task', 'view', "taskID=$child->id", '', '', $child->project), $child->name, null, "style='color: $child->color'");?> + pri;?>' title='task->priList, $child->pri);?>'>task->priList, $child->pri);?> + + storyStatus) and $child->storyStatus == 'active' and $child->latestStoryVersion > $child->storyVersion and !in_array($child->status, array('cancel', 'closed')));?> + {$this->lang->my->storyChanged}") : print(" " . $this->processStatus('task', $child) . "");?> + systemMode == 'new'):?> execution]->name) ? $projects[$child->execution]->name : '';?> execution]->id) ? $projects[$child->execution]->id : 0;?> @@ -207,23 +216,19 @@ createLink('execution', 'task', "executionID=$child->project"), $child->executionName, '');?> - - openedBy);?> - - deadline, 0, 4) > 0) echo substr($child->deadline, 5, 6);?> task->printAssignedHtml($child, $users);?> + deadline, 0, 4) > 0) echo '' . substr($child->deadline, 5, 6) . '';?> + estimate, 1) . ' ' . $lang->execution->workHourUnit;?> + consumed, 1) . ' ' . $lang->execution->workHourUnit;?> + left, 1) . ' ' . $lang->execution->workHourUnit;?> + + openedBy);?> + finishedBy);?> - estimate, 1) . ' ' . $lang->execution->workHourUnit;?> - consumed, 1) . ' ' . $lang->execution->workHourUnit;?> - left, 1) . ' ' . $lang->execution->workHourUnit;?> - - storyStatus) and $child->storyStatus == 'active' and $child->latestStoryVersion > $child->storyVersion and !in_array($child->status, array('cancel', 'closed')));?> - {$this->lang->my->storyChanged}") : print(" " . $this->processStatus('task', $child) . "");?> - idAB);?> testtask->name);?> - testtask->execution);?> testtask->build);?> + testtask->execution);?> + statusAB);?> testtask->begin);?> testtask->end);?> - statusAB);?> actions;?> @@ -48,11 +48,11 @@ id);?> createLink('testtask', 'view', "taskID=$task->id"), $task->name);?> - executionName;?> trunk : $task->buildName;?>'>build == 'trunk' ? print($lang->trunk) : print(html::a($this->createLink('build', 'view', "buildID=$task->build"), $task->buildName));?> + executionName;?> + '>processStatus('testtask', $task);?> begin?> end?> - '>processStatus('testtask', $task);?> id", $task, 'list', 'sitemap', '', '', '', "data-app='qa'"); diff --git a/module/my/view/todo.html.php b/module/my/view/todo.html.php index 22533a65a5..d8d09f7f81 100644 --- a/module/my/view/todo.html.php +++ b/module/my/view/todo.html.php @@ -87,16 +87,20 @@ idAB);?> - todo->date);?> - todo->type);?> + todo->name);?> app->clientLang == 'en' ? "style='width:80px'" : '';?> title=todo->pri;?>> priAB);?> - todo->name);?> + todo->date);?> + todo->status);?> + todo->type);?> + todo->assignedTo);?> + + todo->assignedBy);?> + todo->beginAB);?> todo->endAB);?> - todo->status);?> - actions;?> + actions;?> @@ -111,14 +115,18 @@ id?> - date == '2030-01-01' ? $lang->todo->periods['future'] : $todo->date;?> - todo->typeList, $todo->type, '');?> - pri;?>' title='todo->priList, $todo->pri, $todo->pri);?>'>todo->priList, $todo->pri)?> createLink('todo', 'view', "id=$todo->id&from=my", '', true), $todo->name, '', "data-toggle='modal' data-width='80%' data-type='iframe' data-title='" . $lang->todo->view . "' data-icon='check'");?> + pri;?>' title='todo->priList, $todo->pri, $todo->pri);?>'>todo->priList, $todo->pri)?> + date == '2030-01-01' ? $lang->todo->periods['future'] : $todo->date;?> + todo->statusList[$todo->status];?> + todo->typeList, $todo->type, '');?> + assignedTo);?> + + assignedBy);?> + begin;?> end;?> - todo->statusList[$todo->status];?> id", $todo, 'list', 'play', 'hiddenwin'); diff --git a/module/product/model.php b/module/product/model.php index 4537e9b12d..8b9842f863 100644 --- a/module/product/model.php +++ b/module/product/model.php @@ -1211,7 +1211,7 @@ class productModel extends model ->beginIF($branch !== '' and $branch !== 'all')->andWhere('t1.branch')->in($branch)->fi() ->andWhere('t2.deleted')->eq('0') ->orderBy($orderBy) - ->page($pager) + ->page($pager, 't2.id') ->fetchAll('id'); /* Determine how to display the name of the program. */ diff --git a/module/product/view/project.html.php b/module/product/view/project.html.php index 7e6c9a6fe5..bb9e0f67d1 100644 --- a/module/product/view/project.html.php +++ b/module/product/view/project.html.php @@ -62,8 +62,18 @@ - + + status == 'wait') $waitCount ++;?> + status == 'doing') $doingCount ++;?> + status == 'suspended') $suspendedCount ++;?> + status == 'closed') $closedCount ++;?> id);?> systemMode == 'new'):?> @@ -107,7 +117,10 @@ - + diff --git a/module/productplan/control.php b/module/productplan/control.php index 559c0d5c85..a7c42d0fbd 100644 --- a/module/productplan/control.php +++ b/module/productplan/control.php @@ -440,10 +440,12 @@ class productplan extends control if($plan->branch > 0) $this->view->branchStatus = $this->loadModel('branch')->getById($plan->branch, $plan->product, 'status'); + $storyIdList = array(); $modulePairs = $this->loadModel('tree')->getOptionMenu($plan->product, 'story', 0, 'all'); foreach($planStories as $story) { if(!isset($modulePairs[$story->module])) $modulePairs += $this->tree->getModulesName($story->module); + $storyIdList[] = $story->id; } $this->loadModel('datatable'); @@ -466,6 +468,7 @@ class productplan extends control $this->view->storyPager = $storyPager; $this->view->bugPager = $bugPager; $this->view->canBeChanged = $canBeChanged; + $this->view->storyCases = $storyCases = $this->loadModel('testcase')->getStoryCaseCounts($storyIdList);; if($this->app->getViewType() == 'json') { diff --git a/module/productplan/js/view.js b/module/productplan/js/view.js index 012a26ee42..1658a7a071 100644 --- a/module/productplan/js/view.js +++ b/module/productplan/js/view.js @@ -84,4 +84,46 @@ $(function() history.pushState({}, 0, createLink('productplan', 'view', "planID=" + planID + '&type=story&orderBy=' + order)); }); }); + + $('.table-story').table( + { + statisticCreator: function(table) + { + var $checkedRows = table.getTable().find(table.isDataTable ? '.datatable-row-left.checked' : 'tbody>tr.checked'); + var $originTable = table.isDataTable ? table.$.find('.datatable-origin') : null; + var checkedTotal = $checkedRows.length; + if(!checkedTotal) return; + + var checkedEstimate = 0; + var checkedCase = 0; + var rateCount = checkedTotal; + $checkedRows.each(function() + { + var $row = $(this); + if($originTable) + { + $row = $originTable.find('tbody>tr[data-id="' + $row.data('id') + '"]'); + } + var data = $row.data(); + checkedEstimate += data.estimate; + + if(data.cases > 0) + { + checkedCase += 1; + } + else if(data.children != undefined && data.children > 0) + { + rateCount -= 1; + } + }); + + var rate = '0%'; + if(rateCount) rate = Math.round(checkedCase / rateCount * 100) + '%'; + + if(checkedTotal == 0) return storySummary; + return checkedSummary.replace('%total%', checkedTotal) + .replace('%estimate%', checkedEstimate.toFixed(1)) + .replace('%rate%', rate); + } + }); }); diff --git a/module/productplan/view/view.html.php b/module/productplan/view/view.html.php index dfc20fdf79..44f4e5c692 100644 --- a/module/productplan/view/view.html.php +++ b/module/productplan/view/view.html.php @@ -20,6 +20,9 @@ pageID);?> recPerPage);?> recTotal);?> + +SRCommon);?> +SRCommon, $lang->product->checkedSummary));?>