* Finish task #56396.
This commit is contained in:
@@ -691,6 +691,17 @@ function renderCount($count, count, column)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Alert to link product.
|
||||
*
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function tips()
|
||||
{
|
||||
bootbox.alert(linkProducts);
|
||||
}
|
||||
|
||||
/**
|
||||
* Render header of a column.
|
||||
*/
|
||||
@@ -725,10 +736,11 @@ function renderHeaderCol($column, column, $header, kanbanData)
|
||||
var printMoreBtn = (columnPrivs.includes('setColumn') || columnPrivs.includes('setWIP'));
|
||||
|
||||
/* Render more menu. */
|
||||
if(((column.type == 'backlog' && hasStoryButton) || (column.type == 'wait' && hasTaskButton) || (column.type == 'unconfirmed' && hasBugButton)) && $actions.children('.text-primary').length == 0)
|
||||
if(column.type == 'backlog' || (column.type == 'wait' && hasTaskButton) || column.type == 'unconfirmed' && $actions.children('.text-primary').length == 0)
|
||||
{
|
||||
var tips = (productID) ? '' : 'onclick="tips()"';
|
||||
$actions.append([
|
||||
'<a data-contextmenu="columnCreate" data-type="' + column.type + '" data-kanban="' + kanban.id + '" data-parent="' + (column.parentType || '') + '" class="text-primary">',
|
||||
'<a data-contextmenu="columnCreate" data-type="' + column.type + '" data-kanban="' + kanban.id + '" data-parent="' + (column.parentType || '') + '" class="text-primary"' + ((column.type !== 'wait') ? tips : '') + '>',
|
||||
'<i class="icon icon-expand-alt"></i>',
|
||||
'</a>'
|
||||
].join(''));
|
||||
|
||||
@@ -297,6 +297,17 @@ function renderColumnCount($count, count, col)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Alert to link product.
|
||||
*
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function tips()
|
||||
{
|
||||
bootbox.alert(linkProducts);
|
||||
}
|
||||
|
||||
/**
|
||||
* Render header column
|
||||
* @param {JQuery} $col Header column element
|
||||
@@ -315,10 +326,11 @@ function renderHeaderCol($col, col, $header, kanban)
|
||||
if(priv.canCreateTask || priv.canBatchCreateTask) printTaskButton = true;
|
||||
if(priv.canCreateBug || priv.canBatchCreateBug) printBugButton = true;
|
||||
|
||||
if((col.type === 'backlog' && printStoryButton) || (col.type === 'wait' && printTaskButton) || (col.type == 'unconfirmed' && printBugButton))
|
||||
if(col.type === 'backlog' || (col.type === 'wait' && printTaskButton) || col.type == 'unconfirmed')
|
||||
{
|
||||
var tips = (productID) ? '' : 'onclick="tips()"';
|
||||
$actions.append([
|
||||
'<a data-contextmenu="columnCreate" data-type="' + col.type + '" data-kanban="' + kanban.id + '" data-parent="' + (col.parentType || '') + '" class="text-primary">',
|
||||
'<a data-contextmenu="columnCreate" data-type="' + col.type + '" data-kanban="' + kanban.id + '" data-parent="' + (col.parentType || '') + '" class="text-primary"' + ((col.laneType !== 'task') ? tips : '') + '>',
|
||||
'<i class="icon icon-expand-alt"></i>',
|
||||
'</a>'
|
||||
].join(''));
|
||||
|
||||
@@ -271,6 +271,7 @@ $lang->execution->treeOnlyStory = 'Show Story Only';
|
||||
$lang->execution->storyKanban = 'Story Kanban';
|
||||
$lang->execution->storySort = 'Rank Story';
|
||||
$lang->execution->importPlanStory = $lang->executionCommon . ' is created!\nDo you want to import stories that have been linked to the plan?';
|
||||
$lang->execution->linkProducts = 'The execution has not been linked with any product, and the related functions cannot be used. Please link the product first and try again.';
|
||||
$lang->execution->iteration = 'Iterations';
|
||||
$lang->execution->iterationInfo = '%s Iterations';
|
||||
$lang->execution->viewAll = 'View All';
|
||||
|
||||
@@ -271,6 +271,7 @@ $lang->execution->treeOnlyStory = "树状图只看{$lang->SRCommon}";
|
||||
$lang->execution->storyKanban = "{$lang->SRCommon}看板";
|
||||
$lang->execution->storySort = "{$lang->SRCommon}排序";
|
||||
$lang->execution->importPlanStory = '创建' . $lang->executionCommon . '成功!\n是否导入计划关联的相关' . $lang->SRCommon . '?';
|
||||
$lang->execution->linkProducts = '该执行还未关联任何产品,相关功能无法使用,请先关联产品后再试。';
|
||||
$lang->execution->iteration = '版本迭代';
|
||||
$lang->execution->iterationInfo = '迭代%s次';
|
||||
$lang->execution->viewAll = '查看所有';
|
||||
|
||||
@@ -52,6 +52,7 @@ js::set('vision', $this->config->vision);
|
||||
js::set('productCount', count($productNames));
|
||||
js::set('executionID', $execution->id);
|
||||
js::set('reviewStoryParis', $reviewStoryParis);
|
||||
js::set('linkProducts', $lang->execution->linkProducts);
|
||||
|
||||
$canSortRegion = commonModel::hasPriv('kanban', 'sortRegion') && count($regions) > 1;
|
||||
$canEditRegion = commonModel::hasPriv('kanban', 'editRegion');
|
||||
|
||||
@@ -213,4 +213,5 @@ js::set('priv',
|
||||
<?php js::set('fluidBoard', $execution->fluidBoard);?>
|
||||
<?php js::set('displayCards', $execution->displayCards);?>
|
||||
<?php js::set('reviewStoryParis', $reviewStoryParis);?>
|
||||
<?php js::set('linkProducts', $lang->execution->linkProducts);?>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
Reference in New Issue
Block a user