Merge branch 'zenops_46' of https://gitlab.zcorp.cc/easycorp/zentaopms into zenops_46

This commit is contained in:
zhaoke
2023-01-03 05:26:25 +00:00
42 changed files with 943 additions and 242 deletions
File diff suppressed because one or more lines are too long
+106 -106
View File
File diff suppressed because one or more lines are too long
+4 -2
View File
@@ -1237,7 +1237,8 @@ class block extends control
$this->view->sv = $this->weekly->getSV($this->view->ev, $this->view->pv);
$this->view->cv = $this->weekly->getCV($this->view->ev, $this->view->ac);
$progress = !empty($this->view->pv) ? floor($this->view->ac / $this->view->pv * 1000) / 1000 * 100 : 0;
$left = (float)$this->weekly->getLeft($this->session->project, $today);
$progress = (!empty($this->view->ac) or !empty($left)) ? floor($this->view->ac / ($this->view->ac + $left) * 1000) / 1000 * 100 : 0;
$this->view->progress = $progress > 100 ? 100 : $progress;
$this->view->current = $current;
}
@@ -1261,7 +1262,8 @@ class block extends control
$this->view->sv = $this->weekly->getSV($this->view->ev, $this->view->pv);
$this->view->cv = $this->weekly->getCV($this->view->ev, $this->view->ac);
$progress = !empty($this->view->pv) ? floor($this->view->ac / $this->view->pv * 1000) / 1000 * 100 : 0;
$left = (float)$data['left'];
$progress = (!empty($this->view->ac) or !empty($left)) ? floor($this->view->ac / ($this->view->ac + $left) * 1000) / 1000 * 100 : 0;
$this->view->progress = $progress > 100 ? 100 : $progress;
}
+1 -2
View File
@@ -19,8 +19,7 @@
.block-guide .tab-pane .dataTitle {font-size: 12px; color: #5E626D;}
.block-guide .tab-pane .app-client .menu {margin-top: 10px;}
.block-guide .tab-pane .app-client .menu,
.block-guide .tab-pane .app-client .tree-menu li {padding-left: 0;}
.block-guide .tab-pane .app-client .tree-menu li {line-height: 56px; border: 1px solid #EDEEF2;}
.block-guide .tab-pane .app-client .tree-menu li {line-height: 56px; border: 1px solid #EDEEF2; padding-left: 0; white-space: nowrap}
.block-guide .tab-pane .app-client .tree-menu li:nth-child(2) {border-top: none; border-bottom: none;}
.block-guide .tab-pane .app-client .tree-menu li a.iframe {display: flex;}
.block-guide .tab-pane .app-client .tree-menu li .avatar {background: #E6EAF1; width: 24px; height: 24px; margin-top: 16px; margin-right: 5px;}
+25 -8
View File
@@ -9,12 +9,21 @@
border: 1px solid #EDEEF2;
}
.preference-border > .preference-img {
flex: 0 0 160px;
flex: 0 0 80px;
}
.preference.picker-option-active >.preference-border {
border: 2px solid #2E7FFF;
}
.preference.picker-option-active {
background: unset!important;
}
.preference.picker-option-active > .preference-border {
background: rgba(230,240,255, 0.4)!important;
}
.picker-option.picker-option-selected.preference {
background: unset!important;
}
.picker-option.picker-option-selected.preference > .preference-border {
background: rgba(230,240,255, 0.4)!important;
}
.preference-text {
@@ -34,17 +43,25 @@
white-space: normal;
}
#pickerDropMenu-pk_URSR > .picker-option-list{
.picker-option.picker-option-active,
.picker-single .picker-option.picker-option-selected.picker-option-active.option-ursr,
.picker-option.picker-option-selected.option-ursr {
background: unset!important;
color: unset;
}
.picker-option.picker-option-active > .border,
.picker-single .picker-option.picker-option-selected.picker-option-active.option-ursr > .border,
.picker-single .picker-option.picker-option-selected.picker-option-active.option-ursr > .border {
background: rgba(230,240,255, 0.4)!important;
border: 1px solid #2E7FFF;
}
#pickerDropMenu-pk_URSR > .picker-option-list {
display: flex;
flex-wrap: wrap;
}
.option-ursr {
flex: 1 1 50%;
}
.option-ursr.picker-option-selected > .border,
.option-ursr.picker-option-active> .border {
border: none;
}
.option-ursr > .border {
height: 46px;
display: flex;
@@ -116,8 +133,8 @@ function initPreference() {
'project-kanban': 'kanban',
'execution-all': 'list',
'execution-task': 'kanban',
'execution-executionkanban': 'list-recent',
'execution-task': 'list-recent',
'execution-executionkanban': 'kanban',
}
function optionRenderProgram($option, b)
{
@@ -14,9 +14,30 @@
.block-waterfallreport .progress {position: absolute; left: 45px; top: 90px; right: 40px;}
.block-waterfallreport .progress-num {font-size: 20px; font-weight: 700;}
.block-waterfallreport .col-right .tile-amount {font-size: 20px;}
</style>
<div class="panel-move-handler"><span class='stage text-muted'><?php echo $current;?></span></div>
.block-waterfallreport #helpDropdown{display:inline-block; padding-left:5px; padding-right:10px;}
.block-waterfallreport #helpDropdown .dropdown-menu{width:600px; text-align:left; height:300px; overflow:auto; background: #fff; padding-left:8px;font-weight: normal;}
.block-waterfallreport #helpDropdown h2{font-size:14px; padding:0px; margin:0px; margin-top:10px;}
.block-waterfallreport #helpDropdown p{padding:0px; margin:0px; margin-top:10px;}
</style>
<script>
$(function()
{
$('.block-waterfallreport').each(function()
{
$(this).find('.panel-heading .panel-title #helpDropdown').remove();
$(this).find('.panel-heading .panel-title').append($('#helpDropdown.hidden'));
$(this).find('.panel-heading .panel-title #helpDropdown').removeClass('hidden');
})
})
</script>
<div id='helpDropdown' class="dropdown dropdown-hover hidden">
<a data-toggle="dropdown"><i class="icon-help"></i></a>
<div class="dropdown-menu">
<?php echo $lang->weekly->blockHelpNotice;?>
</div>
</div>
<div class="panel-body conatiner-fluid">
<div class='table-row'>
<div class="col col-left hide-in-sm">
+1
View File
@@ -10,3 +10,4 @@
.resolution {white-space: nowrap; overflow: hidden;}
.link-commit {overflow: hidden; white-space: nowrap; margin-right: 5px;}
.main-actions .btn-toolbar{display: inline-flex; flex-wrap: wrap;}
#legendBasicInfo td .label-severity {margin-left: -5px;}
+1 -1
View File
@@ -22,7 +22,7 @@
#kanban > .table {min-width: 1100px;}
#kanban.dragging .boards.dragging .board {background: #eee; opacity: .35; border-color: #f1f1f1;}
#kanban thead .c-side {padding: 5px;}
#kanban .label-pri {width: 16px; height: 16px; line-height: 12px; min-width: 16px; font-size: 12px; padding: 0;}
#kanban .label-pri {width: 16px; height: 16px; line-height: 14px; min-width: 16px; font-size: 12px; padding: 0;}
#kanban tbody > tr > td {line-height: 24px;}
#kanban .c-board {border-bottom: 4px #EAF3FC solid;}
#kanban .c-board.s-projected {border-color: #7EC5FF;}
+14
View File
@@ -0,0 +1,14 @@
var runCase = false;
/**
* Define triggerModal hidden event.
*
* @access public
* @return void
*/
function triggerHidden()
{
$('#triggerModal').on('hidden.zui.modal', function()
{
if(runCase == true) window.location.reload();
});
}
+2 -2
View File
@@ -338,7 +338,7 @@ class executionModel extends model
$multipleProducts = $this->loadModel('product')->getMultiBranchPairs();
foreach($_POST['products'] as $index => $productID)
{
if(isset($multipleProducts[$productID]) and empty($_POST['branch'][$index]))
if(isset($multipleProducts[$productID]) and !isset($_POST['branch'][$index]))
{
dao::$errors[] = $this->lang->project->emptyBranch;
return false;
@@ -534,7 +534,7 @@ class executionModel extends model
$multipleProducts = $this->loadModel('product')->getMultiBranchPairs();
foreach($_POST['products'] as $index => $productID)
{
if(isset($multipleProducts[$productID]) and empty($_POST['branch'][$index]))
if(isset($multipleProducts[$productID]) and !isset($_POST['branch'][$index]))
{
dao::$errors[] = $this->lang->project->emptyBranch;
return false;
+7 -1
View File
@@ -143,7 +143,9 @@
<?php $hasBranch = $product->type != 'normal' and isset($branchGroups[$product->id]);?>
<div class='input-group <?php if($hasBranch) echo ' has-branch';?>'>
<span class='input-group-addon'><?php echo $lang->product->common;?></span>
<?php echo html::select("products[$i]", $allProducts, $product->id, "class='form-control chosen' onchange='loadBranches(this)' data-last='" . $product->id . "' data-type='" . $product->type . "'");?>
<?php $disabled = ($project->model == 'waterfall' and !$project->division) ? "disabled='disabled'" : '';?>
<?php echo html::select("products[$i]", $allProducts, $product->id, "class='form-control chosen' $disabled onchange='loadBranches(this)' data-last='" . $product->id . "' data-type='" . $product->type . "'");?>
<?php if($project->model == 'waterfall' and !$project->division) echo html::hidden("products[$i]", $product->id);?>
</div>
</div>
<div class='table-col <?php if(!$hasBranch) echo 'hidden';?>'>
@@ -159,10 +161,12 @@
<div class='input-group' <?php echo "id='plan$i'";?>>
<span class='input-group-addon'><?php echo $lang->product->plan;?></span>
<?php echo html::select("plans[$product->id][]", isset($productPlans[$product->id]) ? $productPlans[$product->id] : array(), isset($product->plans) ? $product->plans : '', "class='form-control chosen' multiple");?>
<?php if(!($project->model == 'waterfall' and !$project->division)):?>
<div class='input-group-btn'>
<a href='javascript:;' onclick='addNewLine(this)' class='btn btn-link addLine'><i class='icon-plus'></i></a>
<a href='javascript:;' onclick='removeLine(this)' class='btn btn-link removeLine' <?php if($i == 0) echo "style='visibility: hidden'";?>><i class='icon-close'></i></a>
</div>
<?php endif;?>
</div>
</div>
</div>
@@ -195,10 +199,12 @@
<div class='input-group' id='plan0'>
<span class='input-group-addon'><?php echo $lang->product->plan;?></span>
<?php echo html::select("plans[][]", $productPlan, '', "class='form-control chosen' multiple");?>
<?php if(!($project->model == 'waterfall' and $project->division)):?>
<div class='input-group-btn'>
<a href='javascript:;' onclick='addNewLine(this)' class='btn btn-link addLine'><i class='icon-plus'></i></a>
<a href='javascript:;' onclick='removeLine(this)' class='btn btn-link removeLine' style='visibility: hidden'><i class='icon-close'></i></a>
</div>
<?php endif;?>
</div>
</div>
</div>
+5 -1
View File
@@ -154,7 +154,9 @@
<?php $hasBranch = $product->type != 'normal' and isset($branchGroups[$product->id]);?>
<div class='input-group <?php if($hasBranch) echo ' has-branch';?>'>
<span class='input-group-addon'><?php echo $lang->product->common;?></span>
<?php echo html::select("products[$i]", $allProducts, $product->id, "class='form-control chosen' onchange='loadBranches(this)' data-last='" . $product->id . "' data-type='" . $product->type . "'");?>
<?php $disabled = ($execution->type == 'stage' and !$execution->division) ? "disabled='disabled'" : '';?>
<?php echo html::select("products[$i]", $allProducts, $product->id, "class='form-control chosen' $disabled onchange='loadBranches(this)' data-last='" . $product->id . "' data-type='" . $product->type . "'");?>
<?php if($execution->type == 'stage' and !$execution->division) echo html::hidden("products[$i]", $product->id);?>
</div>
</div>
<div class='table-col <?php if(!$hasBranch) echo 'hidden';?>'>
@@ -170,10 +172,12 @@
<div class='input-group' <?php echo "id='plan$i'";?>>
<span class='input-group-addon'><?php echo $lang->product->plan;?></span>
<?php echo html::select("plans[$product->id][]", isset($productPlans[$product->id]) ? $productPlans[$product->id] : array(), $product->plans, "class='form-control chosen' multiple");?>
<?php if(!($execution->type == 'stage' and !$execution->division)):?>
<div class='input-group-btn'>
<a href='javascript:;' onclick='addNewLine(this)' class='btn btn-link addLine'><i class='icon-plus'></i></a>
<a href='javascript:;' onclick='removeLine(this)' class='btn btn-link removeLine' <?php if($i == 0) echo "style='visibility: hidden'";?>><i class='icon-close'></i></a>
</div>
<?php endif;?>
</div>
</div>
</div>
+27 -9
View File
@@ -1,6 +1,7 @@
.preference .table-form > tbody > tr > th {font-weight: 400; color: #0B0F18;}
.preference .chosen-container-single .chosen-single > span {color: #313C52;}
.tip {margin-top: 10px;}
.table-form>tbody>tr>th {white-space: nowrap!important}
.table-form>tbody>tr>td {width: 75%!important}
.preference > .preference-border {
display: flex;
@@ -8,12 +9,21 @@
border: 1px solid #EDEEF2;
}
.preference-border > .preference-img {
flex: 0 0 160px;
flex: 0 0 80px;
}
.preference.picker-option-active >.preference-border {
border: 2px solid #2E7FFF;
}
.preference.picker-option-active {
background: unset!important;
}
.preference.picker-option-active > .preference-border {
background: rgba(230,240,255, 0.4)!important;
}
.picker-option.picker-option-selected.preference {
background: unset!important;
}
.picker-option.picker-option-selected.preference > .preference-border {
background: rgba(230,240,255, 0.4)!important;
}
.preference-text {
@@ -33,17 +43,25 @@
white-space: normal;
}
#pickerDropMenu-pk_URSR > .picker-option-list{
.picker-option.picker-option-active,
.picker-single .picker-option.picker-option-selected.picker-option-active.option-ursr,
.picker-option.picker-option-selected.option-ursr {
background: unset!important;
color: unset;
}
.picker-option.picker-option-active > .border,
.picker-single .picker-option.picker-option-selected.picker-option-active.option-ursr > .border,
.picker-single .picker-option.picker-option-selected.picker-option-active.option-ursr > .border {
background: rgba(230,240,255, 0.4)!important;
border: 1px solid #2E7FFF;
}
#pickerDropMenu-pk_URSR > .picker-option-list {
display: flex;
flex-wrap: wrap;
}
.option-ursr {
flex: 1 1 50%;
}
.option-ursr.picker-option-selected > .border,
.option-ursr.picker-option-active> .border {
border: none;
}
.option-ursr > .border {
height: 46px;
display: flex;
@@ -61,4 +79,4 @@
.option-ursr > .border > .value > p {
line-height: 20px;
text-align: center;
}
}
+2 -2
View File
@@ -16,8 +16,8 @@ function initPreference() {
'project-kanban': 'kanban',
'execution-all': 'list',
'execution-task': 'kanban',
'execution-executionkanban': 'list-recent',
'execution-task': 'list-recent',
'execution-executionkanban': 'kanban',
}
function optionRenderProgram($option, b)
{
+12 -12
View File
@@ -131,22 +131,22 @@ $lang->my->programLinkList['program-kanban'] = '项目集看板/可以可视化
$lang->my->programLinkList['program-project'] = '最近一个项目集的项目列表/可以查看当前项目集下所有项目';
$lang->my->productLinkList = array();
$lang->my->productLinkList['product-all'] = '产品列表/可以查看所有的产品';
$lang->my->productLinkList['product-kanban'] = '产品看板/可以可视化的查看到所有产品的进展情况';
$lang->my->productLinkList['product-index'] = '所有产品仪表盘/可以查看所有产品的统计';
$lang->my->productLinkList['product-dashboard'] = '最近一个产品仪表盘/可以查看当前产品概况';
$lang->my->productLinkList['product-browse'] = '最近一个产品的需求列表/可以查看当前产品下的需求信息';
$lang->my->productLinkList['product-all'] = '产品列表/可以查看所有产品';
$lang->my->productLinkList['product-kanban'] = '产品看板/以可视化的方式查看到所有产品的整体情况';
$lang->my->productLinkList['product-index'] = '所有产品仪表盘/可以查看所有产品的统计,概况,总览等';
$lang->my->productLinkList['product-dashboard'] = '最近一个产品仪表盘/可以查看最近查看过的一个产品仪表盘';
$lang->my->productLinkList['product-browse'] = '最近一个产品的需求列表/可以进入最近查看过的一个产品下的研发需求列表';
$lang->my->projectLinkList = array();
$lang->my->projectLinkList['project-browse'] = '项目列表/可以查看所有的项目';
$lang->my->projectLinkList['project-execution'] = '项目下所有执行列表/查看所有执行信息';
$lang->my->projectLinkList['project-index'] = '最近一个项目仪表盘/可以查看当前项目概况';
$lang->my->projectLinkList['project-kanban'] = '项目看板/可以可视化的查看到所有项目的进展情况';
$lang->my->projectLinkList['project-browse'] = '项目列表/可以查看所有项目';
$lang->my->projectLinkList['project-kanban'] = '项目看板/以可视化的查看到所有项目的整体情况';
$lang->my->projectLinkList['project-execution'] = '最近一个项目执行列表/可以查看项目下所有的执行列表';
$lang->my->projectLinkList['project-index'] = '最近一个项目仪表盘/可以进入最近查看过的一个项目的仪表盘';
$lang->my->executionLinkList = array();
$lang->my->executionLinkList['execution-all'] = '执行列表/可以查看所有的执行';
$lang->my->executionLinkList['execution-task'] = '最近一个执行的任务列表/可以查看当前迭代下的任务信息';
$lang->my->executionLinkList['execution-executionkanban'] = '执行看板/可以查看进行中项目的执行情况';
$lang->my->executionLinkList['execution-all'] = '执行列表/可以查看所有执行';
$lang->my->executionLinkList['execution-executionkanban'] = '执行看板/以可视化的方式查看所有执行的整体情况';
$lang->my->executionLinkList['execution-task'] = '最近一个执行的任务列表/可以查看最近创建的一个执行下的任务';
$lang->my->confirmReview['pass'] = '您确定要执行通过操作吗?';
$lang->my->guideChangeTheme = <<<EOT
+1 -1
View File
@@ -244,7 +244,7 @@ class productplan extends control
if($this->post->comments)
{
$allChanges = $this->productplan->batchChangeStatus($status);
return print(js::locate(inlink('browse', "product=$productID"), 'parent'));
return print(js::locate(inlink('browse', "product=$productID")));
}
$plans = $this->dao->select('*')->from(TABLE_PRODUCTPLAN)->where('id')->in($planIDList)->fetchAll('id');
+13 -9
View File
@@ -457,17 +457,15 @@ class projectModel extends model
public function getWaterfallPVEVAC($projectID)
{
$executions = $this->dao->select('id,begin,end,realEnd,status')->from(TABLE_EXECUTION)->where('deleted')->eq(0)->andWhere('vision')->eq($this->config->vision)->andWhere('project')->eq($projectID)->fetchAll('id');
$stmt = $this->dao->select('id,status,estimate,consumed,`left`,closedReason')->from(TABLE_TASK)->where('execution')->in(array_keys($executions))->andWhere("parent")->ge(0)->andWhere("deleted")->eq(0)->query();
$stmt = $this->dao->select('id,status,estimate,consumed,`left`,closedReason')->from(TABLE_TASK)->where('execution')->in(array_keys($executions))->andWhere("parent")->ge(0)->andWhere("deleted")->eq(0)->andWhere('status')->ne('cancel')->query();
$PV = 0;
$EV = 0;
$AC = 0;
$PV = 0;
$EV = 0;
$left = 0;
while($task = $stmt->fetch())
{
if(empty($task->estimate)) continue;
$PV += $task->estimate;
$AC += $task->consumed;
$PV += $task->estimate;
$left += $task->left;
if($task->status == 'done' or $task->closedReason == 'done')
{
$EV += $task->estimate;
@@ -480,7 +478,13 @@ class projectModel extends model
}
}
return array('PV' => sprintf("%.2f", $PV), 'EV' => sprintf("%.2f", $EV), 'AC' => sprintf("%.2f", $AC));
$AC = $this->dao->select('SUM(consumed) as consumed')->from(TABLE_EFFORT)
->where('deleted')->eq(0)
->andWhere('project')->eq($projectID)
->fetch('consumed');
if(is_null($AC)) $AC = 0;
return array('PV' => sprintf("%.2f", $PV), 'EV' => sprintf("%.2f", $EV), 'AC' => sprintf("%.2f", $AC), 'left' => sprintf("%.2f", $left));
}
/**
+1 -1
View File
@@ -49,7 +49,7 @@ class screen extends control
{
$this->loadModel('execution');
$this->view->executions = $this->screen->getBurnData();
$this->view->date = date('Y-m-d h:i:s');
$this->view->date = date('Y-m-d H:i:s');
$this->display('screen', 'burn');
}
else
+2 -1
View File
@@ -4322,8 +4322,9 @@ class taskModel extends model
private function updateExecutionEsDateByGantt($objectID, $objectType, $postData)
{
$objectData = $this->dao->select('*')->from(TABLE_PROJECT)->where('id')->eq($objectID)->fetch();
$parent = $objectData->parent;
$project = $objectData->project;
$parent = '';
if($objectData->project != $objectData->parent) $parent = $objectData->parent;
if(empty($parent))
{
+3
View File
@@ -25,3 +25,6 @@ tbody > tr > td .icon-share {font-size: 9px;}
#importToLib .select-lib {width: 100px; text-align: right;}
#subHeader #currentBranch + #dropMenu .col-left {padding-bottom: 30px;}
.status-blocked {left: -5px;}
#mainMenu .pull-left .dividing-line {margin: 7px 5px 0 0;}
.btn-toolbar>.btn, .btn-toolbar>.btn-group, .btn-toolbar>.dropdown {margin-right: 5px;}
+12 -6
View File
@@ -2,9 +2,15 @@
.col-side .chosen-container {width: 218px !important;}
.table-form > tbody > tr > td .btn.addbutton {display: block; margin: 1px 0px; width: 40px; padding: 1px 6px;}
.table-form > tbody > tr > td .btn.delbutton {display: block; margin: 1px 0px; width: 40px; padding: 1px 6px;}
#branch {width: 95px!important;}
.detail > table > tbody th {width: 100px !important;}
[lang^=en] .detail > table > tbody th, [lang^=fr] .detail > table > tbody th {width: 100px !important;}
[lang^=de] .detail > table > tbody th {width: 125px !important;}
.linkCaseTitle, .linkBugTitle {white-space: nowrap;}
#type_chosen{display: table-cell;}
#branch {width: 95px!important;}
.detail > table > tbody th {width: 100px !important;}
[lang^=en] .detail > table > tbody th, [lang^=fr] .detail > table > tbody th {width: 100px !important;}
[lang^=de] .detail > table > tbody th {width: 125px !important;}
.linkCaseTitle, .linkBugTitle {white-space: nowrap;}
#type_chosen{display: table-cell;}
.autoScript .file-input .file-title{max-width: 70px;}
@media screen and (max-width: 1366px) {
#module_chosen{min-width: 60px;}
}
+14
View File
@@ -40,3 +40,17 @@ $(function()
});
});
var runCase = false;
/**
* Define triggerModal hidden event.
*
* @access public
* @return void
*/
function triggerHidden()
{
$('#triggerModal').on('hidden.zui.modal', function()
{
if(runCase == true) window.location.reload();
});
}
+1 -1
View File
@@ -99,7 +99,7 @@ $lang->testcase->suite = 'Test Suite';
$lang->testcase->executionStatus = 'executionStatus';
$lang->testcase->caseType = 'Case Type';
$lang->testcase->allType = 'All Types';
$lang->testcase->showAutoCase = 'Automated Test Cases';
$lang->testcase->showAutoCase = 'Automated';
$lang->testcase->automation = 'Automation Test';
$lang->case = $lang->testcase; // For dao checking using. Because 'case' is a php keywords, so the module name is testcase, table name is still case.
+1 -1
View File
@@ -99,7 +99,7 @@ $lang->testcase->suite = 'Test Suite';
$lang->testcase->executionStatus = 'executionStatus';
$lang->testcase->caseType = 'Case Type';
$lang->testcase->allType = 'All Types';
$lang->testcase->showAutoCase = 'Automated Test Cases';
$lang->testcase->showAutoCase = 'Automated';
$lang->testcase->automation = 'Automation Test';
$lang->case = $lang->testcase; // For dao checking using. Because 'case' is a php keywords, so the module name is testcase, table name is still case.
+1 -1
View File
@@ -99,7 +99,7 @@ $lang->testcase->suite = 'Test Suite';
$lang->testcase->executionStatus = 'executionStatus';
$lang->testcase->caseType = 'Case Type';
$lang->testcase->allType = 'All Types';
$lang->testcase->showAutoCase = 'Automated Test Cases';
$lang->testcase->showAutoCase = 'Automated';
$lang->testcase->automation = 'Automation Test';
$lang->case = $lang->testcase; // For dao checking using. Because 'case' is a php keywords, so the module name is testcase, table name is still case.
+4
View File
@@ -95,12 +95,16 @@ $(document).ready(function()
$("#submit").attr({"disabled":"disabled"});
});
}
if(typeof(window.parent.runCase) != 'undefined') window.parent.runCase = true;
}
return false;
}
});
window.parent.triggerHidden();
$(document).on('click', ".step-group input[type='checkbox']", function()
{
var $next = $(this).closest('tr').next();
+3 -3
View File
@@ -1500,7 +1500,7 @@ class testtaskModel extends model
$failHtml = ': <span class="result-testcase fail">' . $this->lang->testtask->fail . '</span>';
$passHtml = ': <span class="result-testcase pass">' . $this->lang->testtask->pass . '</span>';
$log = preg_replace(array("/:\x20失败/", "/:\x20fail/", "/:\x20成功/", "/:\x20pass/"), array($failHtml, $failHtml, $passHtml, $passHtml), $log);
$logHtml .= "<li>" . $log . "</li>";
@@ -1524,11 +1524,11 @@ class testtaskModel extends model
}
$caseResult = $passCount ? 'pass':'fail';
$logHtml .= "<li class='result-testcase {$caseResult}'>"
$logHtml .= "<li class='result-testcase {$caseResult}'>"
. sprintf($this->lang->testtask->stepSummary, $total, $passCount, $failCount)
. "</li>";
}
return $logHtml;
}
+5
View File
@@ -1,3 +1,8 @@
#mainContent td.projectName {white-space: nowrap; overflow-x: hidden;}
#pageNav .angle-btn:first-child a.btn {max-width: 300px; overflow: hidden;}
.totalCount {height: 36px !important; line-height: 30px; font-weight: bold; text-align: right !important; padding: 0px 50px 0px 8px !important; width: 100%;}
#helpDropdown{display:inline-block; padding-left:5px; padding-right:10px;}
#helpDropdown .dropdown-menu{width:600px; text-align:left; height:300px; overflow:auto; background: #fff; padding-left:8px;}
#helpDropdown h2{font-size:14px; padding:0px; margin:0px; margin-top:10px;}
#helpDropdown p{padding:0px; margin:0px; margin-top:10px;}
+102
View File
@@ -41,3 +41,105 @@ $lang->weekly->cv = 'Cost Variance(CV%)';
$lang->weekly->totalCount = 'Total : %u tasks';
$lang->weekly->exportWeeklyReport = 'Export Weekly Report';
$lang->weekly->reportHelpNotice = <<<EOD
<h2>PV Planned Value</h2>
Calculation method:
<br />1) The estimated start date and end date of the task are within the range of the start and end dates of this week, and the estimated work hours are accumulated
<br />2) The estimated start date and end date of the task are before the start and end date of this week, and the estimated work hours are accumulated
<br />3) The scheduled start date of the task is earlier than the start date of this week, the end date is later than the start date of this week, and the scheduled work hours are accumulated when it is earlier than the end date of this week
<br />4) The expected start date of a task is later than the start date of this week, less than the end date of this week, and the end date is later than the end date of this week. The cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<br />5) The estimated start date of a task is equal to the start date of this week, and the end date is greater than the end date of this week. The cumulative (estimated work hours of the task ÷ task duration days) x the number of days from the estimated start date of the task to the end date of this week
<br />6) The scheduled start date of the task is earlier than the start date of this week, and the end date is equal to the end date of this week. The scheduled work hours are accumulated
<br />7) If the expected start date of a task is earlier than the start date of this week and the end date is later than the end date of this week, the cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<p>Statistical range:</p>
1) Start date of this week: 00:00:00 on Monday End date of this week: determined according to the calculation of working days and holidays
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) No expected start date is filled in the task. The expected start date defaults to the planned start date of the phase to which the task belongs
<br />7) No expected end date is filled in the task. By default, the expected end date is the planned completion date of the phase to which the task belongs
<br />8) Calculation formula only calculates working days
<h2>EV Earned Value</h2>
Calculation method:
<br />1) The task status is done, and the estimated work hours are accumulated
<br />2) The task status is closed and the reason for closing is done, and the estimated work hours are accumulated
<br />3) The task status is in doing, suspended, and the estimated work hours are accumulated × progress
<p>Statistical range:</p>
1) Tasks whose work consumption is not 0 before the end date of this week
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) Progress= consumed man hours ÷(consumed man hours+remaining man hours)
<h2>AC Actual Cost</h2>
Calculation method:
<br />1) Accumulate all consumed work hours before the end date of this week
<p>Statistical range:</p>
1) All consumed man hours include task, requirement, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and time consuming of reviews
<br />4) Including the time consumption of deleted tasks, requirements, bugs, use cases, versions, test sheets and documents in execution
<br />5) Including the time consumption of cancelled tasks, problems and risks
<h2>SV(%) Schedule Variance</h2>
Calculation method: SV(%) = -1 * (1 - (EV / PV))%
<h2>CV(%) Cost Variance</h2>
Calculation method: CV(%) = -1 * (1 - (EV / AC))%
EOD;
$lang->weekly->blockHelpNotice = <<<EOD
<h2>Progress this week</h2>
Calculation method:
<br />1) Progress of this week=total consumed man hours/(total consumed man hours+remaining man hours)
<p>Statistical range:</p>
1) The total consumed man hours include task, demand, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, the task only contains child tasks, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and consumed man hours in reviews
<br />4) This includes the work hours consumed by deleted tasks, requirements, bugs, use cases, versions, test sheets, and documents
<br />5) Including work hours consumed by cancelled tasks, problems and risks
<br />6) Exclude remaining work on canceled tasks
<br />7) Exclude remaining work for deleted tasks in progress
<h2>PV Planned Value</h2>
Calculation method:
<br />1) The estimated start date and end date of the task are within the range of the start and end dates of this week, and the estimated work hours are accumulated
<br />2) The estimated start date and end date of the task are before the start and end date of this week, and the estimated work hours are accumulated
<br />3) The scheduled start date of the task is earlier than the start date of this week, the end date is later than the start date of this week, and the scheduled work hours are accumulated when it is earlier than the end date of this week
<br />4) The expected start date of a task is later than the start date of this week, less than the end date of this week, and the end date is later than the end date of this week. The cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<br />5) The estimated start date of a task is equal to the start date of this week, and the end date is greater than the end date of this week. Accumulate (estimated work hours of a task ÷ task duration days) × The number of days from the expected start of the task to the end of this week
<br />6) The scheduled start date of the task is earlier than the start date of this week, and the end date is equal to the end date of this week. The scheduled work hours are accumulated
<br />7) The expected start date of a task is earlier than the start date of this week, and the end date is later than the end date of this week. Accumulate (the expected work hours of the task ÷ the task duration days) × The number of days from the expected start of the task to the end of this week
<p>Statistical range:</p>
1) Start date of this week: 00:00:00 on Monday End date of this week: determined according to the calculation of working days and holidays
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) No expected start date is filled in the task. The expected start date defaults to the planned start date of the phase to which the task belongs
<br />7) No expected end date is filled in the task. By default, the expected end date is the planned completion date of the phase to which the task belongs
<br />8) Calculation formula only calculates working days
<h2>EV Earned Value</h2>
Calculation method:
<br />1) The task status is done, and the estimated work hours are accumulated
<br />2) The task status is closed and the reason for closing is done, and the estimated work hours are accumulated
<br />3) The task status is in doing, suspended, and the estimated work hours are accumulated ×progress
<p>Statistical range:</p>
1) Tasks whose work consumption is not 0 before the end date of this week
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude deleted tasks in progress
<br />6) Progress=consumed man hours ÷ (consumed man hours+remaining man hours)
<h2>AC Actual Cost</h2>
Calculation method:
<br />1) Accumulate all consumed work hours before the end date of this week
<p>Statistical range:</p>
1) All consumed man hours include task, requirement, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and time consuming of reviews
<br />4) Including the time consumption of deleted tasks, requirements, bugs, use cases, versions, test sheets and documents in execution
<br />5) Including the time consumption of cancelled tasks, problems and risks
<h2>SV(%) Schedule Variance</h2>
Calculation method: SV(%) = -1 * (1 - (EV / PV))%
<h2>CV(%) Schedule Variance</h2>
Calculation method: CV(%) = -1 * (1 - (EV / AC))%
EOD;
+102
View File
@@ -41,3 +41,105 @@ $lang->weekly->cv = 'Cost Variance(CV%)';
$lang->weekly->totalCount = 'Total : %u tasks';
$lang->weekly->exportWeeklyReport = 'Export Weekly Report';
$lang->weekly->reportHelpNotice = <<<EOD
<h2>PV Planned Value</h2>
Calculation method:
<br />1) The estimated start date and end date of the task are within the range of the start and end dates of this week, and the estimated work hours are accumulated
<br />2) The estimated start date and end date of the task are before the start and end date of this week, and the estimated work hours are accumulated
<br />3) The scheduled start date of the task is earlier than the start date of this week, the end date is later than the start date of this week, and the scheduled work hours are accumulated when it is earlier than the end date of this week
<br />4) The expected start date of a task is later than the start date of this week, less than the end date of this week, and the end date is later than the end date of this week. The cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<br />5) The estimated start date of a task is equal to the start date of this week, and the end date is greater than the end date of this week. The cumulative (estimated work hours of the task ÷ task duration days) x the number of days from the estimated start date of the task to the end date of this week
<br />6) The scheduled start date of the task is earlier than the start date of this week, and the end date is equal to the end date of this week. The scheduled work hours are accumulated
<br />7) If the expected start date of a task is earlier than the start date of this week and the end date is later than the end date of this week, the cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<p>Statistical range:</p>
1) Start date of this week: 00:00:00 on Monday End date of this week: determined according to the calculation of working days and holidays
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) No expected start date is filled in the task. The expected start date defaults to the planned start date of the phase to which the task belongs
<br />7) No expected end date is filled in the task. By default, the expected end date is the planned completion date of the phase to which the task belongs
<br />8) Calculation formula only calculates working days
<h2>EV Earned Value</h2>
Calculation method:
<br />1) The task status is done, and the estimated work hours are accumulated
<br />2) The task status is closed and the reason for closing is done, and the estimated work hours are accumulated
<br />3) The task status is in doing, suspended, and the estimated work hours are accumulated × progress
<p>Statistical range:</p>
1) Tasks whose work consumption is not 0 before the end date of this week
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) Progress= consumed man hours ÷(consumed man hours+remaining man hours)
<h2>AC Actual Cost</h2>
Calculation method:
<br />1) Accumulate all consumed work hours before the end date of this week
<p>Statistical range:</p>
1) All consumed man hours include task, requirement, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and time consuming of reviews
<br />4) Including the time consumption of deleted tasks, requirements, bugs, use cases, versions, test sheets and documents in execution
<br />5) Including the time consumption of cancelled tasks, problems and risks
<h2>SV(%) Schedule Variance</h2>
Calculation method: SV(%) = -1 * (1 - (EV / PV))%
<h2>CV(%) Cost Variance</h2>
Calculation method: CV(%) = -1 * (1 - (EV / AC))%
EOD;
$lang->weekly->blockHelpNotice = <<<EOD
<h2>Progress this week</h2>
Calculation method:
<br />1) Progress of this week=total consumed man hours/(total consumed man hours+remaining man hours)
<p>Statistical range:</p>
1) The total consumed man hours include task, demand, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, the task only contains child tasks, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and consumed man hours in reviews
<br />4) This includes the work hours consumed by deleted tasks, requirements, bugs, use cases, versions, test sheets, and documents
<br />5) Including work hours consumed by cancelled tasks, problems and risks
<br />6) Exclude remaining work on canceled tasks
<br />7) Exclude remaining work for deleted tasks in progress
<h2>PV Planned Value</h2>
Calculation method:
<br />1) The estimated start date and end date of the task are within the range of the start and end dates of this week, and the estimated work hours are accumulated
<br />2) The estimated start date and end date of the task are before the start and end date of this week, and the estimated work hours are accumulated
<br />3) The scheduled start date of the task is earlier than the start date of this week, the end date is later than the start date of this week, and the scheduled work hours are accumulated when it is earlier than the end date of this week
<br />4) The expected start date of a task is later than the start date of this week, less than the end date of this week, and the end date is later than the end date of this week. The cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<br />5) The estimated start date of a task is equal to the start date of this week, and the end date is greater than the end date of this week. Accumulate (estimated work hours of a task ÷ task duration days) × The number of days from the expected start of the task to the end of this week
<br />6) The scheduled start date of the task is earlier than the start date of this week, and the end date is equal to the end date of this week. The scheduled work hours are accumulated
<br />7) The expected start date of a task is earlier than the start date of this week, and the end date is later than the end date of this week. Accumulate (the expected work hours of the task ÷ the task duration days) × The number of days from the expected start of the task to the end of this week
<p>Statistical range:</p>
1) Start date of this week: 00:00:00 on Monday End date of this week: determined according to the calculation of working days and holidays
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) No expected start date is filled in the task. The expected start date defaults to the planned start date of the phase to which the task belongs
<br />7) No expected end date is filled in the task. By default, the expected end date is the planned completion date of the phase to which the task belongs
<br />8) Calculation formula only calculates working days
<h2>EV Earned Value</h2>
Calculation method:
<br />1) The task status is done, and the estimated work hours are accumulated
<br />2) The task status is closed and the reason for closing is done, and the estimated work hours are accumulated
<br />3) The task status is in doing, suspended, and the estimated work hours are accumulated ×progress
<p>Statistical range:</p>
1) Tasks whose work consumption is not 0 before the end date of this week
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude deleted tasks in progress
<br />6) Progress=consumed man hours ÷ (consumed man hours+remaining man hours)
<h2>AC Actual Cost</h2>
Calculation method:
<br />1) Accumulate all consumed work hours before the end date of this week
<p>Statistical range:</p>
1) All consumed man hours include task, requirement, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and time consuming of reviews
<br />4) Including the time consumption of deleted tasks, requirements, bugs, use cases, versions, test sheets and documents in execution
<br />5) Including the time consumption of cancelled tasks, problems and risks
<h2>SV(%) Schedule Variance</h2>
Calculation method: SV(%) = -1 * (1 - (EV / PV))%
<h2>CV(%) Schedule Variance</h2>
Calculation method: CV(%) = -1 * (1 - (EV / AC))%
EOD;
+102
View File
@@ -41,3 +41,105 @@ $lang->weekly->cv = 'Cost Variance(CV%)';
$lang->weekly->totalCount = 'Total : %u tasks';
$lang->weekly->exportWeeklyReport = 'Export Weekly Report';
$lang->weekly->reportHelpNotice = <<<EOD
<h2>PV Planned Value</h2>
Calculation method:
<br />1) The estimated start date and end date of the task are within the range of the start and end dates of this week, and the estimated work hours are accumulated
<br />2) The estimated start date and end date of the task are before the start and end date of this week, and the estimated work hours are accumulated
<br />3) The scheduled start date of the task is earlier than the start date of this week, the end date is later than the start date of this week, and the scheduled work hours are accumulated when it is earlier than the end date of this week
<br />4) The expected start date of a task is later than the start date of this week, less than the end date of this week, and the end date is later than the end date of this week. The cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<br />5) The estimated start date of a task is equal to the start date of this week, and the end date is greater than the end date of this week. The cumulative (estimated work hours of the task ÷ task duration days) x the number of days from the estimated start date of the task to the end date of this week
<br />6) The scheduled start date of the task is earlier than the start date of this week, and the end date is equal to the end date of this week. The scheduled work hours are accumulated
<br />7) If the expected start date of a task is earlier than the start date of this week and the end date is later than the end date of this week, the cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<p>Statistical range:</p>
1) Start date of this week: 00:00:00 on Monday End date of this week: determined according to the calculation of working days and holidays
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) No expected start date is filled in the task. The expected start date defaults to the planned start date of the phase to which the task belongs
<br />7) No expected end date is filled in the task. By default, the expected end date is the planned completion date of the phase to which the task belongs
<br />8) Calculation formula only calculates working days
<h2>EV Earned Value</h2>
Calculation method:
<br />1) The task status is done, and the estimated work hours are accumulated
<br />2) The task status is closed and the reason for closing is done, and the estimated work hours are accumulated
<br />3) The task status is in doing, suspended, and the estimated work hours are accumulated × progress
<p>Statistical range:</p>
1) Tasks whose work consumption is not 0 before the end date of this week
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) Progress= consumed man hours ÷(consumed man hours+remaining man hours)
<h2>AC Actual Cost</h2>
Calculation method:
<br />1) Accumulate all consumed work hours before the end date of this week
<p>Statistical range:</p>
1) All consumed man hours include task, requirement, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and time consuming of reviews
<br />4) Including the time consumption of deleted tasks, requirements, bugs, use cases, versions, test sheets and documents in execution
<br />5) Including the time consumption of cancelled tasks, problems and risks
<h2>SV(%) Schedule Variance</h2>
Calculation method: SV(%) = -1 * (1 - (EV / PV))%
<h2>CV(%) Cost Variance</h2>
Calculation method: CV(%) = -1 * (1 - (EV / AC))%
EOD;
$lang->weekly->blockHelpNotice = <<<EOD
<h2>Progress this week</h2>
Calculation method:
<br />1) Progress of this week=total consumed man hours/(total consumed man hours+remaining man hours)
<p>Statistical range:</p>
1) The total consumed man hours include task, demand, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, the task only contains child tasks, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and consumed man hours in reviews
<br />4) This includes the work hours consumed by deleted tasks, requirements, bugs, use cases, versions, test sheets, and documents
<br />5) Including work hours consumed by cancelled tasks, problems and risks
<br />6) Exclude remaining work on canceled tasks
<br />7) Exclude remaining work for deleted tasks in progress
<h2>PV Planned Value</h2>
Calculation method:
<br />1) The estimated start date and end date of the task are within the range of the start and end dates of this week, and the estimated work hours are accumulated
<br />2) The estimated start date and end date of the task are before the start and end date of this week, and the estimated work hours are accumulated
<br />3) The scheduled start date of the task is earlier than the start date of this week, the end date is later than the start date of this week, and the scheduled work hours are accumulated when it is earlier than the end date of this week
<br />4) The expected start date of a task is later than the start date of this week, less than the end date of this week, and the end date is later than the end date of this week. The cumulative (expected work hours of the task ÷ task duration days) x the days from the expected start date of the task to the end date of this week
<br />5) The estimated start date of a task is equal to the start date of this week, and the end date is greater than the end date of this week. Accumulate (estimated work hours of a task ÷ task duration days) × The number of days from the expected start of the task to the end of this week
<br />6) The scheduled start date of the task is earlier than the start date of this week, and the end date is equal to the end date of this week. The scheduled work hours are accumulated
<br />7) The expected start date of a task is earlier than the start date of this week, and the end date is later than the end date of this week. Accumulate (the expected work hours of the task ÷ the task duration days) × The number of days from the expected start of the task to the end of this week
<p>Statistical range:</p>
1) Start date of this week: 00:00:00 on Monday End date of this week: determined according to the calculation of working days and holidays
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude tasks in deleted execution
<br />6) No expected start date is filled in the task. The expected start date defaults to the planned start date of the phase to which the task belongs
<br />7) No expected end date is filled in the task. By default, the expected end date is the planned completion date of the phase to which the task belongs
<br />8) Calculation formula only calculates working days
<h2>EV Earned Value</h2>
Calculation method:
<br />1) The task status is done, and the estimated work hours are accumulated
<br />2) The task status is closed and the reason for closing is done, and the estimated work hours are accumulated
<br />3) The task status is in doing, suspended, and the estimated work hours are accumulated ×progress
<p>Statistical range:</p>
1) Tasks whose work consumption is not 0 before the end date of this week
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Exclude deleted tasks
<br />4) Exclude canceled tasks
<br />5) Exclude deleted tasks in progress
<br />6) Progress=consumed man hours ÷ (consumed man hours+remaining man hours)
<h2>AC Actual Cost</h2>
Calculation method:
<br />1) Accumulate all consumed work hours before the end date of this week
<p>Statistical range:</p>
1) All consumed man hours include task, requirement, bug, use case, version, test sheet, problem, risk, document and review time
<br />2) To avoid repeated calculation, only child tasks are included, not parent tasks
<br />3) Including deleted tasks, requirements, bugs, use cases, versions, test sheets, problems, risks, documents, and time consuming of reviews
<br />4) Including the time consumption of deleted tasks, requirements, bugs, use cases, versions, test sheets and documents in execution
<br />5) Including the time consumption of cancelled tasks, problems and risks
<h2>SV(%) Schedule Variance</h2>
Calculation method: SV(%) = -1 * (1 - (EV / PV))%
<h2>CV(%) Schedule Variance</h2>
Calculation method: CV(%) = -1 * (1 - (EV / AC))%
EOD;
+103
View File
@@ -41,3 +41,106 @@ $lang->weekly->cv = '成本偏差率(CV%)';
$lang->weekly->totalCount = '总计 : %u 个任务';
$lang->weekly->exportWeeklyReport = '导出周报';
$lang->weekly->reportHelpNotice = <<<EOD
<h2>PV 计划完成的工作</h2>
计算方式:
<br />1)任务预计开始日期、截止日期在本周起止日期范围内,累加预计工时
<br />2)任务预计开始日期、截止日期在本周起止日期之前,累加预计工时
<br />3)任务预计开始日期小于本周开始日期,截止日期大于本周开始日期,小于本周结束日期,累加预计工时
<br />4)任务预计开始日期大于本周开始日期,小于本周截止日期,截止日期大于本周结束日期,累加 (任务的预计工时÷任务工期天数)× 任务预计开始到本周结束日期的天数
<br />5)任务预计开始日期等于本周开始日期,截止日期大于本周结束日期,累加 (任务的预计工时÷任务工期天数)× 任务预计开始到本周结束日期的天数
<br />6)任务预计开始日期小于本周开始日期,截止日期等于本周结束日期,累加预计工时
<br />7)任务预计开始日期小于本周开始日期,截止日期大于本周结束日期,累加 (任务的预计工时÷任务工期天数)× 任务预计开始到本周结束日期的天数
<p>统计范围:</p>
1)本周开始日期:周一 00:00:00 本周结束日期:根据工作日和节假日的计算来确定
<br />2)为避免重复计算,只包含子任务,不包括父任务
<br />3)不包括已删除的任务
<br />4)不包括已取消的任务
<br />5)不包括已删除执行中的任务
<br />6)任务未填写预计开始日期,预计开始日期默认取任务所属阶段的计划开始日期
<br />7)任务未填写预计截止日期,预计截止日期默认取任务所属阶段的计划完成日期
<br />8)计算公式只计算工作日
<h2>EV实际完成的工作</h2>
计算方式:
<br />1)任务状态为已完成,累加预计工时
<br />2)任务状态为已关闭且关闭原因为已完成,累加预计工时
<br />3)任务状态为进行中、已暂停,累加 预计工时×完成进度
<p>统计范围:</p>
1)本周结束日期之前消耗工时不为0的任务
<br />2)为避免重复计算,只包含子任务,不包括父任务
<br />3)不包括已删除的任务
<br />4)不包括已取消的任务
<br />5)不包括已删除执行中的任务
<br />6)完成进度=已消耗工时÷(已消耗工时+剩余工时)
<h2>AC 实际花费(消耗)的成本</h2>
计算方式:
<br />1)累加本周结束日期之前所有消耗的工时
<p>统计范围:</p>
1)所有消耗的工时包括任务、需求、Bug、用例、版本、测试单、问题、风险、文档、评审的耗时
<br />2)为避免重复计算,只包含子任务,不包括父任务
<br />3)包括已删除的任务、需求、Bug、用例、版本、测试单、问题、风险、文档、评审的耗时
<br />4)包括已删除执行中任务、需求、Bug、用例、版本、测试单、文档的耗时
<br />5)包括取消的任务、问题、风险的耗时
<h2>SV(%)进度偏差率</h2>
计算方式:SV(%) = -1 * (1 - (EV / PV))%
<h2>CV(%) 成本偏差率</h2>
计算方式:CV(%) = -1 * (1 - (EV / AC))%
EOD;
$lang->weekly->blockHelpNotice = <<<EOD
<h2>本周进度</h2>
计算方式:
<br />1)本周进度=总消耗工时/(总消耗工时+剩余工时)
<p>统计范围:</p>
1)总消耗的工时包括任务、需求、Bug、用例、版本、测试单、问题、风险、文档、评审的耗时
<br />2)为避免重复计算,任务只包含子任务,不包括父任务
<br />3)包括已删除任务、需求、Bug、用例、版本、测试单、问题、风险、文档、评审中已消耗的工时
<br />4)包括已删除执行中任务、需求、Bug、用例、版本、测试单、文档已消耗的工时
<br />5)包括已取消任务、问题、风险已消耗的工时
<br />6)不包括已取消任务的剩余工时
<br />7)不包括已删除执行中任务的剩余工时
<h2>PV 计划完成的工作</h2>
计算方式:
<br />1)任务预计开始日期、截止日期在本周起止日期范围内,累加预计工时
<br />2)任务预计开始日期、截止日期在本周起止日期之前,累加预计工时
<br />3)任务预计开始日期小于本周开始日期,截止日期大于本周开始日期,小于本周结束日期,累加预计工时
<br />4)任务预计开始日期大于本周开始日期,小于本周截止日期,截止日期大于本周结束日期,累加 (任务的预计工时÷任务工期天数)× 任务预计开始到本周结束日期的天数
<br />5)任务预计开始日期等于本周开始日期,截止日期大于本周结束日期,累加 (任务的预计工时÷任务工期天数)× 任务预计开始到本周结束日期的天数
<br />6)任务预计开始日期小于本周开始日期,截止日期等于本周结束日期,累加预计工时
<br />7)任务预计开始日期小于本周开始日期,截止日期大于本周结束日期,累加 (任务的预计工时÷任务工期天数)× 任务预计开始到本周结束日期的天数
<p>统计范围:</p>
1)本周开始日期:周一 00:00:00 本周结束日期:根据工作日和节假日的计算来确定
<br />2)为避免重复计算,只包含子任务,不包括父任务
<br />3)不包括已删除的任务
<br />4)不包括已取消的任务
<br />5)不包括已删除执行中的任务
<br />6)任务未填写预计开始日期,预计开始日期默认取任务所属阶段的计划开始日期
<br />7)任务未填写预计截止日期,预计截止日期默认取任务所属阶段的计划完成日期
<br />8)计算公式只计算工作日
<h2>EV实际完成的工作</h2>
计算方式:
<br />1)任务状态为已完成,累加预计工时
<br />2)任务状态为已关闭且关闭原因为已完成,累加预计工时
<br />3)任务状态为进行中、已暂停,累加 预计工时×完成进度
<p>统计范围:</p>
1)本周结束日期之前消耗工时不为0的任务
<br />2)为避免重复计算,只包含子任务,不包括父任务
<br />3)不包括已删除的任务
<br />4)不包括已取消的任务
<br />5)不包括已删除执行中的任务
<br />6)完成进度=已消耗工时÷(已消耗工时+剩余工时)
<h2>AC 实际花费(消耗)的成本</h2>
计算方式:
<br />1)累加本周结束日期之前所有消耗的工时
<p>统计范围:</p>
1)所有消耗的工时包括任务、需求、Bug、用例、版本、测试单、问题、风险、文档、评审的耗时
<br />2)为避免重复计算,只包含子任务,不包括父任务
<br />3)包括已删除的任务、需求、Bug、用例、版本、测试单、问题、风险、文档、评审的耗时
<br />4)包括已删除执行中任务、需求、Bug、用例、版本、测试单、文档的耗时
<br />5)包括取消的任务、问题、风险的耗时
<br />
<h2>SV(%)进度偏差率</h2>
计算方式:SV(%) = -1 * (1 - (EV / PV))%
<h2>CV(%) 成本偏差率</h2>
计算方式:CV(%) = -1 * (1 - (EV / AC))%
EOD;
+62 -47
View File
@@ -116,13 +116,9 @@ class weeklyModel extends model
public function save($project, $date)
{
$weekStart = $this->getThisMonday($date);
$this->dao->delete()->from(TABLE_WEEKLYREPORT)
->where('project')->eq($project)
->andWhere('weekStart')->eq($weekStart)
->exec();
$report = new stdclass();
$PVEV = $this->getPVEV($project, $date);
$report = new stdclass;
$PVEV = $this->getPVEV($project, $date);
$report->pv = $PVEV['PV'];
$report->ev = $PVEV['EV'];
$report->ac = $this->getAC($project, $date);
@@ -385,61 +381,49 @@ class weeklyModel extends model
if(!empty($report)) return array('PV' => $report->pv, 'EV' => $report->ev);
if(!$date) $date = date('Y-m-d');
$monday = $this->getThisMonday($date);
$sunday = $this->getThisSunday($date);
$lastDay = $this->getLastDay($date);
$nextMonday = date('Y-m-d', strtotime($sunday) + 24 * 3600);
$workdays = $this->loadModel('holiday')->getActualWorkingDays($monday, $sunday);
$executions = $this->dao->select('id,begin,end,realEnd,status')->from(TABLE_EXECUTION)->where('deleted')->eq(0)->andWhere('vision')->eq($this->config->vision)->andWhere('project')->eq($projectID)->fetchAll('id');
$lastDay = $this->getLastDay($date);
$monday = $this->getThisMonday($date);
if(empty($lastDay)) $lastDay = $monday;
$tasks = $this->dao->select('*')->from(TABLE_TASK)
$executions = $this->dao->select('id,begin,end,realBegan,realEnd,status')->from(TABLE_EXECUTION)->where('deleted')->eq(0)->andWhere('vision')->eq($this->config->vision)->andWhere('project')->eq($projectID)->fetchAll('id');
$stmt = $this->dao->select('*')->from(TABLE_TASK)
->where('execution')->in(array_keys($executions))
->andWhere("parent")->ge(0)
->andWhere("deleted")->eq(0)
->andWhere("((estStarted >= '$monday' AND estStarted < '$nextMonday') OR (deadline >= '$monday' AND deadline < '$nextMonday') OR (estStarted < '$monday' AND deadline > '$nextMonday'))")
->fetchAll('id');
->andWhere("status")->ne('cancel')
->query();
$PV = 0;
$EV = 0;
$this->loadModel('holiday');
foreach($tasks as $task)
while($task = $stmt->fetch())
{
if(empty($task->execution)) continue;
$execution = $executions[$task->execution];
if(helper::isZeroDate($task->estStarted)) $task->estStarted = helper::isZeroDate($task->openedDate) ? $execution->begin : date('Y-m-d', strtotime($task->openedDate));
if(helper::isZeroDate($task->deadline))
{
$task->deadline = helper::isZeroDate($execution->realEnd) ? $execution->end : $execution->realEnd;
if(!helper::isZeroDate($task->finishedDate)) $task->deadline = date('Y-m-d', strtotime($task->finishedDate));
}
if(helper::isZeroDate($task->estStarted)) $task->estStarted = $execution->begin;
if(helper::isZeroDate($task->deadline)) $task->deadline = $execution->end;
$fullDays = $this->holiday->getActualWorkingDays($task->estStarted, $task->deadline);
if($task->estStarted < $monday and $task->deadline >= $nextMonday)
if($task->deadline <= $lastDay)
{
$weekActualDays = $workdays;
$PV += $task->estimate;
}
elseif($task->estStarted >= $monday and $task->estStarted < $nextMonday)
elseif($task->estStarted <= $lastDay)
{
$weekActualDays = $this->holiday->getActualWorkingDays($task->estStarted, $task->deadline >= $nextMonday ? $sunday : $task->deadline);
$fullDays = $this->holiday->getActualWorkingDays($task->estStarted, $task->deadline);
$weekActualDays = $this->holiday->getActualWorkingDays($task->estStarted, $lastDay);
if(!empty($fullDays) and !empty($weekActualDays)) $PV += round(count($weekActualDays) / count($fullDays) * $task->estimate, 2);
}
elseif($task->deadline >= $monday and $task->deadline < $nextMonday)
{
$weekActualDays = $this->holiday->getActualWorkingDays($monday, $task->deadline);
}
if(empty($fullDays) or empty($weekActualDays) or empty($task->estimate)) continue;
$thisPV = round(count($weekActualDays) / count($fullDays) * $task->estimate, 2);
if($task->status == 'done' or $task->closedReason == 'done')
{
$EV += $thisPV;
$EV += $task->estimate;
}
else
{
$task->progress = 0;
if(($task->consumed + $task->left) > 0) $task->progress = round($task->consumed / ($task->consumed + $task->left) * 100, 2);
$EV += round($thisPV * $task->progress / 100, 2);
$EV += round($task->estimate * $task->progress / 100, 2);
}
$PV += $thisPV;
}
return array('PV' => sprintf("%.2f", $PV), 'EV' => sprintf("%.2f", $EV));
@@ -459,19 +443,14 @@ class weeklyModel extends model
if(!empty($report)) return $report->ac;
if(!$date) $date = date('Y-m-d');
$monday = $this->getThisMonday($date);
$nextMonday = date('Y-m-d', strtotime($monday) + (7 * 24 * 3600));
$executions = $this->dao->select('id,begin,end,realEnd,status')->from(TABLE_EXECUTION)->where('deleted')->eq(0)->andWhere('vision')->eq($this->config->vision)->andWhere('project')->eq($project)->fetchAll('id');
$taskIdList = $this->dao->select('id')->from(TABLE_TASK)->where('execution')->in(array_keys($executions))->andWhere("parent")->ge(0)->andWhere("deleted")->eq(0)->fetchPairs();
$lastDay = $this->getLastDay($date);
if(empty($lastDay)) $lastDay = $this->getThisMonday($date);
$AC = $this->dao->select('sum(consumed) as consumed')
->from(TABLE_EFFORT)
->where('objectType')->eq('task')
->andWhere('objectID')->in($taskIdList)
->andWhere('date')->ge($monday)
->andWhere('date')->lt($nextMonday)
->andWhere('deleted')->eq('0')
->where('project')->eq($project)
->andWhere('date')->le($lastDay)
->andWhere('deleted')->eq(0)
->fetch('consumed');
if(is_null($AC)) $AC = 0;
@@ -479,6 +458,42 @@ class weeklyModel extends model
return sprintf("%.2f", $AC);
}
/**
* Get left.
*
* @param int $projectID
* @param string $date
* @access public
* @return float
*/
public function getLeft($projectID, $date = '')
{
if(!$date) $date = date('Y-m-d');
$lastDay = $this->getLastDay($date);
$monday = $this->getThisMonday($date);
if(empty($lastDay)) $lastDay = $monday;
$executions = $this->dao->select('id,begin,end,realBegan,realEnd,status')->from(TABLE_EXECUTION)->where('deleted')->eq(0)->andWhere('vision')->eq($this->config->vision)->andWhere('project')->eq($projectID)->fetchAll('id');
$stmt = $this->dao->select('*')->from(TABLE_TASK)
->where('execution')->in(array_keys($executions))
->andWhere("parent")->ge(0)
->andWhere("deleted")->eq(0)
->andWhere("status")->ne('cancel')
->query();
$left = 0;
while($task = $stmt->fetch())
{
$execution = $executions[$task->execution];
if(helper::isZeroDate($task->estStarted)) $task->estStarted = $execution->begin;
if(helper::isZeroDate($task->deadline)) $task->deadline = $execution->end;
if($task->deadline <= $lastDay or ($task->estStarted <= $lastDay and $task->deadline > $lastDay)) $left += $task->left;
}
return sprintf("%.2f", $left);
}
/**
* Get SV data.
*
+10 -5
View File
@@ -13,10 +13,7 @@
<?php js::set('selectedWeekBegin', $date);?>
<?php if(common::hasPriv('weekly', 'exportweeklyreport')):?>
<script>
$(function()
{
$('#exportreport').modalTrigger();
});
$(function(){$('#exportreport').modalTrigger();});
</script>
<?php endif;?>
<div id="mainMenu" class="clearfix text-center">
@@ -39,7 +36,15 @@ $(function()
<div class='page-title'><h4><?php echo $lang->weekly->summary;?></h4></div>
<table class='table table-bordered'>
<tr>
<td><?php echo $lang->weekly->progress;?></td>
<td>
<?php echo $lang->weekly->progress;?>
<div id='helpDropdown' class="dropdown dropdown-hover">
<a data-toggle="dropdown"><i class="icon-help"></i></a>
<div class="dropdown-menu">
<?php echo $lang->weekly->reportHelpNotice;?>
</div>
</div>
</td>
<td></td>
<td><?php echo $lang->weekly->analysisResult;?></td>
<td></td>
+2 -1
View File
@@ -13,6 +13,7 @@
.fail{color:red;}
.dot-symbol{padding-right:10px;}
#statusContainer{margin:0px 0px 10px 0px;}
#checkServiceStatus{background-color:unset;}
#checkServiceStatus{background-color: #ffffff;}
#checkServiceStatus:hover{background-color: #f0fdfb;}
.service-check{margin-top: 0px;}
.checkStatus{color: #313c52;}
+5
View File
@@ -1,6 +1,7 @@
ajaxGetServiceStatus();
function ajaxGetServiceStatus()
{
$('#serviceContent').addClass('loading');
$.get(createLink('zahost', 'ajaxGetServiceStatus', 'hostID=' + hostID), function(response)
{
var resultData = JSON.parse(response);
@@ -31,6 +32,10 @@ function ajaxGetServiceStatus()
$('.result .init-fail').addClass('hide')
$('.result .init-success').removeClass('hide')
}
setTimeout(function() {
$('#serviceContent').removeClass('loading');
}, 500);
});
return
+1 -1
View File
@@ -102,7 +102,7 @@
<?php echo $lang->zahost->init->statusTitle;?>
<button type='button' id='checkServiceStatus' class='btn btn-info'><i class="icon icon-refresh"></i> <span class='checkStatus'><?php echo $lang->zahost->init->checkStatus;?></span></button>
</div>
<div class="detail-content article-content">
<div class="detail-content article-content load-indicator" id='serviceContent'>
<div class="main-row">
<div id="statusContainer">
<div class="text-kvm"><span class="dot-symbol fail"> ●</span><span>KVM</span></div>
+1 -1
View File
@@ -285,7 +285,7 @@ class zanode extends control
{
if($confirm == 'no')
{
return print(js::confirm($this->lang->zanode->confirmDelete, inlink('delete', "zanodeID={$nodeID}&confirm=yes")));
return print(js::confirm($this->lang->zanode->confirmDelete, inlink('destroy', "zanodeID={$nodeID}&confirm=yes")));
}
$error = $this->zanode->destroy($nodeID);
+3 -2
View File
@@ -12,6 +12,7 @@
.service-status{margin-top: 10px;}
.vnc-detail{height: 60vh;min-height: 550px;}
.vnc-mask{width: 100%;height:100%;background-color: rgba(0,0,0,0);position: absolute;z-index: 1;}
#checkServiceStatus{background-color:unset;}
#checkServiceStatus{background-color: #ffffff;}
#checkServiceStatus:hover{background-color: #f0fdfb;}
.checkStatus{color: #313c52;}
.node-not-wrap{white-space: nowrap;}
.node-not-wrap{white-space: nowrap;}
+12 -4
View File
@@ -2,6 +2,11 @@ var checkInterval;
var intervalTimes = 0;
$('#checkServiceStatus').click(function(){
$('#serviceContent').addClass('loading');
checkServiceStatus();
})
function checkServiceStatus(){
$.get(createLink('zanode', 'ajaxGetServiceStatus', 'nodeID=' + nodeID), function(response)
{
var resultData = JSON.parse(response);
@@ -91,9 +96,12 @@ $('#checkServiceStatus').click(function(){
$('.init-success').show();
// $('.init-fail').hide();
}
setTimeout(function() {
$('#serviceContent').removeClass('loading');
}, 500);
});
return
})
}
$('.node-init-install').on('click', function(){
$(this).addClass('load-indicator loading');
@@ -152,13 +160,13 @@ $('.btn-pwd-copy').live('click', function()
})
$(function(){
$('#checkServiceStatus').trigger("click")
checkServiceStatus();
checkInterval = setInterval(() => {
intervalTimes++;
if(intervalTimes > 300)
{
clearInterval(checkInterval)
}
$('#checkServiceStatus').trigger("click")
checkServiceStatus();
}, 2000);
})
})
+3 -4
View File
@@ -110,7 +110,7 @@ $account = strpos($zanode->osName, "windows") ? $config->zanode->defaultWinAccou
</div>
</div>
</div>
<?php
$canBeChanged = common::canBeChanged('zanode', $zanode);
if ($canBeChanged) $actionFormLink = $this->createLink('action', 'comment', "objectType=zanode&objectID=$zanode->id");
@@ -122,7 +122,7 @@ $account = strpos($zanode->osName, "windows") ? $config->zanode->defaultWinAccou
<?php echo $lang->zanode->init->statusTitle; ?>
<button type='button' id='checkServiceStatus' class='btn btn-info'><i class="icon icon-refresh"></i> <span class='checkStatus'><?php echo $lang->zanode->init->checkStatus;?></span></button>
</div>
<div class="detail-content statusContainer">
<div class="detail-content statusContainer load-indicator" id='serviceContent'>
<div class="service-status">
<span class='dot-symbol dot-zenagent text-danger'>●</span>
<span>&nbsp;&nbsp;ZenAgent &nbsp;
@@ -139,7 +139,6 @@ $account = strpos($zanode->osName, "windows") ? $config->zanode->defaultWinAccou
<div class="status-notice">
<span class='init-success hide'><?php echo sprintf($lang->zanode->init->initSuccessNoticeTitle, "<a href='https://www.zentao.net/book/zentaopms/configure-environment-974.html'>{$lang->zanode->manual}</a>", html::a(helper::createLink('testcase', 'automation', "", '', true), $lang->zanode->automation, '', "class='iframe' title='{$lang->zanode->automation}' data-width='50%'", '')); ?></span>
<span class='init-fail hide'><?php echo $lang->zanode->init->initFailNoticeTitle . '<br/>' . $lang->zanode->init->initFailNoticeDesc;?></span>
</div>
</div>
</div>
@@ -200,4 +199,4 @@ $account = strpos($zanode->osName, "windows") ? $config->zanode->defaultWinAccou
<div id='mainActions' class='main-actions'>
<?php common::printPreAndNext($browseLink); ?>
</div>
<?php include '../../common/view/footer.html.php'; ?>
<?php include '../../common/view/footer.html.php'; ?>
+128
View File
File diff suppressed because one or more lines are too long