Merge branch 'master' of https://gitlab.zcorp.cc/easycorp/zentaopms into cyy_28201
This commit is contained in:
@@ -575,7 +575,7 @@ class actionModel extends model
|
||||
if($history->field == 'git') $history->diff = str_replace('+', '%2B', $history->diff);
|
||||
}
|
||||
}
|
||||
elseif($actionName == 'linkstory' or $actionName == 'unlinkstory')
|
||||
elseif(strpos('linkstory,unlinkstory,createchildrenstory', $actionName) !== false)
|
||||
{
|
||||
$extra = '';
|
||||
foreach(explode(',', $action->extra) as $id) $extra .= common::hasPriv('story', 'view') ? html::a(helper::createLink('story', 'view', "storyID=$id"), "#$id ") . ', ' : "#$id, ";
|
||||
|
||||
@@ -67,7 +67,6 @@ class datatable extends control
|
||||
$this->app->loadConfig('testtask');
|
||||
$this->config->testcase->datatable->defaultField = $this->config->testtask->datatable->defaultField;
|
||||
$this->config->testcase->datatable->fieldList['actions']['width'] = '100';
|
||||
$this->config->testcase->datatable->fieldList['status']['title'] = $this->lang->testcase->executionStatus;
|
||||
$this->config->testcase->datatable->fieldList['status']['width'] = '90';
|
||||
}
|
||||
if($module == 'testcase')
|
||||
|
||||
@@ -2,14 +2,5 @@ $(function()
|
||||
{
|
||||
var heightType = $("[name='heightType']:checked").val();
|
||||
setCardCount(heightType);
|
||||
$('#colWidth, #minColWidth, #maxColWidth').attr('onkeyup', 'value=value.match(/^\\d+$/) ? value : ""');
|
||||
$('#colWidth, #minColWidth, #maxColWidth').attr('maxlength', '3');
|
||||
var fluidBoard = $("#mainContent input[name='fluidBoard'][checked='checked']").val() || 0;
|
||||
$('#colWidth').attr('disabled', fluidBoard == 1);
|
||||
$('#minColWidth, #maxColWidth').attr('disabled', fluidBoard == 0);
|
||||
$(document).on('change', "#mainContent input[name='fluidBoard']", function(e)
|
||||
{
|
||||
$('#colWidth').attr('disabled', e.target.value == 1);
|
||||
$('#minColWidth, #maxColWidth').attr('disabled', e.target.value == 0);
|
||||
})
|
||||
handleKanbanWidthAttr();
|
||||
});
|
||||
|
||||
@@ -1139,7 +1139,7 @@ class executionModel extends model
|
||||
->batchCheck($this->config->kanban->edit->requiredFields, 'notempty')
|
||||
->checkIF(!$execution->fluidBoard, 'colWidth', 'gt', 0)
|
||||
->batchCheckIF($execution->fluidBoard, 'minColWidth,maxColWidth', 'gt', 0)
|
||||
->checkIF($execution->minColWidth and $execution->maxColWidth and $execution->fluidBoard, 'maxColWidth', 'ge', $kanban->minColWidth)
|
||||
->checkIF($execution->minColWidth and $execution->maxColWidth and $execution->fluidBoard, 'maxColWidth', 'gt', $execution->minColWidth)
|
||||
->where('id')->eq((int)$executionID)
|
||||
->exec();
|
||||
}
|
||||
|
||||
@@ -23,15 +23,15 @@
|
||||
<tr>
|
||||
<th><?php echo $lang->kanban->columnWidth;?></th>
|
||||
<td colspan='2'>
|
||||
<div class="radio-col">
|
||||
<div class="width-radio-row">
|
||||
<?php echo html::radio('fluidBoard', array(0 => $lang->kanbancolumn->fluidBoardList['0']), "class='inline-block'", $execution->fluidBoard);?>
|
||||
<?php echo html::input('colWidth', !empty($execution->colWidth) ? $execution->colWidth : $this->config->colWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->colWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('colWidth', !empty($execution->colWidth) ? $execution->colWidth : $this->config->colWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->colWidth}' autocomplete='off'");?>px
|
||||
</div>
|
||||
<div class="radio-col mt10">
|
||||
<div class="width-radio-row mt10">
|
||||
<?php echo html::radio('fluidBoard', array(1 => $lang->kanbancolumn->fluidBoardList['1']), "class='inline-block'", $execution->fluidBoard);?>
|
||||
<?php echo html::input('minColWidth', !empty($execution->minColWidth) ? $execution->minColWidth: $this->config->minColWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->minColWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('minColWidth', !empty($execution->minColWidth) ? $execution->minColWidth: $this->config->minColWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->minColWidth}' autocomplete='off'");?>px
|
||||
<span class="input-divider">~</span>
|
||||
<?php echo html::input('maxColWidth', !empty($execution->maxColWidth) ? $execution->maxColWidth: $this->config->maxColWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->maxColWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('maxColWidth', !empty($execution->maxColWidth) ? $execution->maxColWidth: $this->config->maxColWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->maxColWidth}' autocomplete='off'");?>px
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@@ -49,14 +49,14 @@
|
||||
<thead>
|
||||
<tr>
|
||||
<th class='w-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
|
||||
<th class='c-pri' title=<?php echo $lang->execution->pri;?>> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
|
||||
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->testcase->title);?></th>
|
||||
<th class='c-type'> <?php common::printOrderLink('type', $orderBy, $vars, $lang->typeAB);?></th>
|
||||
<th class='c-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
|
||||
<th class='c-pri'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
|
||||
<th class='c-type'> <?php common::printOrderLink('type', $orderBy, $vars, $lang->testcase->type);?></th>
|
||||
<th class='c-status'><?php common::printOrderLink('status', $orderBy, $vars, $lang->statusAB);?></th>
|
||||
<th class='c-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->testcase->openedByAB);?></th>
|
||||
<th class='c-user'> <?php common::printOrderLink('lastRunner', $orderBy, $vars, $lang->testtask->lastRunAccount);?></th>
|
||||
<th class='c-date'> <?php common::printOrderLink('lastRunDate', $orderBy, $vars, $lang->testtask->lastRunTime);?></th>
|
||||
<th class='c-result'><?php common::printOrderLink('lastRunResult', $orderBy, $vars, $lang->testtask->lastRunResult);?></th>
|
||||
<th class='c-status'><?php common::printOrderLink('status', $orderBy, $vars, $lang->statusAB);?></th>
|
||||
<th class='c-actions-6 text-center'><?php echo $lang->actions;?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
@@ -70,15 +70,11 @@
|
||||
<td class="c-id">
|
||||
<?php echo sprintf('%03d', $case->id); ?>
|
||||
</td>
|
||||
<td><span class='label-pri <?php echo 'label-pri-' . $case->pri?>' title='<?php echo zget($lang->testcase->priList, $case->pri, $case->pri);?>'><?php echo zget($lang->testcase->priList, $case->pri, $case->pri)?></span></td>
|
||||
<?php $params = "testcaseID=$caseID&version=$case->version";?>
|
||||
<?php if($type == 'assigntome') $params .= "&from=testtask&taskID=$case->task";?>
|
||||
<td class='c-title text-left' title="<?php echo $case->title?>"><?php echo html::a($this->createLink('testcase', 'view', $params, '', '', $case->project), $case->title, null, "style='color: $case->color' data-app='{$this->app->tab}'");?></td>
|
||||
<td><span class='label-pri <?php echo 'label-pri-' . $case->pri?>' title='<?php echo zget($lang->testcase->priList, $case->pri, $case->pri);?>'><?php echo zget($lang->testcase->priList, $case->pri, $case->pri)?></span></td>
|
||||
<td><?php echo zget($lang->testcase->typeList, $case->type);?></td>
|
||||
<td><?php echo zget($users, $case->openedBy);?></td>
|
||||
<td><?php echo zget($users, $case->lastRunner);?></td>
|
||||
<td><?php if(!helper::isZeroDate($case->lastRunDate)) echo substr($case->lastRunDate, 5, 11);?></td>
|
||||
<td class='<?php echo $case->lastRunResult;?>'><?php if($case->lastRunResult) echo $lang->testcase->resultList[$case->lastRunResult];?></td>
|
||||
<td>
|
||||
<?php
|
||||
if($case->needconfirm)
|
||||
@@ -95,6 +91,10 @@
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
<td><?php echo zget($users, $case->openedBy);?></td>
|
||||
<td><?php echo zget($users, $case->lastRunner);?></td>
|
||||
<td><?php if(!helper::isZeroDate($case->lastRunDate)) echo substr($case->lastRunDate, 5, 11);?></td>
|
||||
<td class='<?php echo $case->lastRunResult;?>'><?php if($case->lastRunResult) echo $lang->testcase->resultList[$case->lastRunResult];?></td>
|
||||
<td class='c-actions'>
|
||||
<?php
|
||||
$case->browseType = $type;
|
||||
|
||||
@@ -49,16 +49,7 @@ $(function()
|
||||
{
|
||||
setCopyKanban($(this).data('id')); $('#copyKanbanModal').modal('hide');
|
||||
});
|
||||
$('#colWidth, #minColWidth, #maxColWidth').attr('onkeyup', 'value=value.match(/^\\d+$/) ? value : ""');
|
||||
$('#colWidth, #minColWidth, #maxColWidth').attr('maxlength', '3');
|
||||
var fluidBoard = $("#mainContent input[name='fluidBoard'][checked='checked']").val() || 0;
|
||||
$('#colWidth').attr('disabled', fluidBoard == 1);
|
||||
$('#minColWidth, #maxColWidth').attr('disabled', fluidBoard == 0);
|
||||
$(document).on('change', "#mainContent input[name='fluidBoard']", function(e)
|
||||
{
|
||||
$('#colWidth').attr('disabled', e.target.value == 1);
|
||||
$('#minColWidth, #maxColWidth').attr('disabled', e.target.value == 0);
|
||||
})
|
||||
handleKanbanWidthAttr();
|
||||
})
|
||||
|
||||
/**
|
||||
|
||||
@@ -39,16 +39,7 @@ $(function()
|
||||
return false;
|
||||
}
|
||||
})
|
||||
$('#colWidth, #minColWidth, #maxColWidth').attr('onkeyup', 'value=value.match(/^\\d+$/) ? value : ""');
|
||||
$('#colWidth, #minColWidth, #maxColWidth').attr('maxlength', '3');
|
||||
var fluidBoard = $("#mainContent input[name='fluidBoard'][checked='checked']").val() || 0;
|
||||
$('#colWidth').attr('disabled', fluidBoard == 1);
|
||||
$('#minColWidth, #maxColWidth').attr('disabled', fluidBoard == 0);
|
||||
$(document).on('change', "#mainContent input[name='fluidBoard']", function(e)
|
||||
{
|
||||
$('#colWidth').attr('disabled', e.target.value == 1);
|
||||
$('#minColWidth, #maxColWidth').attr('disabled', e.target.value == 0);
|
||||
})
|
||||
handleKanbanWidthAttr();
|
||||
})
|
||||
|
||||
/**
|
||||
|
||||
@@ -1446,7 +1446,6 @@ $(function()
|
||||
{
|
||||
initKanban($(this));
|
||||
});
|
||||
initRegionTabs();
|
||||
|
||||
if(navigator.userAgent.toLowerCase().indexOf("qqbrowser") > -1) $('.region .kanban-header-col > .actions').css('top', '30%');
|
||||
|
||||
@@ -1560,6 +1559,7 @@ $(function()
|
||||
|
||||
distance = 0;
|
||||
radiusWidth = 10;
|
||||
initRegionTabs();
|
||||
|
||||
$('.leftBtn').click(function()
|
||||
{
|
||||
|
||||
@@ -2239,7 +2239,7 @@ class kanbanModel extends model
|
||||
->batchCheck($this->config->kanban->create->requiredFields, 'notempty')
|
||||
->checkIF(!$kanban->fluidBoard, 'colWidth', 'gt', 0)
|
||||
->batchCheckIF($kanban->fluidBoard, 'minColWidth,maxColWidth', 'gt', 0)
|
||||
->checkIF($kanban->minColWidth and $kanban->maxColWidth and $kanban->fluidBoard, 'maxColWidth', 'ge', $kanban->minColWidth)
|
||||
->checkIF($kanban->minColWidth and $kanban->maxColWidth and $kanban->fluidBoard, 'maxColWidth', 'gt', $kanban->minColWidth)
|
||||
->check('name', 'unique', "space = {$kanban->space}")
|
||||
->exec();
|
||||
|
||||
@@ -2346,7 +2346,7 @@ class kanbanModel extends model
|
||||
->batchCheck($this->config->kanban->edit->requiredFields, 'notempty')
|
||||
->checkIF(!$kanban->fluidBoard, 'colWidth', 'gt', 0)
|
||||
->batchCheckIF($kanban->fluidBoard, 'minColWidth,maxColWidth', 'gt', 0)
|
||||
->checkIF($kanban->minColWidth and $kanban->maxColWidth and $kanban->fluidBoard, 'maxColWidth', 'ge', $kanban->minColWidth)
|
||||
->checkIF($kanban->minColWidth and $kanban->maxColWidth and $kanban->fluidBoard, 'maxColWidth', 'gt', $kanban->minColWidth)
|
||||
->where('id')->eq($kanbanID)
|
||||
->exec();
|
||||
|
||||
|
||||
@@ -67,15 +67,15 @@
|
||||
<tr>
|
||||
<th class='columnWidth'><?php echo $lang->kanban->columnWidth;?></th>
|
||||
<td colspan='2'>
|
||||
<div class="radio-col">
|
||||
<div class="width-radio-row">
|
||||
<?php echo html::radio('fluidBoard', array(0 => $lang->kanbancolumn->fluidBoardList['0']), isset($copyKanban->fluidBoard) ? $copyKanban->fluidBoard : 0);?>
|
||||
<?php echo html::input('colWidth', !empty($copyKanban->colWidth) ? $copyKanban->colWidth : $this->config->colWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->colWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('colWidth', !empty($copyKanban->colWidth) ? $copyKanban->colWidth : $this->config->colWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->colWidth}' autocomplete='off'");?>px
|
||||
</div>
|
||||
<div class="radio-col mt10">
|
||||
<div class="width-radio-row mt10">
|
||||
<?php echo html::radio('fluidBoard', array(1 => $lang->kanbancolumn->fluidBoardList['1']), isset($copyKanban->fluidBoard) ? $copyKanban->fluidBoard : 0);?>
|
||||
<?php echo html::input('minColWidth', !empty($copyKanban->minColWidth) ? $copyKanban->minColWidth: $this->config->minColWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->minColWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('minColWidth', !empty($copyKanban->minColWidth) ? $copyKanban->minColWidth: $this->config->minColWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->minColWidth}' autocomplete='off'");?>px
|
||||
<span class="input-divider">~</span>
|
||||
<?php echo html::input('maxColWidth', !empty($copyKanban->maxColWidth) ? $copyKanban->maxColWidth: $this->config->maxColWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->maxColWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('maxColWidth', !empty($copyKanban->maxColWidth) ? $copyKanban->maxColWidth: $this->config->maxColWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->maxColWidth}' autocomplete='off'");?>px
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@@ -28,15 +28,15 @@
|
||||
<tr>
|
||||
<th class='columnWidth'><?php echo $lang->kanban->columnWidth;?></th>
|
||||
<td colspan='2'>
|
||||
<div class="radio-col">
|
||||
<div class="width-radio-row">
|
||||
<?php echo html::radio('fluidBoard', array(0 => $lang->kanbancolumn->fluidBoardList['0']), $kanban->fluidBoard);?>
|
||||
<?php echo html::input('colWidth', !empty($kanban->colWidth) ? $kanban->colWidth : $this->config->colWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->colWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('colWidth', !empty($kanban->colWidth) ? $kanban->colWidth : $this->config->colWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->colWidth}' autocomplete='off'");?>px
|
||||
</div>
|
||||
<div class="radio-col mt10">
|
||||
<div class="width-radio-row mt10">
|
||||
<?php echo html::radio('fluidBoard', array(1 => $lang->kanbancolumn->fluidBoardList['1']), $kanban->fluidBoard);?>
|
||||
<?php echo html::input('minColWidth', !empty($kanban->minColWidth) ? $kanban->minColWidth : $this->config->minColWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->minColWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('minColWidth', !empty($kanban->minColWidth) ? $kanban->minColWidth : $this->config->minColWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->minColWidth}' autocomplete='off'");?>px
|
||||
<span class="input-divider">~</span>
|
||||
<?php echo html::input('maxColWidth', !empty($kanban->maxColWidth) ? $kanban->maxColWidth : $this->config->maxColWidth, "class='form-control inline-block setting-input' required placeholder='{$this->config->maxColWidth}' autocomplete='off'");?>px
|
||||
<?php echo html::input('maxColWidth', !empty($kanban->maxColWidth) ? $kanban->maxColWidth : $this->config->maxColWidth, "class='form-control inline-block setting-input' placeholder='{$this->config->maxColWidth}' autocomplete='off'");?>px
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@@ -55,17 +55,17 @@
|
||||
<?php endif;?>
|
||||
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
|
||||
</th>
|
||||
<th class='c-pri' title=<?php echo $lang->testcase->pri;?>> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
|
||||
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->testcase->title);?></th>
|
||||
<th class='c-pri'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
|
||||
<?php if($type == 'assigntome'):?>
|
||||
<th class='c-task'> <?php common::printOrderLink('task', $orderBy, $vars, $lang->testtask->common);?></th>
|
||||
<?php endif;?>
|
||||
<th class='c-type'> <?php common::printOrderLink('type', $orderBy, $vars, $lang->typeAB);?></th>
|
||||
<th class='c-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
|
||||
<th class='c-status'> <?php echo $lang->statusAB;?></th>
|
||||
<th class='c-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->testcase->openedByAB);?></th>
|
||||
<th class='c-user'> <?php common::printOrderLink('lastRunner', $orderBy, $vars, $lang->testtask->lastRunAccount);?></th>
|
||||
<th class='c-full-date'><?php common::printOrderLink('lastRunDate', $orderBy, $vars, $lang->testtask->lastRunTime);?></th>
|
||||
<th class='c-result'> <?php common::printOrderLink('lastRunResult', $orderBy, $vars, $lang->testtask->lastRunResult);?></th>
|
||||
<th class='c-status'> <?php echo $lang->statusAB;?></th>
|
||||
<th class='c-actions-5 text-center'> <?php echo $lang->actions;?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
@@ -86,19 +86,19 @@
|
||||
<?php endif;?>
|
||||
<?php echo sprintf('%03d', $case->id); ?>
|
||||
</td>
|
||||
<td><span class='label-pri <?php echo 'label-pri-' . $case->pri?>' title='<?php echo zget($lang->testcase->priList, $case->pri, $case->pri);?>'><?php echo zget($lang->testcase->priList, $case->pri, $case->pri)?></span></td>
|
||||
<?php $params = "testcaseID=$caseID&version=$case->version";?>
|
||||
<?php if($type == 'assigntome') $params .= "&from=testtask&taskID=$case->task";?>
|
||||
<td class='c-name'><?php echo html::a($this->createLink('testcase', 'view', $params), $case->title, null, "style='color: $case->color' title='{$case->title}'");?></td>
|
||||
<td><span class='label-pri <?php echo 'label-pri-' . $case->pri?>' title='<?php echo zget($lang->testcase->priList, $case->pri, $case->pri);?>'><?php echo zget($lang->testcase->priList, $case->pri, $case->pri)?></span></td>
|
||||
<?php if($type == 'assigntome'):?>
|
||||
<td class='c-name' title='<?php echo $case->taskName;?>'><?php echo $case->taskName;?></td>
|
||||
<?php endif;?>
|
||||
<td><?php echo zget($lang->testcase->typeList, $case->type);?></td>
|
||||
<td class='<?php if(isset($run)) echo $run->status;?>'><?php echo $this->processStatus('testcase', $case);?></td>
|
||||
<td><?php echo zget($users, $case->openedBy);?></td>
|
||||
<td><?php echo zget($users, $case->lastRunner);?></td>
|
||||
<td><?php echo helper::isZeroDate($case->lastRunDate) ? '' : substr($case->lastRunDate, 5, 11);?></td>
|
||||
<td class='<?php echo $case->lastRunResult;?>'><?php if($case->lastRunResult) echo $lang->testcase->resultList[$case->lastRunResult];?></td>
|
||||
<td class='<?php if(isset($run)) echo $run->status;?>'><?php echo $this->processStatus('testcase', $case);?></td>
|
||||
<td class='c-actions'>
|
||||
<?php
|
||||
if($canBeChanged)
|
||||
|
||||
@@ -31,3 +31,4 @@ ol, ul {padding-left: 20px;}
|
||||
#mainMenu .page-title {display: flex;}
|
||||
#mainMenu .btn-toolbar .page-title .label {top: 9px; margin-right: 10px; height: 16px;}
|
||||
#mainMenu .btn-toolbar .page-title .text {max-width: 434px; overflow: hidden; white-space:nowrap; margin-right: 6px;}
|
||||
#actionsBox a:last-of-type + .divider {display: none;}
|
||||
|
||||
@@ -44,6 +44,8 @@ function loadURL(url, type)
|
||||
|
||||
$(function()
|
||||
{
|
||||
$('#actionsBox a').first().prevAll('.divider').hide();
|
||||
|
||||
/* Recalculate the maximum width of the title. */
|
||||
var maxWidth = $('#mainMenu').width() - $('#actionsBox').width() - $('#mainMenu .btn-toolbar .page-title .label-info').width() - 177;
|
||||
$('#mainMenu .btn-toolbar .page-title .text').css('max-width', maxWidth.toString() + 'px');
|
||||
|
||||
@@ -122,14 +122,14 @@ class productplanModel extends model
|
||||
|
||||
foreach($planIdList as $planID)
|
||||
{
|
||||
$planProjects[$planID] = $this->dao->select('t1.*,t2.type')->from(TABLE_PROJECTPRODUCT)->alias('t1')
|
||||
$planProjects[$planID] = $this->dao->select('t1.project,t2.name')->from(TABLE_PROJECTPRODUCT)->alias('t1')
|
||||
->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project=t2.id')
|
||||
->where('t1.product')->eq($product)
|
||||
->andWhere('t2.deleted')->eq(0)
|
||||
->andWhere('t1.plan')->like(",$planID,")
|
||||
->andWhere('t2.type')->in('sprint,stage,kanban')
|
||||
->orderBy('project_desc')
|
||||
->fetch('project');
|
||||
->fetchAll('project');
|
||||
}
|
||||
|
||||
$storyCountInTable = $this->dao->select('plan,count(story) as count')->from(TABLE_PLANSTORY)->where('plan')->in($planIdList)->groupBy('plan')->fetchPairs('plan', 'count');
|
||||
@@ -159,12 +159,11 @@ class productplanModel extends model
|
||||
->andWhere('deleted')->eq(0)
|
||||
->fetchPairs('id', 'estimate');
|
||||
}
|
||||
$plan->stories = count($storyPairs);
|
||||
$plan->bugs = isset($bugs[$plan->id]) ? count($bugs[$plan->id]) : 0;
|
||||
$plan->hour = array_sum($storyPairs);
|
||||
$plan->project = zget($planProjects, $plan->id, '');
|
||||
$plan->projectID = $plan->project;
|
||||
$plan->expired = $plan->end < $date ? true : false;
|
||||
$plan->stories = count($storyPairs);
|
||||
$plan->bugs = isset($bugs[$plan->id]) ? count($bugs[$plan->id]) : 0;
|
||||
$plan->hour = array_sum($storyPairs);
|
||||
$plan->projects = zget($planProjects, $plan->id, '');
|
||||
$plan->expired = $plan->end < $date ? true : false;
|
||||
|
||||
/* Sync linked stories. */
|
||||
if(!isset($storyCountInTable[$plan->id]) or $storyCountInTable[$plan->id] != $plan->stories)
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
<th style="border-left: 1px solid #ddd;"><?php echo $lang->story->draft;?></th>
|
||||
<th><?php echo $lang->story->activate;?></th>
|
||||
<th><?php echo $lang->story->change;?></th>
|
||||
<th><?php echo $lang->story->review;?></th>
|
||||
<th><?php echo $lang->story->statusList['reviewing'];?></th>
|
||||
<th><?php echo $lang->story->completeRate;?></th>
|
||||
<th style="border-left: 1px solid #ddd;"><?php echo $lang->bug->activate;?></th>
|
||||
<th><?php echo $lang->bug->fixedRate;?></th>
|
||||
|
||||
+44
-45
@@ -79,7 +79,7 @@ $config->testcase->search['params']['lastEditedDate'] = array('operator' => '=',
|
||||
|
||||
global $app;
|
||||
$config->testcase->datatable = new stdclass();
|
||||
$config->testcase->datatable->defaultField = array('id', 'pri', 'title', 'type', 'openedBy', 'lastRunner', 'lastRunDate', 'lastRunResult', 'status', 'bugs', 'results', 'stepNumber', 'actions');
|
||||
$config->testcase->datatable->defaultField = array('id', 'title', 'pri', 'openedBy', 'lastRunner', 'lastRunDate', 'lastRunResult', 'actions');
|
||||
|
||||
$config->testcase->datatable->fieldList['id']['title'] = 'idAB';
|
||||
$config->testcase->datatable->fieldList['id']['fixed'] = 'left';
|
||||
@@ -94,12 +94,6 @@ $config->testcase->datatable->fieldList['module']['title'] = 'module';
|
||||
$config->testcase->datatable->fieldList['module']['control'] = 'select';
|
||||
$config->testcase->datatable->fieldList['module']['dataSource'] = array('module' => 'tree', 'method' => 'getOptionMenu', 'params' => '$productID&case');
|
||||
|
||||
$config->testcase->datatable->fieldList['pri']['title'] = 'priAB';
|
||||
$config->testcase->datatable->fieldList['pri']['fixed'] = 'left';
|
||||
$config->testcase->datatable->fieldList['pri']['width'] = '40';
|
||||
$config->testcase->datatable->fieldList['pri']['required'] = 'no';
|
||||
$config->testcase->datatable->fieldList['pri']['name'] = $lang->testcase->pri;
|
||||
|
||||
$config->testcase->datatable->fieldList['title']['title'] = 'title';
|
||||
$config->testcase->datatable->fieldList['title']['fixed'] = 'left';
|
||||
$config->testcase->datatable->fieldList['title']['width'] = 'auto';
|
||||
@@ -111,11 +105,44 @@ $config->testcase->datatable->fieldList['branch']['width'] = '100';
|
||||
$config->testcase->datatable->fieldList['branch']['required'] = 'no';
|
||||
$config->testcase->datatable->fieldList['branch']['dataSource'] = array('module' => 'port', 'method' => 'getRelatedObjects', 'params' => 'testcase&branch&id,name');
|
||||
|
||||
$config->testcase->datatable->fieldList['pri']['title'] = 'priAB';
|
||||
$config->testcase->datatable->fieldList['pri']['fixed'] = 'left';
|
||||
$config->testcase->datatable->fieldList['pri']['width'] = '40';
|
||||
$config->testcase->datatable->fieldList['pri']['required'] = 'no';
|
||||
$config->testcase->datatable->fieldList['pri']['name'] = $lang->testcase->pri;
|
||||
|
||||
$config->testcase->datatable->fieldList['type']['title'] = 'type';
|
||||
$config->testcase->datatable->fieldList['type']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['type']['width'] = '80';
|
||||
$config->testcase->datatable->fieldList['type']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['assignedTo']['title'] = 'assignedTo';
|
||||
$config->testcase->datatable->fieldList['assignedTo']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['assignedTo']['width'] = '90';
|
||||
$config->testcase->datatable->fieldList['assignedTo']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['status']['title'] = 'statusAB';
|
||||
if($app->rawMethod == 'cases')
|
||||
{
|
||||
$config->testcase->datatable->fieldList['status']['width'] = '90';
|
||||
}
|
||||
else
|
||||
{
|
||||
$config->testcase->datatable->fieldList['status']['width'] = '70';
|
||||
}
|
||||
$config->testcase->datatable->fieldList['status']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['status']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['openedBy']['title'] = 'openedByAB';
|
||||
$config->testcase->datatable->fieldList['openedBy']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['openedBy']['width'] = '80';
|
||||
$config->testcase->datatable->fieldList['openedBy']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['openedDate']['title'] = 'openedDate';
|
||||
$config->testcase->datatable->fieldList['openedDate']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['openedDate']['width'] = '90';
|
||||
$config->testcase->datatable->fieldList['openedDate']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['stage']['title'] = 'stage';
|
||||
$config->testcase->datatable->fieldList['stage']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['stage']['width'] = '110';
|
||||
@@ -132,20 +159,12 @@ $config->testcase->datatable->fieldList['keywords']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['keywords']['width'] = '100';
|
||||
$config->testcase->datatable->fieldList['keywords']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['assignedTo']['title'] = 'assignedTo';
|
||||
$config->testcase->datatable->fieldList['assignedTo']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['assignedTo']['width'] = '90';
|
||||
$config->testcase->datatable->fieldList['assignedTo']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['openedBy']['title'] = 'openedByAB';
|
||||
$config->testcase->datatable->fieldList['openedBy']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['openedBy']['width'] = '80';
|
||||
$config->testcase->datatable->fieldList['openedBy']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['openedDate']['title'] = 'openedDate';
|
||||
$config->testcase->datatable->fieldList['openedDate']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['openedDate']['width'] = '90';
|
||||
$config->testcase->datatable->fieldList['openedDate']['required'] = 'no';
|
||||
$config->testcase->datatable->fieldList['story']['title'] = 'story';
|
||||
$config->testcase->datatable->fieldList['story']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['story']['width'] = '90';
|
||||
$config->testcase->datatable->fieldList['story']['required'] = 'no';
|
||||
$config->testcase->datatable->fieldList['story']['control'] = 'select';
|
||||
$config->testcase->datatable->fieldList['story']['dataSource'] = array('module' => 'story', 'method' => 'getProductStoryPairs', 'params' => '$productID&$branch');
|
||||
|
||||
$config->testcase->datatable->fieldList['reviewedBy']['title'] = 'reviewedBy';
|
||||
$config->testcase->datatable->fieldList['reviewedBy']['fixed'] = 'no';
|
||||
@@ -162,28 +181,15 @@ $config->testcase->datatable->fieldList['lastRunner']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['lastRunner']['width'] = '70';
|
||||
$config->testcase->datatable->fieldList['lastRunner']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['lastRunDate']['title'] = 'lastRunDate';
|
||||
$config->testcase->datatable->fieldList['lastRunDate']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['lastRunDate']['width'] = '90';
|
||||
$config->testcase->datatable->fieldList['lastRunDate']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['lastRunResult']['title'] = 'lastRunResult';
|
||||
$config->testcase->datatable->fieldList['lastRunResult']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['lastRunResult']['width'] = '70';
|
||||
$config->testcase->datatable->fieldList['lastRunResult']['required'] = 'no';
|
||||
|
||||
if($app->rawMethod == 'cases')
|
||||
{
|
||||
$config->testcase->datatable->fieldList['status']['title'] = 'executionStatus';
|
||||
$config->testcase->datatable->fieldList['status']['width'] = '90';
|
||||
}
|
||||
else
|
||||
{
|
||||
$config->testcase->datatable->fieldList['status']['title'] = 'statusAB';
|
||||
$config->testcase->datatable->fieldList['status']['width'] = '70';
|
||||
}
|
||||
$config->testcase->datatable->fieldList['status']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['status']['required'] = 'no';
|
||||
$config->testcase->datatable->fieldList['lastRunDate']['title'] = 'lastRunDate';
|
||||
$config->testcase->datatable->fieldList['lastRunDate']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['lastRunDate']['width'] = '90';
|
||||
$config->testcase->datatable->fieldList['lastRunDate']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['lastEditedBy']['title'] = 'lastEditedBy';
|
||||
$config->testcase->datatable->fieldList['lastEditedBy']['fixed'] = 'no';
|
||||
@@ -200,13 +206,6 @@ $config->testcase->datatable->fieldList['version']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['version']['width'] = '60';
|
||||
$config->testcase->datatable->fieldList['version']['required'] = 'no';
|
||||
|
||||
$config->testcase->datatable->fieldList['story']['title'] = 'story';
|
||||
$config->testcase->datatable->fieldList['story']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['story']['width'] = '90';
|
||||
$config->testcase->datatable->fieldList['story']['required'] = 'no';
|
||||
$config->testcase->datatable->fieldList['story']['control'] = 'select';
|
||||
$config->testcase->datatable->fieldList['story']['dataSource'] = array('module' => 'story', 'method' => 'getProductStoryPairs', 'params' => '$productID&$branch');
|
||||
|
||||
$config->testcase->datatable->fieldList['bugs']['title'] = 'B';
|
||||
$config->testcase->datatable->fieldList['bugs']['fixed'] = 'no';
|
||||
$config->testcase->datatable->fieldList['bugs']['width'] = '32';
|
||||
|
||||
@@ -31,9 +31,11 @@ $lang->testcase->precondition = 'Voraussetzungen';
|
||||
$lang->testcase->pri = 'Priorität';
|
||||
$lang->testcase->type = 'Type';
|
||||
$lang->testcase->status = 'Status';
|
||||
$lang->testcase->statusAB = 'Status';
|
||||
$lang->testcase->subStatus = 'Sub Status';
|
||||
$lang->testcase->steps = 'Schritte';
|
||||
$lang->testcase->openedBy = 'Ersteller';
|
||||
$lang->testcase->openedByAB = 'Reporter';
|
||||
$lang->testcase->openedDate = 'Erstellt am';
|
||||
$lang->testcase->lastEditedBy = 'Bearbeitet von';
|
||||
$lang->testcase->result = 'Ergebnis';
|
||||
|
||||
@@ -31,9 +31,11 @@ $lang->testcase->precondition = 'Prerequisite';
|
||||
$lang->testcase->pri = 'Priority';
|
||||
$lang->testcase->type = 'Type';
|
||||
$lang->testcase->status = 'Status';
|
||||
$lang->testcase->statusAB = 'Status';
|
||||
$lang->testcase->subStatus = 'Sub Status';
|
||||
$lang->testcase->steps = 'Steps';
|
||||
$lang->testcase->openedBy = 'CreatedBy';
|
||||
$lang->testcase->openedByAB = 'Reporter';
|
||||
$lang->testcase->openedDate = 'CreatedDate';
|
||||
$lang->testcase->lastEditedBy = 'EditedBy';
|
||||
$lang->testcase->result = 'Result';
|
||||
|
||||
@@ -31,9 +31,11 @@ $lang->testcase->precondition = 'Prérequis';
|
||||
$lang->testcase->pri = 'Priorité';
|
||||
$lang->testcase->type = 'Type';
|
||||
$lang->testcase->status = 'Statut';
|
||||
$lang->testcase->statusAB = 'Statut';
|
||||
$lang->testcase->subStatus = 'Sous-statut';
|
||||
$lang->testcase->steps = 'Etape';
|
||||
$lang->testcase->openedBy = 'Créé par';
|
||||
$lang->testcase->openedByAB = 'Détecteur';
|
||||
$lang->testcase->openedDate = 'Créé le';
|
||||
$lang->testcase->lastEditedBy = 'Modifié par';
|
||||
$lang->testcase->result = 'Résultat';
|
||||
|
||||
@@ -31,9 +31,11 @@ $lang->testcase->precondition = '前置条件';
|
||||
$lang->testcase->pri = '优先级';
|
||||
$lang->testcase->type = '用例类型';
|
||||
$lang->testcase->status = '用例状态';
|
||||
$lang->testcase->statusAB = '状态';
|
||||
$lang->testcase->subStatus = '子状态';
|
||||
$lang->testcase->steps = '用例步骤';
|
||||
$lang->testcase->openedBy = '由谁创建';
|
||||
$lang->testcase->openedByAB = '创建者';
|
||||
$lang->testcase->openedDate = '创建日期';
|
||||
$lang->testcase->lastEditedBy = '最后修改者';
|
||||
$lang->testcase->result = '测试结果';
|
||||
|
||||
@@ -61,7 +61,6 @@ class testcaseModel extends model
|
||||
->setIF($this->config->systemMode == 'new' and $this->app->tab == 'project', 'project', $this->session->project)
|
||||
->setIF($this->app->tab == 'execution', 'execution', $this->session->execution)
|
||||
->setIF($this->post->story != false, 'storyVersion', $this->loadModel('story')->getVersion((int)$this->post->story))
|
||||
->stripTags($this->config->testcase->editor->create['id'], $this->config->allowedTags)
|
||||
->remove('steps,expects,files,labels,stepType,forceNotReview')
|
||||
->setDefault('story', 0)
|
||||
->cleanInt('story,product,branch,module')
|
||||
@@ -78,7 +77,6 @@ class testcaseModel extends model
|
||||
|
||||
/* Value of story may be showmore. */
|
||||
$case->story = (int)$case->story;
|
||||
$case = $this->loadModel('file')->processImgURL($case, $this->config->testcase->editor->create['id'], $this->post->uid);
|
||||
$this->dao->insert(TABLE_CASE)->data($case)->autoCheck()->batchCheck($this->config->testcase->create->requiredFields, 'notempty')->checkFlow()->exec();
|
||||
if(!$this->dao->isError())
|
||||
{
|
||||
|
||||
@@ -19,7 +19,7 @@ $config->testtask->editor->activate = array('id' => 'comment', 'tools' =
|
||||
$config->testtask->editor->importunitresult = array('id' => 'desc', 'tools' => 'simpleTools');
|
||||
|
||||
$config->testtask->datatable = new stdclass();
|
||||
$config->testtask->datatable->defaultField = array('id', 'pri', 'title', 'type', 'assignedTo', 'lastRunner', 'lastRunDate', 'lastRunResult', 'status', 'bugs', 'results', 'stepNumber','actions');
|
||||
$config->testtask->datatable->defaultField = array('id', 'title', 'pri', 'assignedTo', 'openedBy', 'lastRunner', 'lastRunDate', 'lastRunResult', 'actions');
|
||||
|
||||
$config->testtask->unitResultRules = new stdclass();
|
||||
$config->testtask->unitResultRules->common = array('path' => array('testsuite/testcase', 'testcase'), 'name' => array('classname', 'name'), 'failure' => 'failure', 'skipped' => 'skipped', 'suite' => 'name', 'aliasSuite' => array('classname'));
|
||||
|
||||
@@ -1329,3 +1329,39 @@ function refreshBudgetUnit(data)
|
||||
$('#future').prop('checked', false);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Handle radio logic of Kanban column width setting.
|
||||
*
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function handleKanbanWidthAttr ()
|
||||
{
|
||||
$('#colWidth, #minColWidth, #maxColWidth').attr('onkeyup', 'value=value.match(/^\\d+$/) ? value : ""');
|
||||
$('#colWidth, #minColWidth, #maxColWidth').attr('maxlength', '3');
|
||||
var fluidBoard = $("#mainContent input[name='fluidBoard'][checked='checked']").val() || 0;
|
||||
var addAttrEle = fluidBoard == 0 ? '#colWidth' : '#minColWidth, #maxColWidth';
|
||||
$(addAttrEle).closest('.width-radio-row').addClass('required');
|
||||
$('#colWidth').attr('disabled',fluidBoard == 1);
|
||||
$('#minColWidth, #maxColWidth').attr('disabled',fluidBoard == 0);
|
||||
$(document).on('change', "#mainContent input[name='fluidBoard']", function(e)
|
||||
{
|
||||
$('#colWidth').attr('disabled', e.target.value == 1);
|
||||
$('#minColWidth, #maxColWidth').attr('disabled', e.target.value == 0);
|
||||
if(e.target.value == 0 && $('#minColWidthLabel, #maxColWidthLabel'))
|
||||
{
|
||||
$('#colWidth').closest('.width-radio-row').addClass('required');
|
||||
$('#minColWidth, #maxColWidth').closest('.width-radio-row').removeClass('required');
|
||||
$('#minColWidthLabel, #maxColWidthLabel').remove();
|
||||
$('#minColWidth, #maxColWidth').removeClass('has-error');
|
||||
}
|
||||
else if(e.target.value == 1 && $('#colWidthLabel'))
|
||||
{
|
||||
$('#minColWidth, #maxColWidth').closest('.width-radio-row').addClass('required');
|
||||
$('#colWidth').closest('.width-radio-row').removeClass('required');
|
||||
$('#colWidthLabel').remove();
|
||||
$('#colWidth').removeClass('has-error');
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -122,7 +122,8 @@ body.xxc-embed.m-productplan-view,body.xxc-embed.m-bug-browse,body.xxc-embed.m-p
|
||||
.input-divider {margin: 0 4px;}
|
||||
.setting-input {width: 64px; height: 20px; margin: 0 4px; text-align: center;}
|
||||
.setting-input.disabled,.setting-input[disabled="disabled"] {color: #C4C4C4;}
|
||||
.radio-col {display: flex;}
|
||||
.width-radio-row {display: flex;}
|
||||
#dataform .width-radio-row.required:after {top: 1px; left: 360px;}
|
||||
.mt10 {margin-top: 10px;}
|
||||
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user