diff --git a/module/action/lang/en.php b/module/action/lang/en.php
index a1539cb4e2..c6c7e56262 100755
--- a/module/action/lang/en.php
+++ b/module/action/lang/en.php
@@ -405,22 +405,37 @@ $lang->action->dynamicAction->execution['undeleted'] = 'Restore ' . $lang->execu
$lang->action->dynamicAction->execution['hidden'] = 'Hide ' . $lang->executionCommon;
$lang->action->dynamicAction->execution['moved'] = 'Improt Task';
-$lang->action->dynamicAction->kanban['create'] = 'Create Kanban';
-$lang->action->dynamicAction->kanban['edited'] = 'Kanban Settings';
+$lang->action->dynamicAction->kanban['created'] = 'Create Kanban';
+$lang->action->dynamicAction->kanban['edited'] = 'Kanban Settings';
+$lang->action->dynamicAction->kanban['closed'] = 'Close Kanban';
+$lang->action->dynamicAction->kanban['deleted'] = 'Delete Kanban';
-$lang->action->dynamicAction->kanbanspace['create'] = 'Create Space';
-$lang->action->dynamicAction->kanbanspace['edited'] = 'Space Settings';
-$lang->action->dynamicAction->kanbanspace['closed'] = 'Close Kanban';
+$lang->action->dynamicAction->kanbanspace['created'] = 'Create Space';
+$lang->action->dynamicAction->kanbanspace['edited'] = 'Space Settings';
+$lang->action->dynamicAction->kanbanspace['closed'] = 'Close Space';
+$lang->action->dynamicAction->kanbanspace['deleted'] = 'Deleted Space';
-$lang->action->dynamicAction->kanbancolumn['create'] = 'Create Column';
-$lang->action->dynamicAction->kanbancolumn['edited'] = 'Column Settings';
+$lang->action->dynamicAction->kanbanregion['created'] = 'Create Region';
+$lang->action->dynamicAction->kanbanregion['edited'] = 'Edit Region';
+$lang->action->dynamicAction->kanbanregion['deleted'] = 'Delete Region';
-$lang->action->dynamicAction->kanbanlane['created'] = 'Create Swimlane';
-$lang->action->dynamicAction->kanbanlane['edited'] = 'Swimlane Settings';
-$lang->action->dynamicAction->kanbanlane['moved'] = 'Move Swimlane';
+$lang->action->dynamicAction->kanbancolumn['created'] = 'Create Column';
+$lang->action->dynamicAction->kanbancolumn['edited'] = 'Column Settings';
+$lang->action->dynamicAction->kanbancolumn['archived'] = 'Archive Column';
+$lang->action->dynamicAction->kanbancolumn['restore'] = 'Restore Column';
+$lang->action->dynamicAction->kanbancolumn['deleted'] = 'Delete Column';
-$lang->action->dynamicAction->kanbancard['create'] = 'Create Card';
-$lang->action->dynamicAction->kanbancard['edited'] = 'Edit card';
+$lang->action->dynamicAction->kanbanlane['created'] = 'Create Lane';
+$lang->action->dynamicAction->kanbanlane['edited'] = 'Lane Settings';
+$lang->action->dynamicAction->kanbanlane['moved'] = 'Move Lane';
+$lang->action->dynamicAction->kanbanlane['deleted'] = 'Delete Lane';
+
+$lang->action->dynamicAction->kanbancard['created'] = 'Create Card';
+$lang->action->dynamicAction->kanbancard['edited'] = 'Edit Card';
+$lang->action->dynamicAction->kanbancard['commented'] = 'Comment Card';
+$lang->action->dynamicAction->kanbancard['archived'] = 'Archive Card';
+$lang->action->dynamicAction->kanbancard['restore'] = 'Restore Card';
+$lang->action->dynamicAction->kanbancard['deleted'] = 'Delete Card';
$lang->action->dynamicAction->team['managedTeam'] = 'Manage Team';
diff --git a/module/action/lang/zh-cn.php b/module/action/lang/zh-cn.php
index 172fba68d3..5f043c6650 100755
--- a/module/action/lang/zh-cn.php
+++ b/module/action/lang/zh-cn.php
@@ -405,22 +405,37 @@ $lang->action->dynamicAction->execution['undeleted'] = '还原' . $lang->executi
$lang->action->dynamicAction->execution['hidden'] = '隐藏' . $lang->executionCommon;
$lang->action->dynamicAction->execution['moved'] = '导入任务';
-$lang->action->dynamicAction->kanban['create'] = '创建看板';
-$lang->action->dynamicAction->kanban['edited'] = '设置看板';
+$lang->action->dynamicAction->kanban['created'] = '创建看板';
+$lang->action->dynamicAction->kanban['edited'] = '设置看板';
+$lang->action->dynamicAction->kanban['closed'] = '关闭看板';
+$lang->action->dynamicAction->kanban['deleted'] = '删除看板';
-$lang->action->dynamicAction->kanbanspace['create'] = '创建看板空间';
-$lang->action->dynamicAction->kanbanspace['edited'] = '设置看板空间';
-$lang->action->dynamicAction->kanbanspace['closed'] = '关闭看板空间';
+$lang->action->dynamicAction->kanbanspace['created'] = '创建看板空间';
+$lang->action->dynamicAction->kanbanspace['edited'] = '设置看板空间';
+$lang->action->dynamicAction->kanbanspace['closed'] = '关闭看板空间';
+$lang->action->dynamicAction->kanbanspace['deleted'] = '删除看板空间';
-$lang->action->dynamicAction->kanbancolumn['create'] = '创建看板列';
-$lang->action->dynamicAction->kanbancolumn['edited'] = '设置看板列';
+$lang->action->dynamicAction->kanbanregion['created'] = '创建看板区域';
+$lang->action->dynamicAction->kanbanregion['edited'] = '编辑看板区域';
+$lang->action->dynamicAction->kanbanregion['deleted'] = '删除看板区域';
-$lang->action->dynamicAction->kanbanlane['created'] = '创建泳道';
-$lang->action->dynamicAction->kanbanlane['edited'] = '设置泳道';
-$lang->action->dynamicAction->kanbanlane['moved'] = '移动泳道';
+$lang->action->dynamicAction->kanbancolumn['created'] = '创建看板列';
+$lang->action->dynamicAction->kanbancolumn['edited'] = '设置看板列';
+$lang->action->dynamicAction->kanbancolumn['archived'] = '归档看板列';
+$lang->action->dynamicAction->kanbancolumn['restore'] = '还原看板列';
+$lang->action->dynamicAction->kanbancolumn['deleted'] = '删除看板列';
-$lang->action->dynamicAction->kanbancard['create'] = '创建看板卡片';
-$lang->action->dynamicAction->kanbancard['edited'] = '编辑看板卡片';
+$lang->action->dynamicAction->kanbanlane['created'] = '创建泳道';
+$lang->action->dynamicAction->kanbanlane['edited'] = '设置泳道';
+$lang->action->dynamicAction->kanbanlane['moved'] = '移动泳道';
+$lang->action->dynamicAction->kanbanlane['deleted'] = '删除泳道';
+
+$lang->action->dynamicAction->kanbancard['created'] = '创建看板卡片';
+$lang->action->dynamicAction->kanbancard['edited'] = '编辑看板卡片';
+$lang->action->dynamicAction->kanbancard['commented'] = '备注看板卡片';
+$lang->action->dynamicAction->kanbancard['archived'] = '归档看板卡片';
+$lang->action->dynamicAction->kanbancard['restore'] = '还原看板卡片';
+$lang->action->dynamicAction->kanbancard['deleted'] = '删除看板卡片';
$lang->action->dynamicAction->team['managedTeam'] = '维护团队';
diff --git a/module/action/view/trash.html.php b/module/action/view/trash.html.php
index 8e359d54cb..772c24ff55 100755
--- a/module/action/view/trash.html.php
+++ b/module/action/view/trash.html.php
@@ -73,7 +73,7 @@
}
elseif($action->objectType == 'kanbancard')
{
- echo html::a($this->createLink('kanban', 'viewCard', "id=$action->objectID", '', true), $action->objectName, '', "title={$action->objectName} class='iframe'");
+ echo html::a($this->createLink('kanban', 'viewCard', "id=$action->objectID", '', true), $action->objectName, '', "title={$action->objectName} class='iframe' data-width=80%");
}
else
{
diff --git a/module/api/css/index.css b/module/api/css/index.css
index 228854c88d..2b3b4a18de 100644
--- a/module/api/css/index.css
+++ b/module/api/css/index.css
@@ -11,7 +11,7 @@
.main-col .doc-title {display: flex; font-size: 16px; margin-bottom: 15px;}
.main-col .doc-title .title {margin: 0; line-height: 30px; font-size: 25px;}
.main-col .doc-title .http-method {line-height: 27px; height: 27px; font-size: 13px; margin-right: 10px; padding: 0 10px;}
-.main-col .doc-title .path { line-height: 30px; font-size: 20px; margin-right: 15px;width:60%;word-wrap: break-word; }
+.main-col .doc-title .path {line-height: 30px; font-size: 20px; margin-right: 15px; word-wrap: break-word;}
.main-col .doc-title .info {flex: 1 1 0;}
.main-col .doc-title .version a {font-size: 13px; color: #8c8c8c;}
.main-col .doc-title .version .dropdown-menu a:hover {color: #ffffff;}
@@ -107,7 +107,7 @@
padding-right: 10px;
}
.detail .list-group-item {list-style: none; font-size: 14px; margin-bottom: 10px; line-height: 30px}
-.detail .list-group-item span {line-height: 30px; width: 50px;}
+.detail .list-group-item span {line-height: 30px; width: 65px;}
.detail .list-group-item .label+.label {margin-left: -4px;}
.detail .list-group-item .label {border-radius: 0;}
diff --git a/module/api/view/index.html.php b/module/api/view/index.html.php
index ba0656c6c2..e77975a522 100644
--- a/module/api/view/index.html.php
+++ b/module/api/view/index.html.php
@@ -81,7 +81,6 @@
lib}&moduleID=0&apiID={$api->id}&version=0&release=$release");?>">
method;?>
- status);?>
path;?>
title;?>
diff --git a/module/branch/control.php b/module/branch/control.php
index 0181b053e6..5c9b516a1d 100644
--- a/module/branch/control.php
+++ b/module/branch/control.php
@@ -325,4 +325,18 @@ class branch extends control
return $this->send(array('message' => $this->lang->saveSuccess, 'result' => 'success'));
}
+
+ /**
+ * AJAX: Get target branches for merge branch.
+ *
+ * @param int $productID
+ * @param string $mergedBranches
+ * @access public
+ * @return string
+ */
+ public function ajaxGetTargetBranches($productID, $mergedBranches = '')
+ {
+ $branchPairs = $this->branch->getPairs($productID, 'active', 0, $mergedBranches);
+ return print(html::select('targetBranch', $branchPairs, '', "class='form-control chosen'"));
+ }
}
diff --git a/module/branch/css/manage.css b/module/branch/css/manage.css
index a34994347c..edaa96f5ca 100644
--- a/module/branch/css/manage.css
+++ b/module/branch/css/manage.css
@@ -9,3 +9,4 @@ td.flex .label-primary {min-width: 40px;}
td.flex .setDefault {min-width: 120px;}
#mergeBranch .form-actions {padding-top: 20px;}
+.modal-body {padding-top: 0;}
diff --git a/module/branch/js/manage.js b/module/branch/js/manage.js
index 89e2faa12a..49f87ac8e8 100644
--- a/module/branch/js/manage.js
+++ b/module/branch/js/manage.js
@@ -65,8 +65,8 @@ $(function()
{
$('#targetBranch').attr('disabled', true).trigger('chosen:updated');
- var newBranchName = '
| ' + branchLang.name + " | |
|---|
";
- var newBranchDesc = '
| ' + branchLang.desc + " | |
|---|
";
+ var newBranchName = '
| ' + branchLang.name + " | |
|---|
";
+ var newBranchDesc = '
| ' + branchLang.desc + " | |
|---|
";
$(this).closest('tr').after(newBranchName + newBranchDesc);
}
else
@@ -78,35 +78,87 @@ $(function()
}
});
- $('#saveButton').on('click', function()
+ $("#merge").click(function()
{
var mergedBranchIDList = [];
+ var mergedBranchName = '';
+
$("input:checkbox[name^='branchIDList']:checked").each(function()
{
mergedBranchIDList.push($(this).val());
+ mergedBranchName += ',' + $(this).closest('tr').find('.branchName').attr('title');
+ });
+ mergedBranchName = mergedBranchName.substr(1);
+ mergedBranchIDList = mergedBranchIDList.join(',');
+
+ $.get(createLink('branch', 'ajaxGetTargetBranches', "productID=" + productID + "&mergedBranches=" + mergedBranchIDList), function(data)
+ {
+ $('#targetBranch').replaceWith(data);
+ $('#targetBranch_chosen').remove();
+ $('#targetBranch').chosen();
+
+ if($('#createBranch').prop('checked')) $('#targetBranch').attr('disabled', true).trigger('chosen:updated')
+ })
+ })
+
+ $('#saveButton').on('click', function()
+ {
+ var mergedBranchIDList = [];
+ var mergedBranchName = '';
+ var targetBranchName = $('#targetBranch_chosen').find('span').text();
+
+ $("input:checkbox[name^='branchIDList']:checked").each(function()
+ {
+ mergedBranchIDList.push($(this).val());
+ mergedBranchName += ',' + $(this).closest('tr').find('.branchName').attr('title');
});
+ mergedBranchName = mergedBranchName.substr(1);
+ targetBranchName = $('#createBranch').prop('checked') ? $('#name').val() : targetBranchName;
+
+ var confirmMergeMessage = branchLang.confirmMerge.replace(/(.*)mergedBranch(.*)targetBranch(.*)/, "$1" + mergedBranchName + "$2" + targetBranchName + "$3");
+
var isChecked = $('#createBranch').attr('checked') ? 1 : 0;
- var postData = {'name' : $('#name').val(), 'desc' : $('#desc').val(), 'createBranch' : isChecked, 'mergedBranchIDList' : mergedBranchIDList, 'targetBranch' : $('#targetBranch').val()};
- $.ajax(
+ if(isChecked && $('#name').val() == '')
{
- url: createLink('branch', 'mergeBranch', 'productID=' + productID),
- dataType: 'json',
- method: 'post',
- data: postData,
- success: function(data)
+ alert(branchLang.nameNotEmpty);
+ return false;
+ }
+
+ var branchNames = Object.values(branchPairs);
+ if(isChecked && branchNames.includes($('#name').val()) !== -1)
+ {
+ alert(branchLang.existName);
+ return false;
+ }
+
+ if(confirm(confirmMergeMessage))
+ {
+ var postData = {'name' : $('#name').val(), 'desc' : $('#desc').val(), 'createBranch' : isChecked, 'mergedBranchIDList' : mergedBranchIDList, 'targetBranch' : $('#targetBranch').val()};
+ $.ajax(
{
- if(data.result == 'fail')
+ url: createLink('branch', 'mergeBranch', 'productID=' + productID),
+ dataType: 'json',
+ method: 'post',
+ data: postData,
+ success: function(data)
{
- alert(data.message.name)
- return false;
+ if(data.result == 'fail')
+ {
+ alert(data.message.name)
+ return false;
+ }
+ else
+ {
+ $('#mergeBranch').modal('hide');
+ window.location.reload();
+ }
}
- else
- {
- $('#mergeBranch').modal('hide');
- window.location.reload();
- }
- }
- })
+ })
+ }
+ else
+ {
+ window.location.reload();
+ }
});
})
diff --git a/module/branch/lang/en.php b/module/branch/lang/en.php
index 45a74d62be..6f6292b986 100644
--- a/module/branch/lang/en.php
+++ b/module/branch/lang/en.php
@@ -22,7 +22,7 @@ $lang->branch->batchEdit = 'Batch Edit';
$lang->branch->defaultBranch = 'Default Branch';
$lang->branch->setDefault = 'Set Default';
$lang->branch->setDefaultAction = 'Set Default';
-$lang->branch->mergeTo = 'Merge branch to';
+$lang->branch->mergeTo = 'Merge to';
$lang->branch->mergeBranch = 'Merge branch';
$lang->branch->mergeBranchAction = 'Merge branch';
@@ -45,8 +45,10 @@ $lang->branch->nameNotEmpty = 'Name must not be empty!';
$lang->branch->confirmClose = 'Do you want to close this @branch@?';
$lang->branch->confirmActivate = 'Do you want to activate this @branch@?';
$lang->branch->existName = '@branch@ name already exists.';
-$lang->branch->mergeTips = '(Trunk does not support being merged. After the branch is merged, the corresponding releases, plans, modules, requirements, bugs, and cases under the branch will be merged into the new branch)';
-$lang->branch->targetBranchTips = 'Note: You can merge it into an existing branch, merge it into the trunk, or create a new branch.';
+$lang->branch->mergedMain = 'Trunk does not support being merged.';
+$lang->branch->mergeTips = 'After the branch is merged, the corresponding releases, plans, modules, requirements, bugs, and cases under the branch will be merged into the new branch';
+$lang->branch->targetBranchTips = 'You can merge it into an existing branch, merge it into the trunk, or create a new branch.';
+$lang->branch->confirmMerge = 'The data of "mergedBranch" will be merged into "targetBranch", please confirm whether you want to perform the branch merge operation, the data will not be restored after the merge!';
$lang->branch->noData = 'No branches.';
$lang->branch->mainBranch = 'The default main %s of the product.';
diff --git a/module/branch/lang/zh-cn.php b/module/branch/lang/zh-cn.php
index d839898ad8..4b8ea184ba 100644
--- a/module/branch/lang/zh-cn.php
+++ b/module/branch/lang/zh-cn.php
@@ -45,8 +45,10 @@ $lang->branch->nameNotEmpty = '名称不能为空!';
$lang->branch->confirmClose = '是否关闭该@branch@?';
$lang->branch->confirmActivate = '是否激活该@branch@?';
$lang->branch->existName = '@branch@名称已存在';
-$lang->branch->mergeTips = '(主干不支持被合并,合并@branch@后,会将@branch@下面对应的发布、计划、模块、需求、Bug、用例都合并到新的@branch@下)';
-$lang->branch->targetBranchTips = '注:您可以将其合并到已有的一个@branch@,也可以合并到主干,也可以新创建一个@branch@。';
+$lang->branch->mergedMain = '主干不支持被合并。';
+$lang->branch->mergeTips = '合并@branch@后,会将@branch@下面对应的发布、计划、模块、需求、Bug、用例都合并到新的@branch@下';
+$lang->branch->targetBranchTips = '您可以将其合并到已有的一个@branch@,也可以合并到主干,也可以新创建一个@branch@。';
+$lang->branch->confirmMerge = '"mergedBranch"的数据将被合并到"targetBranch",请确认是否要执行分支合并操作,合并后数据将不可再恢复!';
$lang->branch->noData = '暂时没有分支。';
$lang->branch->mainBranch = '产品默认主干%s。';
diff --git a/module/branch/model.php b/module/branch/model.php
index 4b1a59861d..a724be195a 100644
--- a/module/branch/model.php
+++ b/module/branch/model.php
@@ -96,10 +96,11 @@ class branchModel extends model
* @param int $productID
* @param string $params
* @param int $executionID
+ * @param string $mergedBranches
* @access public
* @return array
*/
- public function getPairs($productID, $params = '', $executionID = 0)
+ public function getPairs($productID, $params = '', $executionID = 0, $mergedBranches = '')
{
$executionBranches = array();
if($executionID)
@@ -116,6 +117,7 @@ class branchModel extends model
->beginIF($productID)->andWhere('product')->eq($productID)->fi()
->beginIF($productID and $executionID)->andWhere('id')->in(array_keys($executionBranches))->fi()
->beginIF(strpos($params, 'active') !== false)->andWhere('status')->eq('active')->fi()
+ ->beginIF(!empty($mergedBranches))->andWhere('id')->notIN($mergedBranches)->fi()
->orderBy('`order`')
->fetchPairs('id', 'name');
foreach($branches as $branchID => $branchName) $branches[$branchID] = htmlspecialchars_decode($branchName);
@@ -598,10 +600,10 @@ class branchModel extends model
/**
* Merge multiple branches into one branch.
*
- * @param int $productID
- * @param string $mergedBranches
+ * @param int $productID
+ * @param string $mergedBranches
* @access public
- * @return int
+ * @return int|bool
*/
public function mergeBranch($productID, $mergedBranches)
{
@@ -609,7 +611,6 @@ class branchModel extends model
/* Get the target branch. */
$targetBranch = $data->createBranch ? $this->create($productID, true) : $data->targetBranch;
- if(!$targetBranch and $targetBranch != BRANCH_MAIN) return false;
if($data->createBranch) $this->loadModel('action')->create('branch', $targetBranch, 'Opened');
/* Branch. */
diff --git a/module/branch/view/manage.html.php b/module/branch/view/manage.html.php
index f8cda10794..7c7af2328d 100644
--- a/module/branch/view/manage.html.php
+++ b/module/branch/view/manage.html.php
@@ -15,6 +15,7 @@
branch);?>
+
@@ -78,7 +79,7 @@
';?>
-
+ |
name;?>
default)
@@ -126,7 +127,7 @@
createLink('branch', 'batchEdit', "productID=$productID");
echo html::submitButton($lang->edit, "data-form-action='$batchEditLink'", 'btn');
- if($browseType != 'closed') echo html::a('#mergeBranch', $lang->branch->merge, '', "data-toggle='modal' class='btn'");
+ if(($browseType != 'closed' and common::hasPriv('branch', 'mergeBranch'))) echo html::a('#mergeBranch', $lang->branch->merge, '', "data-toggle='modal' class='btn' id='merge'");
?>
@@ -143,14 +144,22 @@
|
- systemMode == 'new'):?>
+ systemMode == 'new' and $this->app->tab == 'execution'):?>
projectName;?>
|
diff --git a/module/execution/view/task.html.php b/module/execution/view/task.html.php
index 81ad58febe..691157a5f7 100644
--- a/module/execution/view/task.html.php
+++ b/module/execution/view/task.html.php
@@ -289,7 +289,7 @@ body {margin-bottom: 25px;}
}
}?>
- task->printCell($field, $task, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table');?>
+ task->printCell($field, $task, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table', false, $showBranch);?>
children)):?>
@@ -306,7 +306,7 @@ body {margin-bottom: 25px;}
$this->task->printCell($field, $child, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table', true);
}?>
- task->printCell($field, $child, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table', true);?>
+ task->printCell($field, $child, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table', true, $showBranch);?>
diff --git a/module/group/lang/resource.php b/module/group/lang/resource.php
index 7d1bb57f52..7fb3631594 100644
--- a/module/group/lang/resource.php
+++ b/module/group/lang/resource.php
@@ -663,6 +663,7 @@ $lang->resource->kanban->laneMove = 'laneMove';
$lang->resource->kanban->cardsSort = 'cardsSort';
$lang->resource->kanban->viewArchivedColumn = 'viewArchivedColumn';
$lang->resource->kanban->viewArchivedCard = 'viewArchivedCard';
+$lang->resource->kanban->restoreCard = 'restoreCard';
$lang->kanban->methodOrder[5] = 'space';
$lang->kanban->methodOrder[10] = 'createSpace';
@@ -706,6 +707,7 @@ $lang->kanban->methodorder[190] = 'cardsSort';
$lang->kanban->methodOrder[195] = 'viewArchivedColumn';
$lang->kanban->methodorder[200] = 'viewArchivedCard';
$lang->kanban->methodorder[205] = 'archiveColumn';
+$lang->kanban->methodorder[210] = 'restoreCard';
/* Execution. */
$lang->resource->execution = new stdclass();
diff --git a/module/kanban/config.php b/module/kanban/config.php
index 3ead86b83f..8ce2018009 100644
--- a/module/kanban/config.php
+++ b/module/kanban/config.php
@@ -101,4 +101,4 @@ $config->kanban->taskColumnStatusList['closed'] = 'closed';
$config->kanban->laneColorList = array('#7ec5ff', '#333', '#2b529c', '#e48600', '#d2323d', '#229f24', '#777', '#d2691e', '#008b8b', '#2e8b57', '#4169e1', '#4b0082', '#fa8072', '#ba55d3', '#6b8e23');
$config->kanban->columnColorList = array('#333', '#2b519c', '#e48610', '#d2313d', '#2a9f23', '#777', '#d2691e', '#2e8b8b', '#2f8b58', '#4168e0', '#4b0082', '#f58072', '#ba55d3', '#6a8e22');
-$config->kanban->cardColorList = array('#fff', '#d2323d', '#f7b501', '#278427');
+$config->kanban->cardColorList = array('#fff', '#b10b0b', '#cfa227', '#2a5f29');
diff --git a/module/kanban/control.php b/module/kanban/control.php
index fa7adb720f..c8d12f8c39 100644
--- a/module/kanban/control.php
+++ b/module/kanban/control.php
@@ -797,7 +797,7 @@ class kanban extends control
{
$card = $this->kanban->getCardByID($cardID);
$column = $this->dao->select('*')->from(TABLE_KANBANCOLUMN)->where('id')->eq($card->column)->fetch();
- if($column->archived) die(js::alert(sprintf($this->lang->kanbancard->confirmRestoreTip, $column->name)));
+ if($column->archived or $column->deleted) die(js::alert(sprintf($this->lang->kanbancard->confirmRestoreTip, $column->name)));
die(js::confirm(sprintf($this->lang->kanbancard->confirmRestore, $column->name), $this->createLink('kanban', 'restoreCard', "cardID=$cardID&confirm=yes"), ''));
}
@@ -1069,15 +1069,18 @@ class kanban extends control
public function ajaxGetKanbanMenu($kanbanID, $moduleName, $methodName)
{
$kanbanIdList = $this->kanban->getCanViewObjects();
+ $spacePairs = $this->kanban->getSpacePairs('all');
+
$this->view->kanbanList = $this->dao->select('*')->from(TABLE_KANBAN)
->where('deleted')->eq('0')
->andWhere('id')->in($kanbanIdList)
+ ->andWhere('space')->in(array_keys($spacePairs))
->fetchGroup('space');
- $this->view->kanbanID = $kanbanID;
- $this->view->spaceList = $this->kanban->getSpacePairs('all');
- $this->view->module = $moduleName;
- $this->view->method = $methodName;
+ $this->view->kanbanID = $kanbanID;
+ $this->view->spaceList = $spacePairs;
+ $this->view->module = $moduleName;
+ $this->view->method = $methodName;
$this->display();
}
}
diff --git a/module/kanban/css/createcard.css b/module/kanban/css/createcard.css
index 31cde3e7c8..3ac8e1d763 100644
--- a/module/kanban/css/createcard.css
+++ b/module/kanban/css/createcard.css
@@ -1,2 +1,2 @@
-#nameBox .required:after {right: 130px; z-index: 2;}
-#nameBox .br-0 {height: 32px;}
+.pri-selector .br-0 {padding-bottom: 5px;}
+.required:after {left: 215px; z-index: 2;}
diff --git a/module/kanban/css/view.css b/module/kanban/css/view.css
index 4efc7af42c..2b288089cc 100644
--- a/module/kanban/css/view.css
+++ b/module/kanban/css/view.css
@@ -43,7 +43,7 @@
.region .kanban-lane {position: relative; border-bottom: none!important; min-height: 200px !important}
-.region .kanban-lane > .kanban-lane-name > .text {margin: auto 0; max-height: 100px;}
+.region .kanban-lane > .kanban-lane-name > .text {margin: auto 0; max-height: 150px; overflow: hidden; text-overflow: ellipsis}
.region .kanban-lane > .kanban-lane-name > .actions {position: absolute; top: 0; left: 0; right: 0; opacity: 0;}
.region .kanban-lane > .kanban-lane-name > .actions > a {display: block; width: 20px; height: 20px; line-height: 20px; text-align: center; opacity: .7; color: #fff;}
.region .kanban-lane > .kanban-lane-name > .actions > a:hover {background-color: rgba(0,0,0,.2); opacity: 1;}
@@ -60,8 +60,8 @@
.region .kanban-item > .kanban-card > .title:hover {color: #2272eb}
.region .kanban-item > .kanban-card > .info {margin-top: 5px; position: relative;}
.region .kanban-item > .kanban-card > .info > .pri {height: 14px; border-width: 1px; font-size: 12px; line-height: 12px; min-width: 14px; padding: 0 1px;}
-.region .kanban-item > .kanban-card > .info > .estimate{margin-left: 10px; color: #999; background-color: rgb(255, 255, 255); padding: 3px 0px}
-.region .kanban-item > .kanban-card > .info > .time {margin-left: 10px; font-size: 12px; background: rgb(242, 242, 242)}
+.region .kanban-item > .kanban-card > .info > .estimate{margin-left: 4px; color: #999; background-color: rgb(255, 255, 255); padding: 3px 0px}
+.region .kanban-item > .kanban-card > .info > .time {margin-left: 4px; font-size: 12px; background: rgb(242, 242, 242)}
.region .kanban-item > .kanban-card > .info > .user {position: absolute; right: 0; top: -2px}
.region .kanban-item > .kanban-card > .info > .user > .avatar {display: inline-block; width: 24px; height: 24px; line-height: 24px; margin-right: 0px; margin-left: 2px}
.region .kanban-item > .kanban-card > .info > .user > span {display: inline-block; color: transparent; width: 2px; height: 2px; background-color: #8990a2; position: sticky; border-radius: 50%; top: 3px; margin: 0 7px;}
diff --git a/module/kanban/js/view.js b/module/kanban/js/view.js
index 2783c48676..79fd9cdbc3 100644
--- a/module/kanban/js/view.js
+++ b/module/kanban/js/view.js
@@ -213,7 +213,7 @@ function renderUsersAvatar(users, itemID, size)
if(users.length == 0 || (users.length == 1 && users[0] == ''))
{
- return $('
');
+ return $('
');
}
var assignees = [];
@@ -309,15 +309,15 @@ function renderKanbanItem(item, $item)
var needRemind = (begin.toLocaleDateString() == today.toLocaleDateString() || end.toLocaleDateString() == today.toLocaleDateString());
if(item.end == '0000-00-00' && item.begin != '0000-00-00')
{
- $time.text($.zui.formatDate(begin, 'MM-dd') + ' ' + kanbancardLang.beginAB).attr('title', $.zui.formatDate(begin, 'yyyy-MM-dd') + ' ' +kanbancardLang.beginAB).show();
+ $time.text($.zui.formatDate(begin, 'MM/dd') + ' ' + kanbancardLang.beginAB).attr('title', $.zui.formatDate(begin, 'yyyy/MM/dd') + ' ' +kanbancardLang.beginAB).show();
}
else if(item.begin == '0000-00-00' && item.end != '0000-00-00')
{
- $time.text($.zui.formatDate(end, 'MM-dd') + ' ' + kanbancardLang.deadlineAB).attr('title', $.zui.formatDate(end, 'yyyy-MM-dd') + ' ' + kanbancardLang.deadlineAB).show();
+ $time.text($.zui.formatDate(end, 'MM/dd') + ' ' + kanbancardLang.deadlineAB).attr('title', $.zui.formatDate(end, 'yyyy/MM/dd') + ' ' + kanbancardLang.deadlineAB).show();
}
else if(item.begin != '0000-00-00' && item.end != '0000-00-00')
{
- $time.text($.zui.formatDate(begin, 'MM-dd') + ' ' + kanbancardLang.to + ' ' + $.zui.formatDate(end, 'MM-dd')).attr('title', $.zui.formatDate(begin, 'yyyy-MM-dd') + ' ' + kanbancardLang.to + ' ' + $.zui.formatDate(end, 'yyyy-MM-dd')).show();
+ $time.text($.zui.formatDate(begin, 'MM/dd') + ' ' + kanbancardLang.to + ' ' + $.zui.formatDate(end, 'MM/dd')).attr('title', $.zui.formatDate(begin, 'yyyy/MM/dd') + kanbancardLang.to + $.zui.formatDate(end, 'yyyy/MM/dd')).show();
}
if(!$item.hasClass('has-color') && needRemind) $time.css('background-color', 'rgba(210, 50, 61, 0.3)');
@@ -484,7 +484,7 @@ function openAddTaskForm($element)
*/
function resetLaneHeight()
{
- var maxHeight = '360px';
+ var maxHeight = '500px';
if(laneCount < 2)
{
var windowHeight = $(window).height();
@@ -697,8 +697,8 @@ function createCardMenu(options)
}
for(let i = moveColumns.length-1 ; i >= 0 ; i -- )
{
- if(moveColumns[i].id == card.column || $.inArray(moveColumns[i].id, parentColumns) >= 0) continue;
if(moveColumns[i].parent > 0) parentColumns.push(moveColumns[i].parent);
+ if(moveColumns[i].id == card.column || $.inArray(moveColumns[i].id, parentColumns) >= 0) continue;
moveCardItems.push({label: moveColumns[i].name, onClick: function(){moveCard(card.id, moveColumns[i].id, card.lane, card.kanban, card.region);}});
}
moveCardItems = moveCardItems.reverse();
diff --git a/module/kanban/lang/en.php b/module/kanban/lang/en.php
index 5b337dda8f..2738d33afb 100644
--- a/module/kanban/lang/en.php
+++ b/module/kanban/lang/en.php
@@ -50,6 +50,7 @@ $lang->kanban->viewArchivedColumn = 'View archived column';
$lang->kanban->archivedColumn = 'Archived Column';
$lang->kanban->archivedCard = 'Archived Card';
$lang->kanban->restoreColumn = 'Restore Column';
+$lang->kanban->restoreCard = 'Restore Card';
$lang->kanban->restore = 'Restore';
$lang->kanban->child = 'Child';
@@ -285,12 +286,13 @@ $lang->kanbancard->lblHour = 'h';
$lang->kanbancard->noAssigned = 'No Assigned';
$lang->kanbancard->deadlineAB = 'DL';
$lang->kanbancard->beginAB = 'Begin';
-$lang->kanbancard->to = 'to';
+$lang->kanbancard->to = '~';
+$lang->kanbancard->archived = 'Archived';
$lang->kanbancard->confirmArchive = 'Are you sure to archive this card? After archiving the card, it will be hidden from the column and you can view it in the Region - Archived.';
$lang->kanbancard->confirmDelete = 'Are you sure to delete this card? After deleting the card, it will be deleted from the Kanban. You can only view it in the system recycle bin.';
$lang->kanbancard->confirmRestore = 'Are you sure you want to restore this card? After the card is restored, the card will be restored to the "%s" Kanban column.';
-$lang->kanbancard->confirmRestoreTip = "The card's column has been archived, please restore '%s' column first.";
+$lang->kanbancard->confirmRestoreTip = "The card's column has been archived or deleted, please restore '%s' column first.";
$lang->kanbancard->priList[1] = 1;
$lang->kanbancard->priList[2] = 2;
@@ -298,9 +300,9 @@ $lang->kanbancard->priList[3] = 3;
$lang->kanbancard->priList[4] = 4;
$lang->kanbancard->colorList['#fff'] = 'Default';
-$lang->kanbancard->colorList['#d2323d'] = 'Blocking';
-$lang->kanbancard->colorList['#f7b501'] = 'Warning';
-$lang->kanbancard->colorList['#278427'] = 'Urgent';
+$lang->kanbancard->colorList['#b10b0b'] = 'Blocking';
+$lang->kanbancard->colorList['#cfa227'] = 'Warning';
+$lang->kanbancard->colorList['#2a5f29'] = 'Urgent';
$lang->kanbancard->error = new stdClass();
$lang->kanbancard->error->recordMinus = 'Estimate cannot be negative!';
diff --git a/module/kanban/lang/zh-cn.php b/module/kanban/lang/zh-cn.php
index 099189b0eb..e8e0b655e3 100644
--- a/module/kanban/lang/zh-cn.php
+++ b/module/kanban/lang/zh-cn.php
@@ -6,11 +6,11 @@ $lang->kanban->editSpace = '设置空间';
$lang->kanban->closeSpace = '关闭空间';
$lang->kanban->deleteSpace = '删除空间';
$lang->kanban->sortSpace = '空间排序';
-$lang->kanban->edit = '编辑看板';
+$lang->kanban->edit = '看板设置';
$lang->kanban->view = '查看看板';
$lang->kanban->close = '关闭看板';
$lang->kanban->delete = '删除看板';
-$lang->kanban->createRegion = '创建区域';
+$lang->kanban->createRegion = '新增区域';
$lang->kanban->editRegion = '编辑区域';
$lang->kanban->sortRegion = '区域排序';
$lang->kanban->sortGroup = '泳道组排序';
@@ -50,6 +50,7 @@ $lang->kanban->viewArchivedColumn = '查看已归档列';
$lang->kanban->archivedColumn = '已归档的看板列';
$lang->kanban->archivedCard = '已归档的卡片';
$lang->kanban->restoreColumn = '还原看板列';
+$lang->kanban->restoreCard = '还原卡片';
$lang->kanban->restore = '还原';
$lang->kanban->child = '子';
@@ -285,12 +286,13 @@ $lang->kanbancard->lblHour = 'h';
$lang->kanbancard->noAssigned = '未指派';
$lang->kanbancard->deadlineAB = '截止';
$lang->kanbancard->beginAB = '开始';
-$lang->kanbancard->to = '至';
+$lang->kanbancard->to = '~';
+$lang->kanbancard->archived = '已归档';
$lang->kanbancard->confirmArchive = '您确认归档该卡片吗?归档卡片后,该卡片将从列中隐藏,您可以在区域-已归档中查看。';
$lang->kanbancard->confirmDelete = '您确认删除该卡片吗?删除卡片后,该卡片将从看板中删除,您只能通过系统回收站查看。';
$lang->kanbancard->confirmRestore = '您确定要还原该卡片吗?还原卡片后,该卡片将还原到“%s”看板列中。';
-$lang->kanbancard->confirmRestoreTip = '该卡片所属的看板列已被归档,请先还原“%s”看板列。';
+$lang->kanbancard->confirmRestoreTip = '该卡片所属的看板列已被归档或删除,请先还原“%s”看板列。';
$lang->kanbancard->priList[1] = 1;
$lang->kanbancard->priList[2] = 2;
@@ -298,9 +300,9 @@ $lang->kanbancard->priList[3] = 3;
$lang->kanbancard->priList[4] = 4;
$lang->kanbancard->colorList['#fff'] = '默认';
-$lang->kanbancard->colorList['#d2323d'] = '阻塞';
-$lang->kanbancard->colorList['#f7b501'] = '警告';
-$lang->kanbancard->colorList['#278427'] = '加急';
+$lang->kanbancard->colorList['#b10b0b'] = '阻塞';
+$lang->kanbancard->colorList['#cfa227'] = '警告';
+$lang->kanbancard->colorList['#2a5f29'] = '加急';
$lang->kanbancard->error = new stdClass();
$lang->kanbancard->error->recordMinus = '预计不能为负数!';
diff --git a/module/kanban/model.php b/module/kanban/model.php
index 820ae7415c..b22360b1d2 100644
--- a/module/kanban/model.php
+++ b/module/kanban/model.php
@@ -594,7 +594,7 @@ class kanbanModel extends model
->orderBy('order')
->fetchGroup('group');
- $actions = array('createColumn', 'editColumn', 'splitColumn', 'setWIP', 'archiveColumn', 'restoreColumn', 'deleteColumn', 'createCard', 'splitColumn');
+ $actions = array('createColumn', 'editColumn', 'setWIP', 'archiveColumn', 'restoreColumn', 'deleteColumn', 'createCard', 'splitColumn');
/* Group by parent. */
$parentColumnGroup = array();
@@ -609,7 +609,7 @@ class kanbanModel extends model
if($this->isClickable($column, $action)) $column->actions[] = $action;
}
- if($column->parent and $column->parent != -1) continue;
+ if($column->parent > 0) continue;
$parentColumnGroup[$group][] = $column;
}
@@ -2136,7 +2136,6 @@ class kanbanModel extends model
$column = $this->dao->select('t1.*, t2.type as laneType')->from(TABLE_KANBANCOLUMN)->alias('t1')
->leftjoin(TABLE_KANBANLANE)->alias('t2')->on('t1.lane=t2.id')
->where('t1.id')->eq($columnID)
- ->andWhere('t1.deleted')->eq(0)
->fetch();
if($column->parent > 0) $column->parentName = $this->dao->findById($column->parent)->from(TABLE_KANBANCOLUMN)->fetch('name');
@@ -2164,7 +2163,7 @@ class kanbanModel extends model
/**
* Get columns by object id.
*
- * @param string $objectType
+ * @param string $objectType parent|region|group
* @param int $objectID
* @param string $archived
* @param string $deleted
@@ -2259,14 +2258,14 @@ class kanbanModel extends model
/**
* Get cards by object id.
*
- * @param string $objectType
+ * @param string $objectType kanban|region|group|lane|column
* @param int $objectID
* @param string $archived
* @param string $deleted
* @access public
* @return array
*/
- public function getCardsByObject($objectType = '', $objectID = 0, $archived = 0, $deleted = 0)
+ public function getCardsByObject($objectType = '', $objectID = 0, $archived = 0, $deleted = '0')
{
return $this->dao->select('*')->from(TABLE_KANBANCARD)
->where(true)
@@ -2380,46 +2379,45 @@ class kanbanModel extends model
->beginIF($action == 'sortlane')->andWhere('`group`')->eq($object->group)->fi()
->fetch('count');
return $count > 1;
- case 'createColumn' :
- case 'copyColumn' :
case 'splitcolumn' :
if($object->parent) return false; // The current column is a child column.
$count = $this->dao->select('COUNT(id) AS count')->from(TABLE_KANBANCOLUMN)
->where('parent')->eq($object->id)
->andWhere('deleted')->eq('0')
- //->andWhere('archived')->eq('0')
+ ->andWhere('archived')->eq('0')
->fetch('count');
return $count == 0; // The column has child columns.
- case 'restoreColumn' :
- if($object->parent)
+ case 'restorecolumn' :
+ if($object->parent > 0)
{
$parent = $this->getColumnByID($object->parent);
if($parent->deleted == '1' || $parent->archived == '1') return false;
}
return $object->archived == '1';
case 'archivecolumn' :
- //if($object->archived != '0') return false; // The column has been archived.
+ if($object->archived != '0') return false; // The column has been archived.
case 'deletecolumn' :
if($object->deleted != '0') return false;
- if($object->parent)
+ if($object->parent > 0)
{
$childrenCount = $this->dao->select('COUNT(id) AS count')->from(TABLE_KANBANCOLUMN)
->where('parent')->eq($object->parent)
->andWhere('deleted')->eq('0')
- //->andWhere('archived')->eq('0')
+ ->andWhere('archived')->eq('0')
->fetch('count');
return $childrenCount > 2;
}
+
$count = $this->dao->select('COUNT(id) AS count')->from(TABLE_KANBANCOLUMN)
->where('region')->eq($object->region)
- ->andWhere('parent')->eq(0)
+ ->andWhere('parent')->in('0,-1')
->andWhere('`group`')->eq($object->group)
->andWhere('deleted')->eq('0')
- //->andWhere('archived')->eq('0')
+ ->andWhere('archived')->eq('0')
->fetch('count');
return $count > 1;
diff --git a/module/kanban/view/ajaxgetkanbanmenu.html.php b/module/kanban/view/ajaxgetkanbanmenu.html.php
index e7d7e53615..7363e0fff1 100644
--- a/module/kanban/view/ajaxgetkanbanmenu.html.php
+++ b/module/kanban/view/ajaxgetkanbanmenu.html.php
@@ -93,7 +93,7 @@ foreach($kanbanList as $spaceID => $spaceKanbans)
}
elseif($kanban->status == 'closed')
{
- $closedKanbansHtml .= '
' . html::a(sprintf($link, $kanban->id), $kanbanName, '', "class='$selected kanbanName' title='$kanbanName' data-key='" . zget($kanbansPinYin, $kanban->name, '') . "'") . '';
+ $closedKanbansHtml .= '
' . html::a(sprintf($link, $kanban->id), $kanbanName, '', "class='$selected kanbanName' title='{$kanban->name}' data-key='" . zget($kanbansPinYin, $kanban->name, '') . "'") . '';
if($selected == 'selected') $tabActive = 'closed';
}
diff --git a/module/kanban/view/createcolumn.html.php b/module/kanban/view/createcolumn.html.php
index d7585e4be2..0cd31bb2a4 100644
--- a/module/kanban/view/createcolumn.html.php
+++ b/module/kanban/view/createcolumn.html.php
@@ -50,7 +50,6 @@
|
-
group);?>
parent > 0 ? $column->parent : 0);?>
diff --git a/module/kanban/view/space.html.php b/module/kanban/view/space.html.php
index e893e8a616..6fd397835a 100644
--- a/module/kanban/view/space.html.php
+++ b/module/kanban/view/space.html.php
@@ -89,7 +89,7 @@
if(common::hasPriv('kanban','delete'))
{
echo '';
- common::printLink('kanban', 'delete', "kanbanID={$kanban->id}", ' ' . $lang->kanban->delete, '', "class='iframe' data-width='75%'", '', true);
+ common::printLink('kanban', 'delete', "kanbanID={$kanban->id}", ' ' . $lang->kanban->delete, 'hiddenwin', '', '', true);
echo '';
}
?>
@@ -141,7 +141,7 @@
acl == 'open' ? 'unlock' : 'lock';?>
- kanban->aclGroup, $kanban->acl, '');?>
+ kanban->aclGroup, $kanban->acl == 'open' ? 'open' : 'private', '');?>
diff --git a/module/kanban/view/view.html.php b/module/kanban/view/view.html.php
index 9ade93870f..01a5ebb44b 100644
--- a/module/kanban/view/view.html.php
+++ b/module/kanban/view/view.html.php
@@ -51,7 +51,7 @@ $canCreateLane = commonModel::hasPriv('kanban', 'createLane');
name;?>
-
+
-
+
archived):?>
diff --git a/module/kanban/view/viewarchivedcard.html.php b/module/kanban/view/viewarchivedcard.html.php
index 2e7133dac4..9dbf290225 100644
--- a/module/kanban/view/viewarchivedcard.html.php
+++ b/module/kanban/view/viewarchivedcard.html.php
@@ -23,10 +23,20 @@
#archivedCards .card-actions {position: relative; padding: 15px 10px; padding-top: 0px;}
#archivedCards .card-actions > .btn {display: block;}
#archivedCards .card-actions > .btn + .btn {margin-top: 10px;}
+#archivedCards .info > .time {background-color: rgba(0, 0, 0, 0.15);}
#archivedCards .info > .users > span:before {left: -4px;}
#archivedCards .info > .users > span:after {right: -4px;}
#archivedCards .info > .users .avatar {display: inline-block; position: relative; border-radius: 50%; top: -5px; margin: 5px; right: -7px; margin-left: -4px;}
#archivedCards .cardName {word-wrap: break-word;}
+#archivedCards .card-item .red {background-color: #b10b0b;}
+#archivedCards .card-item .yellow {background-color: #cfa227;}
+#archivedCards .card-item .green {background-color: #2a5f29;}
+#archivedCards .card-item .has-color .cardName,
+#archivedCards .card-item .has-color .actions .icon-more-v,
+#archivedCards .card-item .has-color .info > .label-pri,
+#archivedCards .card-item .has-color .info > .estimate,
+#archivedCards .card-item .has-color .info > .label-light {color: #FFFFFF;}
+#archivedCards .card-item .has-color .info > .label-pri {border-color: #FFFFFF;}
@@ -37,7 +47,13 @@
-
+ color == '#b10b0b') $color = 'has-color red';
+ if($card->color == '#cfa227') $color = 'has-color yellow';
+ if($card->color == '#2a5f29') $color = 'has-color green';
+ ?>
+
createLink('kanban', 'viewCard', "cardID=$card->id", '', true), $card->name, '', "class='cardName iframe' data-toggle='modal' data-width='80%' title='$card->name'");?>
pri;?>
diff --git a/module/kanban/view/viewcard.html.php b/module/kanban/view/viewcard.html.php
index 3c401d32d2..35a3f42fbf 100644
--- a/module/kanban/view/viewcard.html.php
+++ b/module/kanban/view/viewcard.html.php
@@ -36,10 +36,13 @@
deleted):?>
id", " {$lang->kanbancard->assign}", '', "class='btn btn-link iframe' title='{$lang->kanbancard->assign}'", true, true);
- common::printLink('kanban', 'archiveCard', "cardID=$card->id", " {$lang->kanbancard->archive}", 'hiddenwin', "class='btn btn-link' title='{$lang->kanbancard->archive}'", true, true);
+ //common::printLink('kanban', 'assigntoCard', "cardID=$card->id", " {$lang->kanbancard->assign}", '', "class='btn btn-link iframe' title='{$lang->kanbancard->assign}'", true, true);
+ if(!$card->archived)
+ {
+ common::printLink('kanban', 'archiveCard', "cardID=$card->id", " {$lang->kanbancard->archive}", 'hiddenwin', "class='btn btn-link' title='{$lang->kanbancard->archive}'", true, true);
- echo " ";
+ echo " ";
+ }
common::printLink('kanban', 'editCard', "cardID=$card->id", ' ', '', "class='btn btn-link iframe' data-width='80%' title='{$lang->kanbancard->edit}'", true, true);
common::printLink('kanban', 'copyCard', "cardID=$card->id", ' ', '', "class='btn btn-link iframe' title='{$lang->kanbancard->copy}'", true, true);
diff --git a/module/product/control.php b/module/product/control.php
index f60cc1a0bd..ae6a2ff614 100644
--- a/module/product/control.php
+++ b/module/product/control.php
@@ -254,7 +254,7 @@ class product extends control
}
/* Process the sql, get the conditon partion, save it to session. */
- $this->loadModel('common')->saveQueryCondition($this->dao->get(), 'story', $browseType != 'bysearch' && $this->app->rawModule != 'projectstory');
+ $this->loadModel('common')->saveQueryCondition($this->dao->get(), 'story', ($browseType != 'bysearch' and $browseType != 'reviewbyme' and $this->app->rawModule != 'projectstory'));
if(!empty($stories)) $stories = $this->story->mergeReviewer($stories);
diff --git a/module/productplan/view/browse.html.php b/module/productplan/view/browse.html.php
index 675d5301f2..abbfb064b7 100644
--- a/module/productplan/view/browse.html.php
+++ b/module/productplan/view/browse.html.php
@@ -115,7 +115,7 @@
?>
|
session->currentProductType != 'normal'):?>
- parent != '-1') echo $branchOption[$plan->branch];?> |
+ parent != '-1') echo $branchOption[$plan->branch];?> |
begin == '2030-01-01' ? $lang->productplan->future : $plan->begin;?> |
end == '2030-01-01' ? $lang->productplan->future : $plan->end;?> |
diff --git a/module/story/control.php b/module/story/control.php
index a8a00808d7..aa00d7b601 100644
--- a/module/story/control.php
+++ b/module/story/control.php
@@ -489,7 +489,7 @@ class story extends control
}
$this->view->titles = $titles;
}
- $plans = $this->loadModel('productplan')->getPairsForStory($productID, $branch === 'all' or !in_array($branch, array_keys($branches)) ? 0 : $branch, 'skipParent|unexpired');
+ $plans = $this->loadModel('productplan')->getPairsForStory($productID, ($branch === 'all' or !in_array($branch, array_keys($branches))) ? 0 : $branch, 'skipParent|unexpired');
$plans['ditto'] = $this->lang->story->ditto;
$priList = (array)$this->lang->story->priList;