Conflicts:
	module/bug/lang/zh-cn.php
This commit is contained in:
daitingting
2018-04-27 11:00:34 +08:00
70 changed files with 1802 additions and 1689 deletions
+9
View File
@@ -25,6 +25,7 @@ $lang->action->undelete = 'Restore';
$lang->action->hideOne = 'Hide';
$lang->action->hideAll = 'Hide All';
$lang->action->editComment = 'Edit';
$lang->action->create = 'Create Comment';
$lang->action->comment = 'Comment';
$lang->action->trashTips = 'Note: All Deletion in ZenTao are logical.';
@@ -53,6 +54,14 @@ $lang->action->dynamic->all = 'All';
$lang->action->dynamic->hidden = 'Hidden';
$lang->action->dynamic->search = 'Search';
$lang->action->periods['all'] = $lang->action->dynamic->all;
$lang->action->periods['today'] = $lang->action->dynamic->today;
$lang->action->periods['yesterday'] = $lang->action->dynamic->yesterday;
$lang->action->periods['thisweek'] = $lang->action->dynamic->thisWeek;
$lang->action->periods['lastweek'] = $lang->action->dynamic->lastWeek;
$lang->action->periods['thismonth'] = $lang->action->dynamic->thisMonth;
$lang->action->periods['lastmonth'] = $lang->action->dynamic->lastMonth;
$lang->action->objectTypes['product'] = $lang->productCommon;
$lang->action->objectTypes['story'] = 'Story';
$lang->action->objectTypes['productplan'] = 'Plan';
+8
View File
@@ -54,6 +54,14 @@ $lang->action->dynamic->all = '所有';
$lang->action->dynamic->hidden = '已隐藏';
$lang->action->dynamic->search = '搜索';
$lang->action->periods['all'] = $lang->action->dynamic->all;
$lang->action->periods['today'] = $lang->action->dynamic->today;
$lang->action->periods['yesterday'] = $lang->action->dynamic->yesterday;
$lang->action->periods['thisweek'] = $lang->action->dynamic->thisWeek;
$lang->action->periods['lastweek'] = $lang->action->dynamic->lastWeek;
$lang->action->periods['thismonth'] = $lang->action->dynamic->thisMonth;
$lang->action->periods['lastmonth'] = $lang->action->dynamic->lastMonth;
$lang->action->objectTypes['product'] = $lang->productCommon;
$lang->action->objectTypes['story'] = '需求';
$lang->action->objectTypes['productplan'] = '计划';
-19
View File
@@ -967,25 +967,6 @@ class actionModel extends model
$this->file->updateObjectID($this->post->uid, $action->objectID, $action->objectType);
}
/**
* Get action count.
*
* @param string $type
* @param string $id
* @access public
* @return int
*/
public function getCount($type = 'account', $id = '')
{
if($type == 'account' and empty($id)) $id = $this->app->user->account;
return $this->dao->select('count(*) AS count')->from(TABLE_ACTION)
->where('1=1')
->beginIF($type == 'account')->andWhere('actor')->eq($id)->fi()
->beginIF($type == 'product')->andWhere('product')->like("%,$id,%")->fi()
->beginIF($type == 'project')->andWhere('project')->eq($id)->fi()
->fetch('count');
}
/**
* Build date group by actions
*
+26 -12
View File
@@ -83,21 +83,33 @@ $lang->block->default['product']['4']['params']['num'] = 15;
$lang->block->default['product']['4']['params']['orderBy'] = 'id_desc';
$lang->block->default['product']['4']['params']['type'] = 'assignedTo';
$lang->block->default['project']['1']['title'] = '進行中的' . $lang->projectCommon;
$lang->block->default['project']['1']['block'] = 'list';
$lang->block->default['project']['1']['title'] = $lang->projectCommon . '統計';
$lang->block->default['project']['1']['block'] = 'statistic';
$lang->block->default['project']['1']['grid'] = 8;
$lang->block->default['project']['1']['params']['num'] = 15;
$lang->block->default['project']['1']['params']['orderBy'] = 'id_desc';
$lang->block->default['project']['1']['params']['type'] = 'undone';
$lang->block->default['project']['1']['params']['type'] = 'noclosed';
$lang->block->default['project']['1']['params']['num'] = 5;
$lang->block->default['project']['2']['title'] = '指派給我的任務';
$lang->block->default['project']['2']['block'] = 'task';
$lang->block->default['project']['2']['title'] = $lang->projectCommon . '總覽';
$lang->block->default['project']['2']['block'] = 'overview';
$lang->block->default['project']['2']['grid'] = 4;
$lang->block->default['project']['2']['params']['num'] = 15;
$lang->block->default['project']['2']['params']['orderBy'] = 'id_desc';
$lang->block->default['project']['2']['params']['type'] = 'assignedTo';
$lang->block->default['project']['3']['title'] = '進行中的' . $lang->projectCommon;
$lang->block->default['project']['3']['block'] = 'list';
$lang->block->default['project']['3']['grid'] = 8;
$lang->block->default['project']['3']['params']['num'] = 15;
$lang->block->default['project']['3']['params']['orderBy'] = 'id_desc';
$lang->block->default['project']['3']['params']['type'] = 'undone';
$lang->block->default['project']['4']['title'] = '指派給我的任務';
$lang->block->default['project']['4']['block'] = 'task';
$lang->block->default['project']['4']['grid'] = 4;
$lang->block->default['project']['4']['params']['num'] = 15;
$lang->block->default['project']['4']['params']['orderBy'] = 'id_desc';
$lang->block->default['project']['4']['params']['type'] = 'assignedTo';
$lang->block->default['qa']['1']['title'] = '指派給我的Bug';
$lang->block->default['qa']['1']['block'] = 'bug';
@@ -232,9 +244,11 @@ $lang->block->modules['product']->availableBlocks->plan = '計劃列表';
$lang->block->modules['product']->availableBlocks->release = '發佈列表';
$lang->block->modules['project'] = new stdclass();
$lang->block->modules['project']->availableBlocks = new stdclass();
$lang->block->modules['project']->availableBlocks->list = $lang->projectCommon . '列表';
$lang->block->modules['project']->availableBlocks->task = '任務列表';
$lang->block->modules['project']->availableBlocks->build = '版本列表';
$lang->block->modules['project']->availableBlocks->statistic = $lang->projectCommon . '統計';
$lang->block->modules['project']->availableBlocks->overview = $lang->projectCommon . '總覽';
$lang->block->modules['project']->availableBlocks->list = $lang->projectCommon . '列表';
$lang->block->modules['project']->availableBlocks->task = '任務列表';
$lang->block->modules['project']->availableBlocks->build = '版本列表';
$lang->block->modules['qa'] = new stdclass();
$lang->block->modules['qa']->availableBlocks = new stdclass();
$lang->block->modules['qa']->availableBlocks->bug = 'Bug列表';
+9 -14
View File
@@ -100,6 +100,7 @@ $lang->bug->setPublic = 'Set as Public Template';
$lang->bug->deleteTemplate = 'Delete Template';
$lang->bug->confirmStoryChange = 'Confirm Story Change';
$lang->bug->copy = 'Copy';
$lang->bug->search = 'Search';
/* 查询条件列表。*/
$lang->bug->assignToMe = 'AssignedToMe';
@@ -128,13 +129,13 @@ $lang->bug->ditto = 'Ditto';
$lang->bug->dittoNotice = 'This bug is not linked to the same product as the last one!';
/* 页面标签。*/
$lang->bug->lblAssignedTo = 'Assignee';
$lang->bug->lblMailto = 'Mail To';
$lang->bug->lblLastEdited = 'Last Edited';
$lang->bug->lblResolved = 'Resolved By';
$lang->bug->allUsers = 'All User';
$lang->bug->allBuilds = 'All';
$lang->bug->createBuild = 'New';
$lang->bug->lblAssignedTo = 'Assignee';
$lang->bug->lblMailto = 'Mail To';
$lang->bug->lblLastEdited = 'Last Edited';
$lang->bug->lblResolved = 'Resolved By';
$lang->bug->allUsers = 'All User';
$lang->bug->allBuilds = 'All';
$lang->bug->createBuild = 'New';
/* legend列表。*/
$lang->bug->legendBasicInfo = 'Basic Info';
@@ -149,7 +150,7 @@ $lang->bug->legendMisc = 'Misc';
$lang->bug->legendRelated = 'Related Info';
/* 功能按钮。*/
$lang->bug->buttonConfirm = 'Confirm';
$lang->bug->buttonConfirm = 'Confirm';
/* 交互提示。*/
$lang->bug->confirmChangeProduct = "Change {$lang->productCommon} will cause linked {$lang->projectCommon},Story and Task change. Do you want to do this?";
@@ -233,10 +234,6 @@ $lang->bug->typeList['standard'] = 'Standard';
$lang->bug->typeList['automation'] = 'Testing Script';
$lang->bug->typeList['others'] = 'Other';
$lang->bug->statusList[''] = '';
$lang->bug->statusList['active'] = 'Active';
$lang->bug->statusList['resolved'] = 'Resolved';
@@ -376,8 +373,6 @@ $lang->bug->mySelects['resolvedbyme'] = $lang->bug->resolvedByMeAB;
$lang->bug->featureBar['browse']['unclosed'] = $lang->bug->unclosed;
$lang->bug->featureBar['browse']['all'] = $lang->bug->allBugs;
$lang->bug->featureBar['browse']['my'] = $lang->bug->my;
$lang->bug->featureBar['browse']['unconfirmed'] = $lang->bug->unconfirmed;
$lang->bug->featureBar['browse']['assigntonull'] = $lang->bug->assignToNull;
+10 -12
View File
@@ -100,6 +100,7 @@ $lang->bug->setPublic = '设为公共模板';
$lang->bug->deleteTemplate = '删除模板';
$lang->bug->confirmStoryChange = '确认需求变动';
$lang->bug->copy = '复制Bug';
$lang->bug->search = '搜索';
/* 查询条件列表。*/
$lang->bug->assignToMe = '指派给我';
@@ -118,6 +119,7 @@ $lang->bug->allBugs = '所有';
$lang->bug->byQuery = '搜索';
$lang->bug->needConfirm = '需求变动';
$lang->bug->allProduct = '所有' . $lang->productCommon;
$lang->bug->my = '我的';
$lang->bug->yesterdayResolved = '昨天解决';
$lang->bug->assignToMeAB = '指派给我';
@@ -128,13 +130,13 @@ $lang->bug->ditto = '同上';
$lang->bug->dittoNotice = '该bug与上一bug不属于同一产品!';
/* 页面标签。*/
$lang->bug->lblAssignedTo = '当前指派';
$lang->bug->lblMailto = '抄送给';
$lang->bug->lblLastEdited = '最后修改';
$lang->bug->lblResolved = '由谁解决';
$lang->bug->allUsers = '所有用户';
$lang->bug->allBuilds = '所有';
$lang->bug->createBuild = '新建';
$lang->bug->lblAssignedTo = '当前指派';
$lang->bug->lblMailto = '抄送给';
$lang->bug->lblLastEdited = '最后修改';
$lang->bug->lblResolved = '由谁解决';
$lang->bug->allUsers = '所有用户';
$lang->bug->allBuilds = '所有';
$lang->bug->createBuild = '新建';
/* legend列表。*/
$lang->bug->legendBasicInfo = '基本信息';
@@ -149,7 +151,7 @@ $lang->bug->legendMisc = '其他相关';
$lang->bug->legendRelated = '其他信息';
/* 功能按钮。*/
$lang->bug->buttonConfirm = '确认';
$lang->bug->buttonConfirm = '确认';
/* 交互提示。*/
$lang->bug->confirmChangeProduct = "修改{$lang->productCommon}会导致相应的{$lang->projectCommon}、需求和任务发生变化,确定吗?";
@@ -369,10 +371,6 @@ $lang->bug->placeholder = new stdclass();
$lang->bug->placeholder->chooseBuilds = '选择相关版本...';
$lang->bug->placeholder->newBuildName = '新版本名称';
$lang->bug->featureBar['browse']['unclosed'] = $lang->bug->unclosed;
$lang->bug->featureBar['browse']['all'] = $lang->bug->allBugs;
$lang->bug->featureBar['browse']['assigntome'] = $lang->bug->assignToMe;
+10 -13
View File
@@ -100,6 +100,7 @@ $lang->bug->setPublic = '設為公共模板';
$lang->bug->deleteTemplate = '刪除模板';
$lang->bug->confirmStoryChange = '確認需求變動';
$lang->bug->copy = '複製Bug';
$lang->bug->search = '搜索';
/* 查詢條件列表。*/
$lang->bug->assignToMe = '指派給我';
@@ -118,7 +119,7 @@ $lang->bug->allBugs = '所有';
$lang->bug->byQuery = '搜索';
$lang->bug->needConfirm = '需求變動';
$lang->bug->allProduct = '所有' . $lang->productCommon;
$lang->bug->my = '我的';
$lang->bug->assignToMeAB = '指派給我';
$lang->bug->openedByMeAB = '由我創建';
@@ -128,13 +129,13 @@ $lang->bug->ditto = '同上';
$lang->bug->dittoNotice = '該bug與上一bug不屬於同一產品!';
/* 頁面標籤。*/
$lang->bug->lblAssignedTo = '當前指派';
$lang->bug->lblMailto = '抄送給';
$lang->bug->lblLastEdited = '最後修改';
$lang->bug->lblResolved = '由誰解決';
$lang->bug->allUsers = '所有用戶';
$lang->bug->allBuilds = '所有';
$lang->bug->createBuild = '新建';
$lang->bug->lblAssignedTo = '當前指派';
$lang->bug->lblMailto = '抄送給';
$lang->bug->lblLastEdited = '最後修改';
$lang->bug->lblResolved = '由誰解決';
$lang->bug->allUsers = '所有用戶';
$lang->bug->allBuilds = '所有';
$lang->bug->createBuild = '新建';
/* legend列表。*/
$lang->bug->legendBasicInfo = '基本信息';
@@ -149,7 +150,7 @@ $lang->bug->legendMisc = '其他相關';
$lang->bug->legendRelated = '其他信息';
/* 功能按鈕。*/
$lang->bug->buttonConfirm = '確認';
$lang->bug->buttonConfirm = '確認';
/* 交互提示。*/
$lang->bug->confirmChangeProduct = "修改{$lang->productCommon}會導致相應的{$lang->projectCommon}、需求和任務發生變化,確定嗎?";
@@ -369,10 +370,6 @@ $lang->bug->placeholder = new stdclass();
$lang->bug->placeholder->chooseBuilds = '選擇相關版本...';
$lang->bug->placeholder->newBuildName = '新版本名稱';
$lang->bug->featureBar['browse']['unclosed'] = $lang->bug->unclosed;
$lang->bug->featureBar['browse']['all'] = $lang->bug->allBugs;
$lang->bug->featureBar['browse']['assigntome'] = $lang->bug->assignToMe;
+4 -5
View File
@@ -1,16 +1,15 @@
.tabs {position:relative;}
.tabs .nav-tabs{border-bottom:none;}
.tabs .nav-tabs>li{margin-bottom:0px;}
.tabs .tab-content {padding: 0; border: none;}
.tabs .tab-content .tab-pane .action {position: absolute; right: 0; top: -1px;}
.tabs .tab-content .tab-pane #querybox{margin:0px; border-left:1px solid #ddd; border-right:1px solid #ddd;}
.tabs .tab-content .tab-pane #querybox form {padding-left:0px;}
.table-actions {padding-left: 5px;}
#unlinkStoryList, #unlinkBugList{border:1px solid #ddd;}
.table-footer .text {line-height: 30px;}
.table-footer .table-actions {margin-right: 10px;}
#buildInfo {border-top: 1px solid #ddd;}
#buildInfo > div {padding-top: 15px;}
#querybox form {margin: 0px !important;}
+3 -2
View File
@@ -5,11 +5,12 @@ function showLink(buildID, type, param)
{
var obj = type == 'story' ? '.tab-pane#stories .linkBox' : '.tab-pane#bugs .linkBox';
$(obj).html(data);
$('#' + type + 'List').hide();
$('#' + type + 'List').closest('form').hide();
var formID = type == 'story' ? '#unlinkedStoriesForm' : '#unlinkedBugsForm';
setTimeout(function(){fixedTfootAction(formID)}, 100);
checkTable($(formID).find('table'));
$('[data-ride="table"]').table();
});
}
$(function()
+31 -30
View File
@@ -9,17 +9,17 @@
* @version $Id: en.php 4129 2013-01-18 01:58:14Z wwccss $
* @link http://www.zentao.net
*/
$lang->build->common = "Build";
$lang->build->create = "Create Build";
$lang->build->edit = "Edit";
$lang->build->linkStory = "Link Story";
$lang->build->linkBug = "Link Bug";
$lang->build->delete = "Delete Build";
$lang->build->deleted = "Deleted";
$lang->build->view = "Build Details";
$lang->build->batchUnlink = 'Batch Unlink';
$lang->build->batchUnlinkStory = 'Batch Story Unlink';
$lang->build->batchUnlinkBug = 'Batch Bug Unlink';
$lang->build->common = "Build";
$lang->build->create = "Create Build";
$lang->build->edit = "Edit";
$lang->build->linkStory = "Link Story";
$lang->build->linkBug = "Link Bug";
$lang->build->delete = "Delete Build";
$lang->build->deleted = "Deleted";
$lang->build->view = "Build Details";
$lang->build->batchUnlink = 'Batch Unlink';
$lang->build->batchUnlinkStory = 'Batch Story Unlink';
$lang->build->batchUnlinkBug = 'Batch Bug Unlink';
$lang->build->confirmDelete = "Do you want to delete this Build?";
$lang->build->confirmUnlinkStory = "Do you want to unlink this Story?";
@@ -27,25 +27,26 @@ $lang->build->confirmUnlinkBug = "Do you want to unlink this Bug?";
$lang->build->basicInfo = 'Basic Info';
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = 'Platform/Branch';
$lang->build->project = $lang->projectCommon;
$lang->build->name = 'Name';
$lang->build->date = 'Date';
$lang->build->builder = 'Builder';
$lang->build->scmPath = 'SCM Path';
$lang->build->filePath = 'File Path';
$lang->build->desc = 'Description';
$lang->build->files = 'Upload Files';
$lang->build->last = 'Last Build';
$lang->build->packageType = 'Package Type';
$lang->build->unlinkStory = 'Unlink Story';
$lang->build->unlinkBug = 'Unlink Bug';
$lang->build->stories = 'Finished Story';
$lang->build->bugs = 'Resolved Bug';
$lang->build->generatedBugs = 'Left Bug';
$lang->build->noProduct = " <span style='color:red'>This {$lang->projectCommon} has not linked to {$lang->productCommon}, so Build cannot be created. Please first <a href='%s'> link {$lang->productCommon}</a></span>";
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = 'Platform/Branch';
$lang->build->project = $lang->projectCommon;
$lang->build->name = 'Name';
$lang->build->date = 'Date';
$lang->build->builder = 'Builder';
$lang->build->scmPath = 'SCM Path';
$lang->build->filePath = 'File Path';
$lang->build->desc = 'Description';
$lang->build->files = 'Upload Files';
$lang->build->last = 'Last Build';
$lang->build->packageType = 'Package Type';
$lang->build->unlinkStory = 'Unlink Story';
$lang->build->unlinkBug = 'Unlink Bug';
$lang->build->stories = 'Finished Story';
$lang->build->bugs = 'Resolved Bug';
$lang->build->generatedBugs = 'Left Bug';
$lang->build->noProduct = " <span style='color:red'>This {$lang->projectCommon} has not linked to {$lang->productCommon}, so Build cannot be created. Please first <a href='%s'> link {$lang->productCommon}</a></span>";
$lang->build->noData = 'No data';
$lang->build->finishStories = ' %s Story(ies) have been finished.';
$lang->build->resolvedBugs = ' %s Bug(s) have been resolved.';
+31 -30
View File
@@ -9,17 +9,17 @@
* @version $Id: zh-cn.php 4129 2013-01-18 01:58:14Z wwccss $
* @link http://www.zentao.net
*/
$lang->build->common = "版本";
$lang->build->create = "创建版本";
$lang->build->edit = "编辑版本";
$lang->build->linkStory = "关联需求";
$lang->build->linkBug = "关联Bug";
$lang->build->delete = "删除版本";
$lang->build->deleted = "已删除";
$lang->build->view = "版本详情";
$lang->build->batchUnlink = '批量移除';
$lang->build->batchUnlinkStory = '批量移除需求';
$lang->build->batchUnlinkBug = '批量移除Bug';
$lang->build->common = "版本";
$lang->build->create = "创建版本";
$lang->build->edit = "编辑版本";
$lang->build->linkStory = "关联需求";
$lang->build->linkBug = "关联Bug";
$lang->build->delete = "删除版本";
$lang->build->deleted = "已删除";
$lang->build->view = "版本详情";
$lang->build->batchUnlink = '批量移除';
$lang->build->batchUnlinkStory = '批量移除需求';
$lang->build->batchUnlinkBug = '批量移除Bug';
$lang->build->confirmDelete = "您确认删除该版本吗?";
$lang->build->confirmUnlinkStory = "您确认移除该需求吗?";
@@ -27,25 +27,26 @@ $lang->build->confirmUnlinkBug = "您确认移除该Bug吗?";
$lang->build->basicInfo = '基本信息';
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = '平台/分支';
$lang->build->project = '所属' . $lang->projectCommon;
$lang->build->name = '名称编号';
$lang->build->date = '打包日期';
$lang->build->builder = '构建者';
$lang->build->scmPath = '源代码地址';
$lang->build->filePath = '下载地址';
$lang->build->desc = '描述';
$lang->build->files = '上传发行包';
$lang->build->last = '上个版本';
$lang->build->packageType = '包类型';
$lang->build->unlinkStory = '移除需求';
$lang->build->unlinkBug = '移除Bug';
$lang->build->stories = '完成的需求';
$lang->build->bugs = '解决的Bug';
$lang->build->generatedBugs = '产生的Bug';
$lang->build->noProduct = " <span style='color:red'>该{$lang->projectCommon}没有关联{$lang->productCommon},无法创建版本,请先<a href='%s'>关联{$lang->productCommon}</a></span>";
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = '平台/分支';
$lang->build->project = '所属' . $lang->projectCommon;
$lang->build->name = '名称编号';
$lang->build->date = '打包日期';
$lang->build->builder = '构建者';
$lang->build->scmPath = '源代码地址';
$lang->build->filePath = '下载地址';
$lang->build->desc = '描述';
$lang->build->files = '上传发行包';
$lang->build->last = '上个版本';
$lang->build->packageType = '包类型';
$lang->build->unlinkStory = '移除需求';
$lang->build->unlinkBug = '移除Bug';
$lang->build->stories = '完成的需求';
$lang->build->bugs = '解决的Bug';
$lang->build->generatedBugs = '产生的Bug';
$lang->build->noProduct = " <span style='color:red'>该{$lang->projectCommon}没有关联{$lang->productCommon},无法创建版本,请先<a href='%s'>关联{$lang->productCommon}</a></span>";
$lang->build->noData = '暂无';
$lang->build->finishStories = ' 本次共完成 %s 个需求';
$lang->build->resolvedBugs = ' 本次共解决 %s 个Bug';
+31 -30
View File
@@ -9,17 +9,17 @@
* @version $Id: zh-tw.php 4129 2013-01-18 01:58:14Z wwccss $
* @link http://www.zentao.net
*/
$lang->build->common = "版本";
$lang->build->create = "創建版本";
$lang->build->edit = "編輯版本";
$lang->build->linkStory = "關聯需求";
$lang->build->linkBug = "關聯Bug";
$lang->build->delete = "刪除版本";
$lang->build->deleted = "已刪除";
$lang->build->view = "版本詳情";
$lang->build->batchUnlink = '批量移除';
$lang->build->batchUnlinkStory = '批量移除需求';
$lang->build->batchUnlinkBug = '批量移除Bug';
$lang->build->common = "版本";
$lang->build->create = "創建版本";
$lang->build->edit = "編輯版本";
$lang->build->linkStory = "關聯需求";
$lang->build->linkBug = "關聯Bug";
$lang->build->delete = "刪除版本";
$lang->build->deleted = "已刪除";
$lang->build->view = "版本詳情";
$lang->build->batchUnlink = '批量移除';
$lang->build->batchUnlinkStory = '批量移除需求';
$lang->build->batchUnlinkBug = '批量移除Bug';
$lang->build->confirmDelete = "您確認刪除該版本嗎?";
$lang->build->confirmUnlinkStory = "您確認移除該需求嗎?";
@@ -27,25 +27,26 @@ $lang->build->confirmUnlinkBug = "您確認移除該Bug嗎?";
$lang->build->basicInfo = '基本信息';
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = '平台/分支';
$lang->build->project = '所屬' . $lang->projectCommon;
$lang->build->name = '名稱編號';
$lang->build->date = '打包日期';
$lang->build->builder = '構建者';
$lang->build->scmPath = '原始碼地址';
$lang->build->filePath = '下載地址';
$lang->build->desc = '描述';
$lang->build->files = '上傳發行包';
$lang->build->last = '上個版本';
$lang->build->packageType = '包類型';
$lang->build->unlinkStory = '移除需求';
$lang->build->unlinkBug = '移除Bug';
$lang->build->stories = '完成的需求';
$lang->build->bugs = '解決的Bug';
$lang->build->generatedBugs = '產生的Bug';
$lang->build->noProduct = " <span style='color:red'>該{$lang->projectCommon}沒有關聯{$lang->productCommon},無法創建版本,請先<a href='%s'>關聯{$lang->productCommon}</a></span>";
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = '平台/分支';
$lang->build->project = '所屬' . $lang->projectCommon;
$lang->build->name = '名稱編號';
$lang->build->date = '打包日期';
$lang->build->builder = '構建者';
$lang->build->scmPath = '原始碼地址';
$lang->build->filePath = '下載地址';
$lang->build->desc = '描述';
$lang->build->files = '上傳發行包';
$lang->build->last = '上個版本';
$lang->build->packageType = '包類型';
$lang->build->unlinkStory = '移除需求';
$lang->build->unlinkBug = '移除Bug';
$lang->build->stories = '完成的需求';
$lang->build->bugs = '解決的Bug';
$lang->build->generatedBugs = '產生的Bug';
$lang->build->noProduct = " <span style='color:red'>該{$lang->projectCommon}沒有關聯{$lang->productCommon},無法創建版本,請先<a href='%s'>關聯{$lang->productCommon}</a></span>";
$lang->build->noData = '暫無';
$lang->build->finishStories = ' 本次共完成 %s 個需求';
$lang->build->resolvedBugs = ' 本次共解決 %s 個Bug';
+45 -44
View File
@@ -10,57 +10,58 @@
* @link http://www.zentao.net
*/
?>
<?php
$jsRoot = $this->app->getWebRoot() . "js/";
include '../../common/view/tablesorter.html.php';
?>
<div id='querybox' class='show'></div>
<div id='unlinkBugList'>
<form method='post' id='unlinkedBugsForm' target='hiddenwin' action='<?php echo $this->createLink('build', 'linkBug', "buildID={$build->id}&browseType=$browseType&param=$param");?>'>
<table class='table table-condensed table-hover table-striped tablesorter table-fixed table-selectable'>
<caption class='text-left text-special'><?php echo html::icon('unlink');?> &nbsp;<strong><?php echo $lang->productplan->unlinkedBugs;?></strong></caption>
<form class='main-table table-bug' data-ride='table' method='post' id='unlinkedBugsForm' target='hiddenwin' action='<?php echo $this->createLink('build', 'linkBug', "buildID={$build->id}&browseType=$browseType&param=$param");?>'>
<div class='table-header'>
<div class='table-statistic'><?php echo html::icon('unlink');?> &nbsp;<strong><?php echo $lang->productplan->unlinkedBugs;?></strong></div>
</div>
<table class='table'>
<thead>
<tr class='colhead'>
<th class='w-id {sorter:"currency"}'><?php echo $lang->idAB;?></th>
<th class='w-pri'> <?php echo $lang->priAB;?></th>
<th> <?php echo $lang->bug->title;?></th>
<th class='w-user'> <?php echo $lang->openedByAB;?></th>
<th class='w-150px'> <?php echo $lang->bug->resolvedBy;?></th>
<th class='w-80px'> <?php echo $lang->statusAB;?></th>
</tr>
<tr>
<th class='c-id'>
<?php if($allBugs):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php echo $lang->idAB;?>
</th>
<th class='w-pri'> <?php echo $lang->priAB;?></th>
<th> <?php echo $lang->bug->title;?></th>
<th class='w-user'> <?php echo $lang->openedByAB;?></th>
<th class='w-150px'><?php echo $lang->bug->resolvedBy;?></th>
<th class='w-80px'> <?php echo $lang->statusAB;?></th>
</tr>
</thead>
<tbody>
<?php foreach($allBugs as $bug):?>
<?php if(strpos(",{$build->bugs},", ",$bug->id,") !== false) continue;?>
<?php if($build->product != $bug->product) continue; ?>
<tr>
<td class='cell-id'>
<input type='checkbox' name='bugs[<?php echo $bug->id?>]' value='<?php echo $bug->id;?>' <?php if($bug->status == 'resolved' or $bug->status == 'closed') echo "checked";?> />
<?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id"), $bug->id);?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bug->pri, $bug->pri);?>'><?php echo zget($lang->bug->priList, $bug->pri, $bug->pri)?></span></td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id", '', true), $bug->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td style='overflow:visible;padding-top:1px;padding-bottom:1px;'><?php echo ($bug->status == 'resolved' or $bug->status == 'closed') ? $users[$bug->resolvedBy] : html::select("resolvedBy[{$bug->id}]", $users, $this->app->user->account, "class='form-control chosen'");?></td>
<td class='text-center bug-<?php echo $bug->status?>'><?php echo $lang->bug->statusList[$bug->status];?></td>
</tr>
<?php endforeach;?>
<?php $unlinkedCount = 0;?>
<?php foreach($allBugs as $bug):?>
<?php if(strpos(",{$build->bugs},", ",$bug->id,") !== false) continue;?>
<?php if($build->product != $bug->product) continue; ?>
<tr>
<td class='cell-id'>
<?php echo html::checkbox('bugs', array($bug->id => sprintf('%03d', $bug->id)), ($bug->status == 'resolved' or $bug->status == 'closed') ? $story->id : '');?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bug->pri, $bug->pri);?>'><?php echo zget($lang->bug->priList, $bug->pri, $bug->pri)?></span></td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id", '', true), $bug->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td style='overflow:visible;padding-top:1px;padding-bottom:1px;'><?php echo ($bug->status == 'resolved' or $bug->status == 'closed') ? $users[$bug->resolvedBy] : html::select("resolvedBy[{$bug->id}]", $users, $this->app->user->account, "class='form-control chosen'");?></td>
<td class='text-center bug-<?php echo $bug->status?>'><?php echo $lang->bug->statusList[$bug->status];?></td>
</tr>
<?php $unlinkedCount++;?>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<td colspan='6' class='text-left'>
<?php if(count($allBugs))
{
echo "<div class='table-actions clearfix'>";
echo html::selectButton() . html::submitButton($lang->build->linkBug);
echo html::a(inlink('view', "buildID={$build->id}&type=bug"), $lang->goback, '', "class='btn'");
echo '</div>';
}
?>
</td>
</tr>
</tfoot>
</table>
<div class='table-footer'>
<?php if($unlinkedCount):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->build->linkBug);?>
</div>
<?php endif;?>
<?php echo html::a(inlink('view', "buildID={$build->id}&type=bug"), $lang->goback, '', "class='btn'");?>
</div>
</form>
</div>
<script>
+38 -38
View File
@@ -10,18 +10,23 @@
* @link http://www.zentao.net
*/
?>
<?php
$jsRoot = $this->app->getWebRoot() . "js/";
include '../../common/view/tablesorter.html.php';
?>
<div id='querybox' class='show'></div>
<div id='unlinkStoryList'>
<form method='post' id='unlinkedStoriesForm' target='hiddenwin' action='<?php echo $this->createLink('build', 'linkStory', "buildID={$build->id}&browseType=$browseType&param=$param");?>'>
<table class='table table-condensed table-hover table-striped tablesorter table-fixed table-selectable'>
<caption class='text-left text-special'><?php echo html::icon('unlink');?> &nbsp;<strong><?php echo $lang->productplan->unlinkedStories;?></strong></caption>
<form class='main-table table-story' data-ride='table' method='post' id='unlinkedStoriesForm' target='hiddenwin' action='<?php echo $this->createLink('build', 'linkStory', "buildID={$build->id}&browseType=$browseType&param=$param");?>'>
<div class='table-header'>
<div class='table-statistic'><?php echo html::icon('unlink');?> &nbsp;<strong><?php echo $lang->productplan->unlinkedStories;?></strong></div>
</div>
<table class='table'>
<thead>
<tr>
<th class='w-id {sorter:"currency"}'><?php echo $lang->idAB;?></th>
<th class='c-id'>
<?php if($allStories):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php echo $lang->idAB;?>
</th>
<th class='w-pri'> <?php echo $lang->priAB;?></th>
<th class="text-left"><?php echo $lang->story->title;?></th>
<th class='w-user'> <?php echo $lang->openedByAB;?></th>
@@ -32,40 +37,35 @@ include '../../common/view/tablesorter.html.php';
</tr>
</thead>
<tbody>
<?php foreach($allStories as $story):?>
<?php if(strpos(",{$build->stories},", ",{$story->id},") !== false) continue; ?>
<?php if($build->product != $story->product) continue; ?>
<tr>
<td class='cell-id'>
<input type='checkbox' name='stories[]' value='<?php echo $story->id;?>' <?php if($story->stage == 'developed' or $story->status == 'closed') echo 'checked';?> />
<?php echo html::a($this->createLink('story', 'view', "storyID=$story->id"), $story->id);?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->story->priList, $story->pri, $story->pri);?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri)?></span></td>
<td class='text-left nobr' title='<?php echo $story->title?>'><?php echo html::a($this->createLink('story', 'view', "storyID=$story->id", '', true), $story->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
<td class='text-center'><?php echo $users[$story->openedBy];?></td>
<td class='text-center'><?php echo $users[$story->assignedTo];?></td>
<td class='text-center'><?php echo $story->estimate;?></td>
<td class='text-center story-<?php echo $story->status?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td class='text-center'><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
<?php endforeach;?>
</tbody>
<tfoot>
<?php $unlinkedCount = 0;?>
<?php foreach($allStories as $story):?>
<?php if(strpos(",{$build->stories},", ",{$story->id},") !== false) continue; ?>
<?php if($build->product != $story->product) continue; ?>
<tr>
<td colspan='8' class='text-left'>
<?php
if(count($allStories))
{
echo "<div class='table-actions clearfix'>";
echo html::selectButton() . html::submitButton($lang->story->linkStory);
echo html::a(inlink('view', "buildID={$build->id}&type=story"), $lang->goback, '', "class='btn'");
echo '</div>';
}
?>
<td class='cell-id'>
<?php echo html::checkbox('stories', array($story->id => sprintf('%03d', $story->id)), ($story->stage == 'developed' or $story->status == 'closed') ? $story->id : '');?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->story->priList, $story->pri, $story->pri);?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri)?></span></td>
<td class='text-left nobr' title='<?php echo $story->title?>'><?php echo html::a($this->createLink('story', 'view', "storyID=$story->id", '', true), $story->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
<td class='text-center'><?php echo $users[$story->openedBy];?></td>
<td class='text-center'><?php echo $users[$story->assignedTo];?></td>
<td class='text-center'><?php echo $story->estimate;?></td>
<td class='text-center story-<?php echo $story->status?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td class='text-center'><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
</tfoot>
<?php $unlinkedCount++;?>
<?php endforeach;?>
</tbody>
</table>
<div class='table-footer'>
<?php if($unlinkedCount):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->build->linkStory);?>
</div>
<?php endif;?>
<?php echo html::a(inlink('view', "buildID={$build->id}&type=story"), $lang->goback, '', "class='btn'");?>
</div>
</form>
</div>
<script>
+238 -219
View File
@@ -20,285 +20,304 @@
#bugs .action{display:none;}
tbody tr td:last-child a{display:none;}
tbody tr td:first-child input{display:none;}
tfoot tr td .table-actions .btn{display:none;}
#titlebar .actions{display:none}
.row-table .col-side{display:none;}
</style>
<?php endif;?>
<div id='titlebar'>
<div class='heading'>
<span class='prefix'><?php echo html::icon($lang->icons['build']);?> <strong><?php echo $build->id;?></strong></span>
<strong><?php echo $build->name;?></strong>
<?php if($build->deleted):?>
<span class='label label-danger'><?php echo $lang->build->deleted;?></span>
<?php endif; ?>
<div id='mainMenu' class='clearfix'>
<div class='btn-toolbar pull-left'>
<?php $browseLink = $this->session->buildList ? $this->session->buildList : $this->createLink('project', 'build', "projectID=$build->project");?>
<?php common::printBack($browseLink, 'btn btn-link');?>
<div class='divider'></div>
<div class='page-title'>
<span class='label label-id'><?php echo $build->id;?></span>
<span class='text'><?php echo $build->name;?></span>
<?php if($build->deleted):?>
<span class='label label-danger'><?php echo $lang->build->deleted;?></span>
<?php endif; ?>
</div>
</div>
<div class='actions'>
<?php
$browseLink = $this->session->buildList ? $this->session->buildList : $this->createLink('project', 'build', "projectID=$build->project");
if(!$build->deleted)
{
if($this->config->global->flow != 'onlyTest')
{
echo "<div class='btn-group'>";
if(common::hasPriv('build', 'linkStory')) echo html::a(inlink('view', "buildID=$build->id&type=story&link=true"), '<i class="icon-link"></i> ' . $lang->build->linkStory, '', "class='btn'");
if(common::hasPriv('build', 'linkBug')) echo html::a(inlink('view', "buildID=$build->id&type=bug&link=true"), '<i class="icon-bug"></i> ' . $lang->build->linkBug, '', "class='btn'");
echo '</div>';
}
echo "<div class='btn-group'>";
common::printIcon('build', 'edit', "buildID=$build->id", $build);
common::printIcon('build', 'delete', "buildID=$build->id", $build, 'button', '', 'hiddenwin');
echo '</div>';
}
echo common::printRPN($browseLink);
?>
<div class='btn-toolbar pull-right'>
<?php
if(!$build->deleted)
{
if($this->config->global->flow != 'onlyTest')
{
if(common::hasPriv('build', 'linkStory')) echo html::a(inlink('view', "buildID=$build->id&type=story&link=true"), '<i class="icon-link"></i> ' . $lang->build->linkStory, '', "class='btn btn-link'");
if(common::hasPriv('build', 'linkBug')) echo html::a(inlink('view', "buildID=$build->id&type=bug&link=true"), '<i class="icon-bug"></i> ' . $lang->build->linkBug, '', "class='btn btn-link'");
}
common::printIcon('build', 'edit', "buildID=$build->id", $build);
common::printIcon('build', 'delete', "buildID=$build->id", $build, 'button', '', 'hiddenwin');
}
?>
</div>
</div>
<div class='row-table'>
<div class='col-main'>
<div class='main'>
<?php if($this->config->global->flow == 'onlyTest'):?>
<fieldset>
<legend><?php echo $lang->build->desc;?></legend>
<div class='article-content'><?php echo $build->desc;?></div>
</fieldset>
<?php echo $this->fetch('file', 'printFiles', array('files' => $build->files, 'fieldset' => 'true'));?>
<?php include '../../common/view/action.html.php';?>
<div class='actions'>
<?php
$browseLink = $this->session->buildList ? $this->session->buildList : $this->createLink('product', 'build', "productID=$build->product");
if(!$build->deleted)
{
common::printIcon('build', 'edit', "buildID=$build->id", $build);
common::printIcon('build', 'delete', "buildID=$build->id", $build, 'button', '', 'hiddenwin');
}
echo common::printRPN($browseLink);
?>
</div>
<?php else:?>
<div class='tabs'>
<?php $countStories = count($stories); $countBugs = count($bugs); $countNewBugs = count($generatedBugs);?>
<ul class='nav nav-tabs'>
<li <?php if($type == 'story') echo "class='active'"?>><a href='#stories' data-toggle='tab'><?php echo html::icon($lang->icons['story'], 'green') . ' ' . $lang->build->stories;?></a></li>
<li <?php if($type == 'bug') echo "class='active'"?>><a href='#bugs' data-toggle='tab'><?php echo html::icon($lang->icons['bug'], 'green') . ' ' . $lang->build->bugs;?></a></li>
<li <?php if($type == 'newbug') echo "class='active'"?>><a href='#newBugs' data-toggle='tab'><?php echo html::icon($lang->icons['bug'], 'red') . ' ' . $lang->build->generatedBugs;?></a></li>
<li <?php if($type == 'buildInfo') echo "class='active'"?>><a href='#buildInfo' data-toggle='tab'><?php echo html::icon($lang->icons['plan'], 'blue') . ' ' . $lang->build->view;?></a></li>
</ul>
<div class='tab-content'>
<div class='tab-pane <?php if($type == 'story') echo 'active'?>' id='stories'>
<?php if(common::hasPriv('build', 'linkStory')):?>
<div class='action'><?php echo html::a("javascript:showLink($build->id, \"story\")", '<i class="icon-link"></i> ' . $lang->build->linkStory, '', "class='btn btn-sm btn-primary'");?></div>
<div class='linkBox'></div>
<?php endif;?>
<form method='post' target='hiddenwin' action='<?php echo inlink('batchUnlinkStory', "buildID={$build->id}")?>' id='linkedStoriesForm'>
<table class='table table-hover table-condensed table-striped tablesorter table-fixed table-selectable' id='storyList'>
<?php $vars = "buildID={$build->id}&type=story&link=$link&param=$param&orderBy=%s";?>
<thead>
<tr>
<th class='w-id {sorter:false}'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th class='w-pri {sorter:false}'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th class='text-left {sorter:false}'><?php common::printOrderLink('title', $orderBy, $vars, $lang->story->title);?></th>
<th class='w-user {sorter:false}'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-hour {sorter:false}'> <?php common::printOrderLink('estimate', $orderBy, $vars, $lang->story->estimateAB);?></th>
<th class='w-hour {sorter:false}'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->statusAB);?></th>
<th class='w-100px {sorter:false}'> <?php common::printOrderLink('stage', $orderBy, $vars, $lang->story->stageAB);?></th>
<th class='w-60px {sorter:false}'> <?php echo $lang->actions?></th>
</tr>
</thead>
<?php $canBatchUnlink = common::hasPriv('build', 'batchUnlinkStory');?>
<div id='mainContent' class='main-content'>
<?php if($this->config->global->flow == 'onlyTest'):?>
<fieldset>
<legend><?php echo $lang->build->desc;?></legend>
<div class='article-content'><?php echo $build->desc;?></div>
</fieldset>
<?php echo $this->fetch('file', 'printFiles', array('files' => $build->files, 'fieldset' => 'true'));?>
<?php include '../../common/view/action.html.php';?>
<div class='actions'>
<?php
$browseLink = $this->session->buildList ? $this->session->buildList : $this->createLink('product', 'build', "productID=$build->product");
if(!$build->deleted)
{
common::printIcon('build', 'edit', "buildID=$build->id", $build);
common::printIcon('build', 'delete', "buildID=$build->id", $build, 'button', '', 'hiddenwin');
}
echo common::printRPN($browseLink);
?>
</div>
<?php else:?>
<div class='tabs'>
<?php $countStories = count($stories); $countBugs = count($bugs); $countNewBugs = count($generatedBugs);?>
<ul class='nav nav-tabs'>
<li <?php if($type == 'story') echo "class='active'"?>><a href='#stories' data-toggle='tab'><?php echo html::icon($lang->icons['story'], 'green') . ' ' . $lang->build->stories;?></a></li>
<li <?php if($type == 'bug') echo "class='active'"?>><a href='#bugs' data-toggle='tab'><?php echo html::icon($lang->icons['bug'], 'green') . ' ' . $lang->build->bugs;?></a></li>
<li <?php if($type == 'newbug') echo "class='active'"?>><a href='#newBugs' data-toggle='tab'><?php echo html::icon($lang->icons['bug'], 'red') . ' ' . $lang->build->generatedBugs;?></a></li>
<li <?php if($type == 'buildInfo') echo "class='active'"?>><a href='#buildInfo' data-toggle='tab'><?php echo html::icon($lang->icons['plan'], 'blue') . ' ' . $lang->build->view;?></a></li>
</ul>
<div class='tab-content'>
<div class='tab-pane <?php if($type == 'story') echo 'active'?>' id='stories'>
<?php if(common::hasPriv('build', 'linkStory')):?>
<div class='action'><?php echo html::a("javascript:showLink($build->id, \"story\")", '<i class="icon-link"></i> ' . $lang->build->linkStory, '', "class='btn btn-sm btn-primary'");?></div>
<div class='linkBox'></div>
<?php endif;?>
<form class='main-table table-story' data-ride='table' method='post' target='hiddenwin' action='<?php echo inlink('batchUnlinkStory', "buildID={$build->id}")?>' id='linkedStoriesForm'>
<table class='table has-sort-head' id='storyList'>
<?php $canBatchUnlink = common::hasPriv('build', 'batchUnlinkStory');?>
<?php $vars = "buildID={$build->id}&type=story&link=$link&param=$param&orderBy=%s";?>
<thead>
<tr>
<th class='c-id'>
<?php if($canBatchUnlink):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
</th>
<th class='w-70px'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th class='text-left'><?php common::printOrderLink('title', $orderBy, $vars, $lang->story->title);?></th>
<th class='w-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-70px'> <?php common::printOrderLink('estimate', $orderBy, $vars, $lang->story->estimateAB);?></th>
<th class='w-70px'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->statusAB);?></th>
<th class='w-100px'> <?php common::printOrderLink('stage', $orderBy, $vars, $lang->story->stageAB);?></th>
<th class='w-60px'> <?php echo $lang->actions?></th>
</tr>
</thead>
<tbody>
<?php foreach($stories as $storyID => $story):?>
<?php $storyLink = $this->createLink('story', 'view', "storyID=$story->id", '', true);?>
<tr class='text-center'>
<tr>
<td class='cell-id'>
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkStories[]' value='<?php echo $story->id;?>'/>
<?php echo html::checkbox('unlinkStories', array($story->id => sprintf('%03d', $story->id)));?>
<?php else:?>
<?php printf('%03d', $story->id);?>
<?php endif;?>
<?php echo sprintf('%03d', $story->id);?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->story->priList, $story->pri, $story->pri);?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri);?></span></td>
<td class='text-left nobr' title='<?php echo $story->title?>'><?php echo html::a($storyLink,$story->title, '', "class='preview'");?></td>
<td><?php echo $users[$story->openedBy];?></td>
<td><?php echo $story->estimate;?></td>
<td class='text-center'><?php echo $story->estimate;?></td>
<td class='story-<?php echo $story->status;?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
<td>
<td class='c-actions'>
<?php
if(common::hasPriv('build', 'unlinkStory'))
{
$unlinkURL = inlink('unlinkStory', "buildID=$build->id&story=$story->id");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"storyList\",confirmUnlinkStory)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->build->unlinkStory}'");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"storyList\",confirmUnlinkStory)", '<i class="icon-unlink"></i>', '', "class='btn btn-icon' title='{$lang->build->unlinkStory}'");
}
?>
</td>
</tr>
<?php endforeach;?>
<tfoot>
<tr>
<td colspan='8'>
<div class='table-actions clearfix'>
<?php if($countStories and $canBatchUnlink) echo html::selectButton() . html::submitButton($lang->build->batchUnlink);?>
<div class='text'><?php echo sprintf($lang->build->finishStories, $countStories);?></div>
</div>
</td>
</tr>
</tfoot>
</table>
</form>
</div>
<div class='tab-pane <?php if($type == 'bug') echo 'active'?>' id='bugs'>
<?php if(common::hasPriv('build', 'linkBug')):?>
<div class='action'><?php echo html::a("javascript:showLink($build->id, \"bug\")", '<i class="icon-bug"></i> ' . $lang->build->linkBug, '', "class='btn btn-sm btn-primary'");?></div>
<div class='linkBox'></div>
</tbody>
</table>
<?php if($countStories):?>
<div class='table-footer'>
<?php if($canBatchUnlink):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->build->batchUnlink);?>
</div>
<?php endif;?>
<form method='post' target='hiddenwin' action="<?php echo inLink('batchUnlinkBug', "build=$build->id");?>" id='linkedBugsForm'>
<table class='table table-hover table-condensed table-striped tablesorter table-fixed table-selectable' id='bugList'>
<?php $vars = "buildID={$build->id}&type=bug&link=$link&param=$param&orderBy=%s";?>
<thead>
<tr>
<th class='w-id {sorter:false}'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th class='text-left {sorter:false}'><?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<th class='w-100px {sorter:false}'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->bug->status);?></th>
<th class='w-user {sorter:false}'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-date {sorter:false}'> <?php common::printOrderLink('openedDate', $orderBy, $vars, $lang->bug->openedDateAB);?></th>
<th class='w-user {sorter:false}'> <?php common::printOrderLink('resolvedBy', $orderBy, $vars, $lang->bug->resolvedByAB);?></th>
<th class='w-100px {sorter:false}'> <?php common::printOrderLink('resolvedDate', $orderBy, $vars, $lang->bug->resolvedDateAB);?></th>
<th class='w-60px {sorter:false}'> <?php echo $lang->actions?></th>
</tr>
</thead>
<?php $canBatchUnlink = common::hasPriv('build', 'batchUnlinkBug');?>
<div class='text'><?php echo sprintf($lang->build->finishStories, $countStories);?></div>
</div>
<?php endif;?>
</form>
</div>
<div class='tab-pane <?php if($type == 'bug') echo 'active'?>' id='bugs'>
<?php if(common::hasPriv('build', 'linkBug')):?>
<div class='action'><?php echo html::a("javascript:showLink($build->id, \"bug\")", '<i class="icon-bug"></i> ' . $lang->build->linkBug, '', "class='btn btn-sm btn-primary'");?></div>
<div class='linkBox'></div>
<?php endif;?>
<form class='main-table table-bug' data-ride='table' method='post' target='hiddenwin' action="<?php echo inLink('batchUnlinkBug', "build=$build->id");?>" id='linkedBugsForm'>
<table class='table has-sort-head' id='bugList'>
<?php $canBatchUnlink = common::hasPriv('build', 'batchUnlinkBug');?>
<?php $vars = "buildID={$build->id}&type=bug&link=$link&param=$param&orderBy=%s";?>
<thead>
<tr>
<th class='c-id'>
<?php if($canBatchUnlink):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
</th>
<th class='text-left'><?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<th class='w-100px'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->bug->status);?></th>
<th class='w-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-date'> <?php common::printOrderLink('openedDate', $orderBy, $vars, $lang->bug->openedDateAB);?></th>
<th class='w-user'> <?php common::printOrderLink('resolvedBy', $orderBy, $vars, $lang->bug->resolvedByAB);?></th>
<th class='w-100px'> <?php common::printOrderLink('resolvedDate', $orderBy, $vars, $lang->bug->resolvedDateAB);?></th>
<th class='w-60px'> <?php echo $lang->actions?></th>
</tr>
</thead>
<tbody>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id", '', true);?>
<tr class='text-center'>
<td class='cell-id'>
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkBugs[]' value='<?php echo $bug->id;?>'/>
<?php echo html::checkbox('unlinkBugs', array($bug->id => sprintf('%03d', $bug->id)));?>
<?php else:?>
<?php printf('%03d', $bug->id);?>
<?php endif;?>
<?php echo sprintf('%03d', $bug->id);?>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td class='bug-<?php echo $bug->status?>'><?php echo $lang->bug->statusList[$bug->status];?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
<td>
<td class='c-actions'>
<?php
if(common::hasPriv('build', 'unlinkBug'))
{
$unlinkURL = inlink('unlinkBug', "buildID=$build->id&bug=$bug->id");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"bugList\",confirmUnlinkBug)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->build->unlinkBug}'");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"bugList\",confirmUnlinkBug)", '<i class="icon-unlink"></i>', '', "class='btn btn-icon' title='{$lang->build->unlinkBug}'");
}
?>
</td>
</tr>
<?php endforeach;?>
<tfoot>
<tr>
<td colspan='8'>
<div class='table-actions clearfix'>
<?php if($countBugs and $canBatchUnlink) echo html::selectButton() . html::submitButton($lang->build->batchUnlink);?>
<div class='text'><?php echo sprintf($lang->build->resolvedBugs, $countBugs);?></div>
</div>
</td>
</tr>
</tfoot>
</table>
</form>
</tbody>
</table>
<?php if($countBugs):?>
<div class='table-footer'>
<?php if($canBatchUnlink):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->build->batchUnlink);?>
</div>
<?php endif;?>
<div class='text'><?php echo sprintf($lang->build->resolvedBugs, $countBugs);?></div>
</div>
<div class='tab-pane <?php if($type == 'newbug') echo 'active'?>' id='newBugs'>
<table class='table table-hover table-condensed table-striped tablesorter table-fixed'>
<?php $vars = "buildID={$build->id}&type=newbug&link=$link&param=$param&orderBy=%s";?>
<thead>
<?php endif;?>
</form>
</div>
<div class='tab-pane <?php if($type == 'newbug') echo 'active'?>' id='newBugs'>
<table class='main-table table has-sort-head'>
<?php $vars = "buildID={$build->id}&type=newbug&link=$link&param=$param&orderBy=%s";?>
<thead>
<tr>
<th class='c-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th class='w-severity'><?php common::printOrderLink('severity', $orderBy, $vars, $lang->bug->severityAB);?></th>
<th class='text-left'> <?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<th class='w-100px'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->bug->status);?></th>
<th class='w-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-date'> <?php common::printOrderLink('openedDate', $orderBy, $vars, $lang->bug->openedDateAB);?></th>
<th class='w-user'> <?php common::printOrderLink('resolvedBy', $orderBy, $vars, $lang->bug->resolvedByAB);?></th>
<th class='w-100px'> <?php common::printOrderLink('resolvedDate', $orderBy, $vars, $lang->bug->resolvedDateAB);?></th>
</tr>
</thead>
<tbody>
<?php foreach($generatedBugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id", '', true);?>
<tr class='text-center'>
<td><?php printf('%03d', $bug->id);?></td>
<td><span class='severity<?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity)?>'><?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity);?></span></td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td class='bug-<?php echo $bug->status?>'><?php echo $lang->bug->statusList[$bug->status];?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if($countNewBugs):?>
<div class='table-footer'>
<div class='text'><?php echo sprintf($lang->build->createdBugs, $countNewBugs);?></div>
</div>
<?php endif;?>
</div>
<div class='tab-pane <?php if($type == 'buildInfo') echo 'active'?>' id='buildInfo'>
<div class='cell'>
<div class='detail'>
<div class='detail-title'><?php echo $lang->build->basicInfo?></div>
<div class='detail-content'>
<table class='table table-data table-condensed table-borderless table-fixed'>
<tr>
<th class='w-id {sorter:false}'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th class='w-severity {sorter:false}'><?php common::printOrderLink('severity', $orderBy, $vars, $lang->bug->severityAB);?></th>
<th class='text-left {sorter:false}'> <?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<th class='w-100px {sorter:false}'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->bug->status);?></th>
<th class='w-user {sorter:false}'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-date {sorter:false}'> <?php common::printOrderLink('openedDate', $orderBy, $vars, $lang->bug->openedDateAB);?></th>
<th class='w-user {sorter:false}'> <?php common::printOrderLink('resolvedBy', $orderBy, $vars, $lang->bug->resolvedByAB);?></th>
<th class='w-100px {sorter:false}'> <?php common::printOrderLink('resolvedDate', $orderBy, $vars, $lang->bug->resolvedDateAB);?></th>
<th class='w-80px'><?php echo $lang->build->product;?></th>
<td><?php echo $build->productName;?></td>
</tr>
</thead>
<?php foreach($generatedBugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id", '', true);?>
<tr class='text-center'>
<td><?php echo sprintf('%03d', $bug->id);?></td>
<td><span class='severity<?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity)?>'><?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity);?></span></td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td class='bug-<?php echo $bug->status?>'><?php echo $lang->bug->statusList[$bug->status];?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
</tr>
<?php endforeach;?>
<tfoot>
<?php if($build->productType != 'normal'):?>
<tr>
<td colspan='8'>
<div class='table-actions clearfix'>
<div class='text'><?php echo sprintf($lang->build->createdBugs, $countNewBugs);?></div>
</div>
</td>
<th><?php echo $lang->product->branch;?></th>
<td><?php echo $branchName;?></td>
</tr>
</tfoot>
</table>
</div>
<div class='tab-pane <?php if($type == 'buildInfo') echo 'active'?>' id='buildInfo'>
<div class="row-table">
<div class='col-main'>
<fieldset>
<legend><?php echo $lang->build->basicInfo?></legend>
<table class='table table-data table-condensed table-borderless table-fixed'>
<tr>
<th class='w-80px'><?php echo $lang->build->product;?></th>
<td><?php echo $build->productName;?></td>
</tr>
<?php if($build->productType != 'normal'):?>
<tr>
<th><?php echo $lang->product->branch;?></th>
<td><?php echo $branchName;?></td>
</tr>
<?php endif;?>
<tr>
<th><?php echo $lang->build->name;?></th>
<td><?php echo $build->name;?></td>
</tr>
<tr>
<th><?php echo $lang->build->builder;?></th>
<td><?php echo $users[$build->builder];?></td>
</tr>
<tr>
<th><?php echo $lang->build->date;?></th>
<td><?php echo $build->date;?></td>
</tr>
<tr>
<th><?php echo $lang->build->scmPath;?></th>
<td style='word-break:break-all;'><?php echo html::a($build->scmPath, $build->scmPath, '_blank')?></td>
</tr>
<tr>
<th><?php echo $lang->build->filePath;?></th>
<td style='word-break:break-all;'><?php echo html::a($build->filePath, $build->filePath, '_blank');?></td>
</tr>
<?php if($this->config->global->flow != 'onlyTest'):?>
<tr>
<th><?php echo $lang->build->desc;?></th>
<td><div class='article-content'><?php echo $build->desc;?></div></td>
</tr>
<?php endif;?>
</table>
</fieldset>
<?php if($this->config->global->flow != 'onlyTest'):?>
<?php echo $this->fetch('file', 'printFiles', array('files' => $build->files, 'fieldset' => 'true'));?>
<?php endif;?>
</div>
<div class="col-side"><?php include '../../common/view/action.html.php';?></div>
<tr>
<th><?php echo $lang->build->name;?></th>
<td><?php echo $build->name;?></td>
</tr>
<tr>
<th><?php echo $lang->build->builder;?></th>
<td><?php echo $users[$build->builder];?></td>
</tr>
<tr>
<th><?php echo $lang->build->date;?></th>
<td><?php echo $build->date;?></td>
</tr>
<tr>
<th><?php echo $lang->build->scmPath;?></th>
<td style='word-break:break-all;'><?php echo html::a($build->scmPath, $build->scmPath, '_blank')?></td>
</tr>
<tr>
<th><?php echo $lang->build->filePath;?></th>
<td style='word-break:break-all;'><?php echo html::a($build->filePath, $build->filePath, '_blank');?></td>
</tr>
<?php if($this->config->global->flow != 'onlyTest'):?>
<tr>
<th><?php echo $lang->build->desc;?></th>
<td>
<?php if($build->desc):?>
<div class='article-content'><?php echo $build->desc;?></div>
<?php else:?>
<?php echo $lang->build->noData;?>
<?php endif;?>
</td>
</tr>
<?php endif;?>
</table>
</div>
</div>
<?php if($this->config->global->flow != 'onlyTest'):?>
<?php echo $this->fetch('file', 'printFiles', array('files' => $build->files, 'fieldset' => 'true'));?>
<?php endif;?>
<?php include '../../common/view/action.html.php';?>
</div>
</div>
<?php endif;?>
</div>
</div>
<?php endif;?>
</div>
<?php if($this->config->global->flow != 'onlyTest'):?>
<?php js::set('param', helper::safe64Decode($param))?>
+7 -11
View File
@@ -48,19 +48,15 @@ $lang->branch->menuOrder = $lang->product->menuOrder;
/* project menu order. */
$lang->project->menuOrder[5] = 'list';
$lang->project->menuOrder[10] = 'index';
$lang->project->menuOrder[15] = 'task';
$lang->project->menuOrder[10] = 'kanban';
$lang->project->menuOrder[15] = 'burn';
$lang->project->menuOrder[20] = 'story';
$lang->project->menuOrder[25] = 'bug';
$lang->project->menuOrder[30] = 'build';
$lang->project->menuOrder[35] = 'testtask';
$lang->project->menuOrder[25] = 'qa';
$lang->project->menuOrder[30] = 'doc';
$lang->project->menuOrder[35] = 'action';
$lang->project->menuOrder[40] = 'team';
$lang->project->menuOrder[45] = 'dynamic';
$lang->project->menuOrder[50] = 'doc';
$lang->project->menuOrder[55] = 'product';
$lang->project->menuOrder[60] = 'view';
$lang->project->menuOrder[65] = 'create';
$lang->project->menuOrder[70] = 'all';
$lang->project->menuOrder[45] = 'product';
$lang->project->menuOrder[50] = 'view';
$lang->task->menuOrder = $lang->project->menuOrder;
$lang->build->menuOrder = $lang->project->menuOrder;
+29 -8
View File
@@ -222,21 +222,42 @@ $lang->release->menu = $lang->product->menu;
$lang->project = new stdclass();
$lang->project->menu = new stdclass();
$lang->project->menu->task = array('link' => '任务|project|task|projectID=%s', 'subModule' => 'task,tree', 'alias' => 'grouptask,importtask,burn,importbug,kanban,printkanban,tree');
$lang->project->menu->list = array('link' => '%s', 'subModule' => 'task,tree', 'alias' => 'grouptask,importtask,importbug,tree');
$lang->project->menu->kanban = array('link' => '看板|project|kanban|projectID=%s');
$lang->project->menu->burn = array('link' => '燃尽图|project|burn|projectID=%s');
$lang->project->menu->story = array('link' => '需求|project|story|projectID=%s', 'subModule' => 'story', 'alias' => 'linkstory,storykanban');
$lang->project->menu->bug = 'Bug|project|bug|projectID=%s';
$lang->project->menu->dynamic = '动态|project|dynamic|projectID=%s';
$lang->project->menu->build = array('link' => '版本|project|build|projectID=%s', 'subModule' => 'build');
$lang->project->menu->testtask = array('link' => '测试单|project|testtask|projectID=%s');
$lang->project->menu->team = array('link' => '团队|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->qa = array('link' => '%s', 'subModule' => 'build');
$lang->project->menu->doc = array('link' => '文档|doc|objectLibs|type=project&objectID=%s&from=project', 'subModule' => 'doc');
$lang->project->menu->action = array('link' => '%s');
$lang->project->menu->product = $lang->productCommon . '|project|manageproducts|projectID=%s';
$lang->project->menu->team = array('link' => '团队|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->view = array('link' => '概况|project|view|projectID=%s', 'alias' => 'edit,start,suspend,putoff,close');
$lang->project->subMenu = new stdclass();
$lang->project->subMenu->list = new stdclass();
$lang->project->subMenu->list->task = '任务列表|project|task|projectID=%s';
$lang->project->subMenu->list->tree = '树状图|project|tree|projectID=%s';
$lang->project->subMenu->list->groupTask = '分组视图|project|groupTask|projectID=%s';
$lang->project->subMenu->qa = new stdclass();
$lang->project->subMenu->qa->bug = 'Bug|project|bug|projectID=%s';
$lang->project->subMenu->qa->build = '版本|project|build|projectID=%s';
$lang->project->subMenu->qa->testtask = array('link' => '测试单|project|testtask|projectID=%s', 'subModule' => 'testreport');
$lang->project->subMenu->action = new stdclass();
$lang->project->subMenu->action->dynamic = '动态|project|dynamic|projectID=%s';
$lang->project->dividerMenu = ',story,doc,';
$lang->task = new stdclass();
$lang->build = new stdclass();
$lang->task->menu = $lang->project->menu;
$lang->build->menu = $lang->project->menu;
$lang->task->menu = $lang->project->menu;
$lang->task->subMenu = $lang->project->subMenu;
$lang->build->menu = $lang->project->menu;
$lang->build->subMenu = $lang->project->subMenu;
$lang->task->dividerMenu = $lang->project->dividerMenu;
$lang->build->dividerMenu = $lang->project->dividerMenu;
/* QA视图菜单设置。*/
$lang->qa = new stdclass();
+30 -9
View File
@@ -111,7 +111,7 @@ $lang->common->common = '公有模組';
$lang->menu = new stdclass();
$lang->menu->my = '<span> 我的地盤</span>|my|index';
$lang->menu->product = $lang->productCommon . '|product|index|locate=no';
$lang->menu->project = $lang->projectCommon . '|project|index';
$lang->menu->project = $lang->projectCommon . '|project|index|locate=no';
$lang->menu->qa = '測試|qa|index';
$lang->menu->doc = '文檔|doc|index';
$lang->menu->report = '統計|report|index';
@@ -221,21 +221,42 @@ $lang->release->menu = $lang->product->menu;
$lang->project = new stdclass();
$lang->project->menu = new stdclass();
$lang->project->menu->task = array('link' => '任務|project|task|projectID=%s', 'subModule' => 'task,tree', 'alias' => 'grouptask,importtask,burn,importbug,kanban,printkanban,tree');
$lang->project->menu->list = array('link' => '%s', 'subModule' => 'task,tree', 'alias' => 'grouptask,importtask,importbug,tree');
$lang->project->menu->kanban = array('link' => '看板|project|kanban|projectID=%s');
$lang->project->menu->burn = array('link' => '燃盡圖|project|burn|projectID=%s');
$lang->project->menu->story = array('link' => '需求|project|story|projectID=%s', 'subModule' => 'story', 'alias' => 'linkstory,storykanban');
$lang->project->menu->bug = 'Bug|project|bug|projectID=%s';
$lang->project->menu->dynamic = '動態|project|dynamic|projectID=%s';
$lang->project->menu->build = array('link' => '版本|project|build|projectID=%s', 'subModule' => 'build');
$lang->project->menu->testtask = array('link' => '測試單|project|testtask|projectID=%s');
$lang->project->menu->team = array('link' => '團隊|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->qa = array('link' => '%s', 'subModule' => 'build');
$lang->project->menu->doc = array('link' => '文檔|doc|objectLibs|type=project&objectID=%s&from=project', 'subModule' => 'doc');
$lang->project->menu->action = array('link' => '%s');
$lang->project->menu->product = $lang->productCommon . '|project|manageproducts|projectID=%s';
$lang->project->menu->team = array('link' => '團隊|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->view = array('link' => '概況|project|view|projectID=%s', 'alias' => 'edit,start,suspend,putoff,close');
$lang->project->subMenu = new stdclass();
$lang->project->subMenu->list = new stdclass();
$lang->project->subMenu->list->task = '任務列表|project|task|projectID=%s';
$lang->project->subMenu->list->tree = '樹狀圖|project|tree|projectID=%s';
$lang->project->subMenu->list->groupTask = '分組視圖|project|groupTask|projectID=%s';
$lang->project->subMenu->qa = new stdclass();
$lang->project->subMenu->qa->bug = 'Bug|project|bug|projectID=%s';
$lang->project->subMenu->qa->build = '版本|project|build|projectID=%s';
$lang->project->subMenu->qa->testtask = '測試單|project|testtask|projectID=%s';
$lang->project->subMenu->action = new stdclass();
$lang->project->subMenu->action->dynamic = '動態|project|dynamic|projectID=%s';
$lang->project->dividerMenu = ',story,doc,';
$lang->task = new stdclass();
$lang->build = new stdclass();
$lang->task->menu = $lang->project->menu;
$lang->build->menu = $lang->project->menu;
$lang->task->menu = $lang->project->menu;
$lang->task->subMenu = $lang->project->subMenu;
$lang->build->menu = $lang->project->menu;
$lang->build->subMenu = $lang->project->subMenu;
$lang->task->dividerMenu = $lang->project->dividerMenu;
$lang->build->dividerMenu = $lang->project->dividerMenu;
/* QA視圖菜單設置。*/
$lang->qa = new stdclass();
+12 -14
View File
@@ -456,40 +456,38 @@ class commonModel extends model
/* Cycling to print every sub menus. */
foreach($menu as $menuItem)
{
if(isset($lang->$moduleName->dividerMenu) and strpos($lang->$moduleName->dividerMenu, ",{$menuItem->name},") !== false) echo "<li class='divider'></li>";
if(isset($menuItem->hidden) && $menuItem->hidden) continue;
if($isMobile and empty($menuItem->link)) continue;
/* Init the these vars. */
$alias = isset($menuItem->alias) ? $menuItem->alias : '';
$subModule = isset($menuItem->subModule) ? explode(',', $menuItem->subModule) : array();
$class = isset($menuItem->class) ? $menuItem->class : '';
$active = '';
if($subModule and in_array($currentModule, $subModule)) $active = 'active';
if($alias and $moduleName == $currentModule and strpos(",$alias,", ",$currentMethod,") !== false) $active = 'active';
if($menuItem->link)
{
$active = '';
$float = isset($menuItem->float) ? $menuItem->float : '';
$alias = '';
$target = '';
$module = '';
$method = '';
$link = commonModel::createMenuLink($menuItem);
if(is_array($menuItem->link))
{
if(isset($menuItem->link['subModule']))
{
$subModules = explode(',', $menuItem->link['subModule']);
if(in_array($currentModule, $subModules) and $float != 'right') $active = 'active';
}
if(isset($menuItem->link['alias'])) $alias = $menuItem->link['alias'];
if(isset($menuItem->link['target'])) $target = $menuItem->link['target'];
if(isset($menuItem->link['module'])) $module = $menuItem->link['module'];
if(isset($menuItem->link['method'])) $method = $menuItem->link['method'];
}
if($float != 'right' and $module == $currentModule and ($method == $currentMethod or strpos(",$alias,", ",$currentMethod,") !== false)) $active = 'active';
if($module == $currentModule and ($method == $currentMethod or strpos(",$alias,", ",$currentMethod,") !== false)) $active = 'active';
$menuItemHtml = "<li class='$float $active' data-id='$menuItem->name'>" . html::a($link, $menuItem->text, $target) . "</li>\n";
if($isMobile) $menuItemHtml = html::a($link, $menuItem->text, $target, "class='$active'") . "\n";
$menuItemHtml = "<li class='$class $active' data-id='$menuItem->name'>" . html::a($link, $menuItem->text, $target) . "</li>\n";
if($isMobile) $menuItemHtml = html::a($link, $menuItem->text, $target, "class='$class $active'") . "\n";
echo $menuItemHtml;
}
else
{
echo $isMobile ? $menuItem->text : "<li data-id='$menuItem->name'>$menuItem->text</li>\n";
echo $isMobile ? $menuItem->text : "<li class='$class $active' data-id='$menuItem->name'>$menuItem->text</li>\n";
}
}
echo $isMobile ? '' : "</ul>\n";
@@ -1290,7 +1288,7 @@ EOD;
if(!empty($app->user->admin)) return true;
if($module == 'todo' and ($method == 'create' or $method == 'batchcreate')) return true;
if($module == 'effort' and $method == 'batchcreate') return true;
if($module == 'effort' and ($method == 'batchcreate' or $method == 'createforobject')) return true;
// limited project
$limitedProject = false;
-1
View File
@@ -235,7 +235,6 @@ class company extends control
$this->view->pager = $pager;
$this->view->param = $param;
$this->view->dateGroups = $this->action->buildDateGroup($actions, $direction);
$this->view->allCount = $this->action->getCount('all');
$this->view->direction = $direction;
$this->display();
}
+11 -8
View File
@@ -13,15 +13,18 @@
<?php include '../../common/view/header.html.php';?>
<div id="mainMenu" class="clearfix">
<div class="btn-toolbar pull-left">
<?php
echo html::a(inlink('dynamic', "browseType=all"), "<span class='text'>{$lang->action->dynamic->all}<span> <span class='label label-light label-badge'>{$allCount}</span>", '', "class='btn btn-link " . ($browseType == 'all' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "browseType=today"), "<span class='text'>{$lang->action->dynamic->today}<span>", '', "class='btn btn-link " . ($browseType == 'today' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "browseType=yesterday"), "<span class='text'>{$lang->action->dynamic->yesterday}<span>", '', "class='btn btn-link " . ($browseType == 'yesterday' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "browseType=thisweek"), "<span class='text'>{$lang->action->dynamic->thisWeek}<span>", '', "class='btn btn-link " . ($browseType == 'thisweek' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "browseType=lastweek"), "<span class='text'>{$lang->action->dynamic->lastWeek}<span>", '', "class='btn btn-link " . ($browseType == 'lastweek' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "browseType=thismonth"), "<span class='text'>{$lang->action->dynamic->thisMonth}<span>", '', "class='btn btn-link " . ($browseType == 'thismonth' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "browseType=lastmonth"), "<span class='text'>{$lang->action->dynamic->lastMonth}<span>", '', "class='btn btn-link " . ($browseType == 'lastmonth' ? 'btn-active-text' : '') . "'");
<?php foreach($lang->action->periods as $period => $label):?>
<?php
$label = "<span class='text'>$label</span>";
$active = '';
if($period == $browseType)
{
$active = 'btn-active-text';
$label .= " <span class='label label-light label-badge'>{$pager->recTotal}</span>";
}
echo html::a(inlink('dynamic', "browseType=$period"), $label, '', "class='btn btn-link $active' id='{$period}'")
?>
<?php endforeach;?>
<div class="input-control space w-150px"><?php echo html::select('account', $users, $account, 'onchange=changeUser(this.value) class="form-control chosen"');?></div>
<div class="input-control space w-150px"><?php echo html::select('product', $products, $product, 'onchange=changeProduct(this.value) class="form-control chosen"');?></div>
<?php if($this->config->global->flow != 'onlyTest'):?>
+16 -18
View File
@@ -209,11 +209,12 @@ class customModel extends model
{
if(is_object($item)) $item = (array)$item;
$label = '';
$module = '';
$method = '';
$float = '';
$fixed = '';
$label = '';
$module = '';
$method = '';
$class = '';
$subModule = '';
$alias = '';
$link = (is_array($item) and isset($item['link'])) ? $item['link'] : $item;
/* The variable of item has not link and is not link then ignore it. */
@@ -235,31 +236,28 @@ class customModel extends model
{
$itemLink = array('module' => $module, 'method' => $method);
if(isset($link[3])) $itemLink['vars'] = $link[3];
if(is_array($item))
{
if(isset($item['subModule'])) $itemLink['subModule'] = $item['subModule'];
if(isset($item['alias'])) $itemLink['alias'] = $item['alias'];
if(isset($item['target'])) $itemLink['target'] = $item['target'];
}
if(is_array($item) and isset($item['target'])) $itemLink['target'] = $item['target'];
}
if(is_array($item))
{
if(isset($item['float'])) $float = $item['float'];
if(isset($item['fixed'])) $fixed = $item['fixed'];
if(isset($item['class'])) $class = $item['class'];
if(isset($item['subModule'])) $subModule = $item['subModule'];
if(isset($item['alias'])) $alias = $item['alias'];
}
$hidden = !$fixed && isset($customMenuMap[$name]) && isset($customMenuMap[$name]->hidden) && $customMenuMap[$name]->hidden;
$hidden = isset($customMenuMap[$name]) && isset($customMenuMap[$name]->hidden) && $customMenuMap[$name]->hidden;
if(strpos($name, 'QUERY') === 0 and !isset($customMenuMap[$name])) $hidden = true;
$menuItem = new stdclass();
$menuItem->name = $name;
$menuItem->link = $itemLink;
$menuItem->text = $label;
$menuItem->order = $fixed ? -1 : (isset($customMenuMap[$name]) && isset($customMenuMap[$name]->order) ? $customMenuMap[$name]->order : $order++);
if($float) $menuItem->float = $float;
if($fixed) $menuItem->fixed = $fixed;
if($hidden) $menuItem->hidden = $hidden;
$menuItem->order = (isset($customMenuMap[$name]) && isset($customMenuMap[$name]->order) ? $customMenuMap[$name]->order : $order++);
if($hidden) $menuItem->hidden = $hidden;
if($class) $menuItem->class = $class;
if($subModule)$menuItem->subModule = $subModule;
if($alias) $menuItem->alias = $alias;
if($isTutorialMode) $menuItem->tutorial = true;
/* Hidden menu by config in mobile. */
+2 -2
View File
@@ -106,8 +106,8 @@ $lang->extension->errorPackageFileExists = '下載路徑已經有一個名
$lang->extension->errorDownloadFailed = '下載失敗,請重新下載。如果多次重試還不行,請嘗試手工下載,然後通過上傳功能上傳。';
$lang->extension->errorMd5Checking = '下載檔案不完整,請重新下載。如果多次重試還不行,請嘗試手工下載,然後通過上傳功能上傳。';
$lang->extension->errorExtracted = '包檔案<strong> %s </strong>解壓縮失敗,可能不是一個有效的zip檔案。錯誤信息如下:<br />%s';
$lang->extension->errorCheckIncompatible = '該插件與禪道版本不兼容,%s後可能無法使用。<h3>您可以選擇 <a href="%s">強制%s</a> 或者 <a href="#" onclick=parent.location.href="%s">取消</a></h3>';
$lang->extension->errorFileConflicted = '有以下檔案衝突:<br />%s <h3>您可以選擇 <a href="%s">覆蓋</a> 或者 <a href="#" onclick=parent.location.href="%s">取消</a></h3>';
$lang->extension->errorCheckIncompatible = '該插件與禪道版本不兼容,%s後可能無法使用。<h5>您可以選擇 <a href="%s" class="btn btn-sm">強制%s</a> 或者 <a href="#" onclick=parent.location.href="%s" class="btn btn-sm">取消</a></h5>';
$lang->extension->errorFileConflicted = '有以下檔案衝突:<br />%s <h5>您可以選擇 <a href="%s" class="btn btn-sm">覆蓋</a> 或者 <a href="#" onclick=parent.location.href="%s" class="btn btn-sm">取消</a></h5>';
$lang->extension->errorPackageNotFound = '包檔案 <strong>%s </strong>沒有找到,可能是因為自動下載失敗。您可以嘗試再次下載。';
$lang->extension->errorTargetPathNotWritable = '目標路徑 <strong>%s </strong>不可寫。';
$lang->extension->errorTargetPathNotExists = '目標路徑 <strong>%s </strong>不存在。';
+4 -1
View File
@@ -8,6 +8,9 @@ $sessionString .= session_name() . '=' . session_id();
<div class="detail-title"><?php echo $lang->file->common;?> <i class="icon icon-paper-clip icon-sm"></i></div>
<div class="detail-content">
<?php endif;?>
<style>
.files-list>li>a {display: inline;}
</style>
<script language='Javascript'>
$(function(){
$(".edit").modalTrigger({width:350, type:'iframe'});
@@ -80,7 +83,7 @@ $sessionString .= session_name() . '=' . session_id();
echo "<span class='right-icon'>";
common::printLink('file', 'edit', "fileID=$file->id", "<i class='icon-pencil'></i>", '', "class='edit btn-icon' title='{$lang->file->edit}'");
if(common::hasPriv('file', 'delete')) echo html::a('###', "<i class='icon-remove'></i>", '', "class='btn-icon' onclick='deleteFile($file->id)' title='$lang->delete'");
if(common::hasPriv('file', 'delete')) echo html::a('###', "<i class='icon-sm icon-close'></i>", '', "class='btn-icon' onclick='deleteFile($file->id)' title='$lang->delete'");
echo '</span>';
echo '</li>';
}
-2
View File
@@ -104,7 +104,6 @@ class my extends control
/* Assign. */
$this->view->todos = $this->loadModel('todo')->getList($type, $account, $status, 0, $pager, $sort);
$this->view->todoCount = $this->todo->getCount();
$this->view->date = (int)$type == 0 ? date(DT_DATE1) : date(DT_DATE1, strtotime($type));
$this->view->type = $type;
$this->view->recTotal = $recTotal;
@@ -568,7 +567,6 @@ class my extends control
$this->view->orderBy = $orderBy;
$this->view->pager = $pager;
$this->view->dateGroups = $this->action->buildDateGroup($actions, $direction);
$this->view->allCount = $this->action->getCount();
$this->view->direction = $direction;
$this->display();
}
+10 -7
View File
@@ -13,15 +13,18 @@
<?php include '../../common/view/header.html.php';?>
<div id="mainMenu" class="clearfix">
<div class="btn-toolbar pull-left">
<?php foreach($lang->action->periods as $period => $label):?>
<?php
echo html::a(inlink('dynamic', "type=all"), "<span class='text'>{$lang->action->dynamic->all}</span> <span class='label label-light label-badge'>{$allCount}</span>", '', "class='btn btn-link " . ($type == 'all' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "type=today"), "<span class='text'>{$lang->action->dynamic->today}</span>", '', "class='btn btn-link " . ($type == 'today' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "type=yesterday"), "<span class='text'>{$lang->action->dynamic->yesterday}</span>", '', "class='btn btn-link " . ($type == 'yesterday' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "type=thisweek"), "<span class='text'>{$lang->action->dynamic->thisWeek}</span>", '', "class='btn btn-link " . ($type == 'thisweek' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "type=lastweek"), "<span class='text'>{$lang->action->dynamic->lastWeek}</span>", '', "class='btn btn-link " . ($type == 'lastweek' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "type=thismonth"), "<span class='text'>{$lang->action->dynamic->thisMonth}</span>", '', "class='btn btn-link " . ($type == 'thismonth' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "type=lastmonth"), "<span class='text'>{$lang->action->dynamic->lastMonth}</span>", '', "class='btn btn-link " . ($type == 'lastmonth' ? 'btn-active-text' : '') . "'");
$label = "<span class='text'>$label</span>";
$active = '';
if($period == $type)
{
$active = 'btn-active-text';
$label .= " <span class='label label-light label-badge'>{$pager->recTotal}</span>";
}
echo html::a(inlink('dynamic', "type=$period"), $label, '', "class='btn btn-link $active' id='{$period}'")
?>
<?php endforeach;?>
</div>
</div>
<div id="mainContent" class="main-content">
+7 -2
View File
@@ -19,8 +19,13 @@
<?php
$vars = "date=$period";
if($period == 'before') $vars .= "&account={$app->user->account}&status=undone";
$label = $period == 'all' ? "<span class='text'>$label</span> <span class='label label-light label-badge'>{$todoCount}</span>" : "<span class='text'>$label</span>";
$active = $period == $type ? 'btn-active-text' : '';
$label = "<span class='text'>$label</span>";
$active = '';
if($period == $type)
{
$active = 'btn-active-text';
$label .= " <span class='label label-light label-badge'>{$pager->recTotal}</span>";
}
echo html::a(inlink('todo', $vars), $label, '', "class='btn btn-link $active' id='{$period}'")
?>
<?php endforeach;?>
-2
View File
@@ -204,7 +204,6 @@ class product extends control
$this->view->storyCases = $storyCases;
$this->view->param = $param;
$this->view->products = $this->products;
$this->view->allCount = $this->story->getCount($productID);
$this->display();
}
@@ -516,7 +515,6 @@ class product extends control
$this->view->param = $param;
$this->view->pager = $pager;
$this->view->dateGroups = $this->action->buildDateGroup($actions, $direction);
$this->view->allCount = $this->action->getCount('product', $productID);
$this->view->direction = $direction;
$this->display();
}
+2 -1
View File
@@ -75,6 +75,7 @@ $lang->product->release = '發佈';
$lang->product->latestDynamic = '最新動態';
$lang->product->iteration = '版本迭代';
$lang->product->iterationInfo = '迭代 %s 次';
$lang->product->iterationView = '查看詳情';
$lang->product->searchStory = '搜索';
$lang->product->assignedToMe = '指給我';
@@ -116,7 +117,7 @@ $lang->product->aclList['custom'] = '自定義白名單(團隊成員和白名
$lang->product->storySummary = "本頁共 <strong>%s</strong> 個需求,預計 <strong>%s</strong> 個工時,用例覆蓋率<strong>%s</strong>。";
$lang->product->checkedSummary = "選中 <strong>%total%</strong> 個需求,預計 <strong>%estimate%</strong> 個工時,用例覆蓋率<strong>%rate%</strong>。";
$lang->product->noModule = '您現在還沒有模組信息<br/>請維護產品模組';
$lang->product->noModule = '<div>您現在還沒有模組信息</div><div>請維護產品模組</div>';
$lang->product->noProduct = '暫時沒有產品,您現在可以';
$lang->product->noStory = '暫時沒有需求,您現在可以';
$lang->product->noMatched = '找不到包含"%s"的' . $lang->productCommon;
+1 -1
View File
@@ -47,7 +47,7 @@
echo '</ul></div>';
?>
<?php else:?>
<?php echo html::a($this->inlink('browse', "productID=$productID&branch=$branch&browseType=$menuBrowseType" . $queryParam), "<span class='text'>$menuItem->text</span>" . ($menuItem->name == 'allstory' ? ' <span class="label label-light label-badge">' . $allCount . '</span>' : ''), '', "id='{$menuItem->name}Tab' class='btn btn-link" . ($this->session->storyBrowseType == $menuItem->name ? ' btn-active-text' : '') . "'");?>
<?php echo html::a($this->inlink('browse', "productID=$productID&branch=$branch&browseType=$menuBrowseType" . $queryParam), "<span class='text'>$menuItem->text</span>" . ($menuItem->name == $this->session->storyBrowseType ? ' <span class="label label-light label-badge">' . $pager->recTotal . '</span>' : ''), '', "id='{$menuItem->name}Tab' class='btn btn-link" . ($this->session->storyBrowseType == $menuItem->name ? ' btn-active-text' : '') . "'");?>
<?php endif;?>
<?php endforeach;?>
<a class="btn btn-link querybox-toggle" id='bysearchTab'><i class="icon icon-search muted"></i> <?php echo $lang->product->searchStory;?></a>
+10 -7
View File
@@ -13,15 +13,18 @@
<?php include '../../common/view/header.html.php';?>
<div id="mainMenu" class="clearfix">
<div class="btn-toolbar pull-left">
<?php foreach($lang->action->periods as $period => $label):?>
<?php
echo html::a(inlink('dynamic', "productID=$productID&type=all"), "<span class='text'>{$lang->action->dynamic->all}</span> <span class='label label-light label-badge'>{$allCount}</span>", '', "class='btn btn-link " . ($type == 'all' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "productID=$productID&type=today"), "<span class='text'>{$lang->action->dynamic->today}</span>", '', "class='btn btn-link " . ($type == 'today' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "productID=$productID&type=yesterday"), "<span class='text'>{$lang->action->dynamic->yesterday}</span>", '', "class='btn btn-link " . ($type == 'yesterday' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "productID=$productID&type=thisweek"), "<span class='text'>{$lang->action->dynamic->thisWeek}</span>", '', "class='btn btn-link " . ($type == 'thisweek' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "productID=$productID&type=lastweek"), "<span class='text'>{$lang->action->dynamic->lastWeek}</span>", '', "class='btn btn-link " . ($type == 'lastweek' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "productID=$productID&type=thismonth"), "<span class='text'>{$lang->action->dynamic->thisMonth}</span>", '', "class='btn btn-link " . ($type == 'thismonth' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "productID=$productID&type=lastmonth"), "<span class='text'>{$lang->action->dynamic->lastMonth}</span>", '', "class='btn btn-link " . ($type == 'lastmonth' ? 'btn-active-text' : '') . "'");
$label = "<span class='text'>$label</span>";
$active = '';
if($period == $type)
{
$active = 'btn-active-text';
$label .= " <span class='label label-light label-badge'>{$pager->recTotal}</span>";
}
echo html::a(inlink('dynamic', "productID=$productID&type=$period"), $label, '', "class='btn btn-link $active' id='{$period}'")
?>
<?php endforeach;?>
<div class="input-control space w-150px">
<?php echo html::select('account', $users, $account, "onchange='changeUser(this.value, $productID)' class='form-control chosen'");?>
</div>
+2 -2
View File
@@ -8,7 +8,6 @@
.hide-side .col-side .main-side {width: 0; display: none;}
#unlinkBugList, #unlinkStoryList{margin-bottom:5px;}
input[type=checkbox].ml-10px{margin-left:10px;}
.dropdown-menu.with-search {padding: 0; min-width: 150px; overflow: hidden; max-height: 302px;}
.dropdown-menu > .menu-search .input-group {width:100%;}
@@ -22,7 +21,8 @@ input[type=checkbox].ml-10px{margin-left:10px;}
.checkbox.btn{margin-top:0px}
#unlinkStoryList, #unlinkBugList{border:1px solid #ddd;}
.table-footer .text{line-height:30px;}
.table-footer .text {line-height: 30px;}
.table-footer .table-actions {margin-right: 10px;}
#planInfo > div {padding-top: 15px;}
+2 -1
View File
@@ -9,7 +9,8 @@ function showLink(planID, type, orderBy, param)
var formID = type == 'story' ? '#unlinkedStoriesForm' : '#unlinkedBugsForm';
setTimeout(function(){fixedTfootAction(formID)}, 100);
checkTable($(formID).find('table'));
$('[data-ride="table"]').table();
});
}
$(function()
+1 -1
View File
@@ -17,7 +17,7 @@ $lang->productplan->edit = "Edit";
$lang->productplan->delete = "Delete";
$lang->productplan->view = "Details";
$lang->productplan->bugSummary = "<strong>%s</strong> Bugs in total on this page.";
$lang->productplan->info = 'Info';
$lang->productplan->basicInfo = 'Basic Info';
$lang->productplan->batchEdit = 'Batch Edit';
$lang->productplan->batchUnlink = "Batch Unlink";
+1 -1
View File
@@ -17,7 +17,7 @@ $lang->productplan->edit = "编辑计划";
$lang->productplan->delete = "删除计划";
$lang->productplan->view = "计划详情";
$lang->productplan->bugSummary = "本页共 <strong>%s</strong> 个Bug";
$lang->productplan->info = '信息';
$lang->productplan->basicInfo = '基本信息';
$lang->productplan->batchEdit = '批量编辑';
$lang->productplan->batchUnlink = "批量移除";
+1 -1
View File
@@ -17,7 +17,7 @@ $lang->productplan->edit = "編輯計劃";
$lang->productplan->delete = "刪除計劃";
$lang->productplan->view = "計劃詳情";
$lang->productplan->bugSummary = "本頁共 <strong>%s</strong> 個Bug";
$lang->productplan->info = '信息';
$lang->productplan->basicInfo = '基本信息';
$lang->productplan->batchEdit = '批量編輯';
$lang->productplan->batchUnlink = "批量移除";
+2 -2
View File
@@ -32,7 +32,7 @@
<table class='table has-sort-head' id="productplanList">
<thead>
<?php $vars = "productID=$productID&branch=$branch&browseType=$browseType&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}"; ?>
<tr class='colhead'>
<tr>
<th class='c-id'>
<?php if(common::hasPriv('productplan', 'batchEdit')):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
@@ -104,7 +104,7 @@
<?php if(common::hasPriv('productplan', 'batchEdit')):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->edit);?>
<?php echo html::submitButton($lang->edit, '', 'btn');?>
</div>
<?php endif;?>
<?php $pager->show('right', 'pagerjs');?>
+42 -39
View File
@@ -18,49 +18,52 @@
</div>
<table class='table'>
<thead>
<tr>
<th class='c-id text-center'><?php echo $lang->idAB;?></th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th><?php echo $lang->bug->title;?></th>
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-user'><?php echo $lang->bug->assignedToAB;?></th>
<th class='w-80px'><?php echo $lang->bug->status;?></th>
</tr>
<tr>
<th class='c-id'>
<?php if($allBugs):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php echo $lang->idAB;?>
</th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th><?php echo $lang->bug->title;?></th>
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-user'><?php echo $lang->bug->assignedToAB;?></th>
<th class='w-80px'><?php echo $lang->bug->status;?></th>
</tr>
</thead>
<tbody>
<?php $unlinkedCount = 0;?>
<?php foreach($allBugs as $bug):?>
<?php
if(isset($planBugs[$bug->id])) continue;
if($bug->plan and helper::diffDate($plans[$bug->plan], helper::today()) > 0) continue;
?>
<tr>
<td class='c-id'>
<input class='ml-10px' type='checkbox' name='bugs[]' value='<?php echo $bug->id;?>'/>
<?php printf('%03d', $bug->id);?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bug->pri, $bug->pri);?>'><?php echo zget($lang->bug->priList, $bug->pri, $bug->pri)?></span></td>
<td class='nobr' title='<?php echo $bug->title?>'><?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id", '', true), $bug->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo $users[$bug->assignedTo];?></td>
<td class='text-center bug-<?php echo $bug->status?>'><?php echo $lang->bug->statusList[$bug->status];?></td>
</tr>
<?php $unlinkedCount++;?>
<?php endforeach;?>
<?php $unlinkedCount = 0;?>
<?php foreach($allBugs as $bug):?>
<?php
if(isset($planBugs[$bug->id])) continue;
if($bug->plan and helper::diffDate($plans[$bug->plan], helper::today()) > 0) continue;
?>
<tr>
<td class='cell-id'>
<?php echo html::checkbox('bugs', array($bug->id => sprintf('%03d', $bug->id)));?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bug->pri, $bug->pri);?>'><?php echo zget($lang->bug->priList, $bug->pri, $bug->pri)?></span></td>
<td class='nobr' title='<?php echo $bug->title?>'><?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id", '', true), $bug->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo $users[$bug->assignedTo];?></td>
<td class='text-center bug-<?php echo $bug->status?>'><?php echo $lang->bug->statusList[$bug->status];?></td>
</tr>
<?php $unlinkedCount++;?>
<?php endforeach;?>
</tbody>
<?php if($unlinkedCount):?>
<tfoot>
<tr>
<td colspan='6' class='text-left table-footer'>
<div class='clearfix'>
<?php echo html::selectButton() . html::submitButton($lang->productplan->linkBug);?>
<?php echo html::a(inlink('view', "planID=$plan->id&type=bug&orderBy=$orderBy"), $lang->goback, '', "class='btn'");?>
</div>
</td>
</tr>
</tfoot>
<?php endif;?>
</table>
<div class='table-footer'>
<?php if($unlinkedCount):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->productplan->linkBug);?>
</div>
<?php endif;?>
<?php echo html::a(inlink('view', "planID=$plan->id&type=bug&orderBy=$orderBy"), $lang->goback, '', "class='btn'");?>
</div>
</form>
</div>
<script>
+34 -31
View File
@@ -19,7 +19,14 @@
<table class='table'>
<thead>
<tr>
<th class='c-id text-center'><?php echo $lang->idAB;?></th>
<th class='c-id'>
<?php if($allStories):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php echo $lang->idAB;?>
</th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th class='w-200px'><?php echo $lang->story->plan;?></th>
<th class='w-150px'><?php echo $lang->story->module;?></th>
@@ -32,40 +39,36 @@
</tr>
</thead>
<tbody>
<?php $unlinkedCount = 0;?>
<?php foreach($allStories as $story):?>
<?php if(isset($planStories[$story->id])) continue;?>
<tr>
<td class='c-id'>
<input class='ml-10px' type='checkbox' name='stories[]' value='<?php echo $story->id;?>'/>
<?php printf('%03d', $story->id);?>
</td>
<td><span class='label-pri <?php echo 'label-pri-' . $story->pri;?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri)?></span></td>
<td><?php echo $story->planTitle;?></td>
<td title='<?php echo $modules[$story->module]?>'><?php echo $modules[$story->module];?></td>
<td class='nobr' title='<?php echo $story->title?>'><?php echo html::a($this->createLink('story', 'view', "storyID=$story->id", '', true), $story->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
<td><?php echo zget($users, $story->openedBy);?></td>
<td><?php echo zget($users, $story->assignedTo);?></td>
<td><?php echo $story->estimate;?></td>
<td><span class='status-<?php echo $story->status?>'><span class='label label-dot'></span> <?php echo $lang->story->statusList[$story->status];?></span></td>
<td class='text-center'><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
<?php $unlinkedCount++;?>
<?php endforeach;?>
</tbody>
<?php if($unlinkedCount):?>
<tfoot>
<?php $unlinkedCount = 0;?>
<?php foreach($allStories as $story):?>
<?php if(isset($planStories[$story->id])) continue;?>
<tr>
<td colspan='10' class='text-left'>
<div class='clearfix'>
<?php echo html::selectButton() . html::submitButton($lang->story->linkStory);?>
<?php echo html::a(inlink('view', "planID=$plan->id&type=story&orderBy=$orderBy"), $lang->goback, '', "class='btn'");?>
</div>
<td class='cell-id'>
<?php echo html::checkbox('stories', array($story->id => sprintf('%03d', $story->id)));?>
</td>
<td><span class='label-pri <?php echo 'label-pri-' . $story->pri;?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri)?></span></td>
<td><?php echo $story->planTitle;?></td>
<td title='<?php echo $modules[$story->module]?>'><?php echo $modules[$story->module];?></td>
<td class='nobr' title='<?php echo $story->title?>'><?php echo html::a($this->createLink('story', 'view', "storyID=$story->id", '', true), $story->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
<td><?php echo zget($users, $story->openedBy);?></td>
<td><?php echo zget($users, $story->assignedTo);?></td>
<td><?php echo $story->estimate;?></td>
<td><span class='status-<?php echo $story->status?>'><span class='label label-dot'></span> <?php echo $lang->story->statusList[$story->status];?></span></td>
<td class='text-center'><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
</tfoot>
<?php endif;?>
<?php $unlinkedCount++;?>
<?php endforeach;?>
</tbody>
</table>
<div class='table-footer'>
<?php if($unlinkedCount):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->productplan->linkStory);?>
</div>
<?php endif;?>
<?php echo html::a(inlink('view', "planID=$plan->id&type=story&orderBy=$orderBy"), $lang->goback, '', "class='btn'");?>
</div>
</form>
</div>
<script>
+374 -379
View File
@@ -17,6 +17,9 @@
<div id='mainMenu' class='clearfix'>
<div class='btn-toolbar pull-left'>
<div class='page-title'>
<?php $browseLink = $this->session->productPlanList ? $this->session->productPlanList : inlink('browse', "planID=$plan->id");?>
<?php common::printBack($browseLink, 'btn btn-link');?>
<div class='divider'></div>
<span class='label label-id'><?php echo $plan->id;?></span>
<?php echo $plan->title;?>
<?php if($plan->deleted):?>
@@ -26,7 +29,6 @@
</div>
<div class='btn-toolbar pull-right'>
<?php
$browseLink = $this->session->productPlanList ? $this->session->productPlanList : inlink('browse', "planID=$plan->id");
if(!$plan->deleted)
{
echo "<div class='btn-group' id='createActionMenu'>";
@@ -47,389 +49,382 @@
common::printIcon('productplan', 'edit', "planID=$plan->id", $plan);
common::printIcon('productplan', 'delete', "planID=$plan->id", $plan, 'button', '', 'hiddenwin');
}
common::printBack($browseLink, 'btn btn-link');
?>
</div>
</div>
<div id='mainContent' class='main-content'>
<div class='main-col'>
<div class='main'>
<div class='tabs'>
<?php $countStories = count($planStories); $countBugs = count($planBugs);?>
<ul class='nav nav-tabs'>
<li class='<?php if($type == 'story') echo 'active'?>'><a href='#stories' data-toggle='tab'><?php echo html::icon($lang->icons['story']) . ' ' . $lang->productplan->linkedStories;?></a></li>
<?php if($config->global->flow != 'onlyStory'):?>
<li class='<?php if($type == 'bug') echo 'active'?>'><a href='#bugs' data-toggle='tab'><?php echo html::icon($lang->icons['bug']) . ' ' . $lang->productplan->linkedBugs;?></a></li>
<?php endif;?>
<li><a href='#planInfo' data-toggle='tab'><?php echo html::icon($lang->icons['plan']) . ' ' . $lang->productplan->view;?></a></li>
</ul>
<div class='tab-content'>
<div id='stories' class='tab-pane <?php if($type == 'story') echo 'active'?>'>
<?php if(common::hasPriv('productplan', 'linkStory')):?>
<?php $canOrder = common::hasPriv('project', 'storySort');?>
<div class='action'>
<?php echo html::a("javascript:showLink($plan->id, \"story\")", '<i class="icon-link"></i> ' . $lang->productplan->linkStory, '', "class='btn btn-sm btn-primary'");?>
</div>
<div class='linkBox'></div>
<?php endif;?>
<form class='main-table table-story' data-ride='table' method='post' target='hiddenwin' action="<?php echo inlink('batchUnlinkStory', "planID=$plan->id&orderBy=$orderBy");?>">
<table class='table has-sort-head' id='storyList'>
<?php $canBatchUnlink = common::hasPriv('productplan', 'batchUnlinkStory');?>
<?php $vars = "planID={$plan->id}&type=story&orderBy=%s&link=$link&param=$param"; ?>
<thead>
<tr>
<th class='c-id'>
<?php if($canBatchUnlink):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
</th>
<?php if($canOrder):?>
<th class='w-70px'><?php common::printOrderLink('order', $orderBy, $vars, $lang->productplan->updateOrder);?></th>
<?php endif;?>
<th class='w-pri'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th class='w-150px'><?php common::printOrderLink('module', $orderBy, $vars, $lang->story->module);?></th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->story->title);?></th>
<th class='w-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-user'> <?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->assignedToAB);?></th>
<th class='w-70px'> <?php common::printOrderLink('estimate', $orderBy, $vars, $lang->story->estimateAB);?></th>
<th class='w-70px'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->statusAB);?></th>
<th class='w-80px'> <?php common::printOrderLink('stage', $orderBy, $vars, $lang->story->stageAB);?></th>
<th class='w-50px'> <?php echo $lang->actions?></th>
</tr>
</thead>
<tbody class='sortable'>
<?php
$totalEstimate = 0.0;
$canBatchUnlink = common::hasPriv('productPlan', 'batchUnlinkStory');
$canBatchChangePlan = common::hasPriv('story', 'batchChangePlan');
?>
<?php foreach($planStories as $story):?>
<?php
$viewLink = $this->createLink('story', 'view', "storyID=$story->id");
$totalEstimate += $story->estimate;
?>
<tr data-id='<?php echo $story->id;?>'>
<td class='c-id'>
<div class="checkbox-primary">
<?php if($canBatchUnlink):?>
<input type='checkbox' name='storyIDList[]' value='<?php echo $story->id;?>'/>
<label></label>
<?php endif;?>
<?php echo sprintf('%03d', $story->id);?>
</div>
</td>
<?php if($canOrder):?><td class='sort-handler'><i class='icon-move'></i></td><?php endif;?>
<td><span class='label-pri <?php echo 'label-pri-' . $story->pri;?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri);?></span></td>
<td class='nobr'><?php echo zget($modulePairs, $story->module, '');?></td>
<td class='nobr' title='<?php echo $story->title?>'><?php echo html::a($viewLink , $story->title);?></td>
<td><?php echo zget($users, $story->openedBy);?></td>
<td><?php echo zget($users, $story->assignedTo);?></td>
<td><?php echo $story->estimate;?></td>
<td class='status-<?php echo $story->status?>'><span class='label label-dot'></span> <?php echo $lang->story->statusList[$story->status];?><span></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('productplan', 'unlinkStory'))
{
$unlinkURL = $this->createLink('productplan', 'unlinkStory', "story=$story->id&plan=$plan->id&confirm=yes");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"storyList\",confirmUnlinkStory)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->productplan->unlinkStory}'");
}
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if($countStories && $canBatchUnlink):?>
<div class='table-footer'>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class='table-actions btn-toolbar'>
<?php
$disabled = $canBatchUnlink ? '' : "disabled='disabled'";
$actionLink = inlink('batchUnlinkStory', "planID=$plan->id&orderBy=$orderBy");
?>
<div class='btn-group dropup'>
<?php echo html::commonButton($lang->productplan->unlinkStory, ($canBatchUnlink ? '' : 'disabled') . "onclick=\"setFormAction('$actionLink', 'hiddenwin', this)\"");?>
<button type='button' class='btn dropdown-toggle' data-toggle='dropdown'><span class='caret'></span></button>
<ul class='dropdown-menu'>
<?php
$class = "class='disabled'";
$canBatchClose = common::hasPriv('story', 'batchClose');
$actionLink = $this->createLink('story', 'batchClose', "productID=$plan->product");
$misc = $canBatchClose ? "onclick=\"setFormAction('$actionLink', '', this)\"" : $class;
echo "<li>" . html::a('#', $lang->close, '', $misc) . "</li>";
$canBatchEdit = common::hasPriv('story', 'batchEdit');
$actionLink = $this->createLink('story', 'batchEdit', "productID=$plan->product&projectID=0&branch=$branch");
$misc = $canBatchEdit ? "onclick=\"setFormAction('$actionLink', '', this)\"" : $class;
echo "<li>" . html::a('#', $lang->edit, '', $misc) . "</li>";
if(common::hasPriv('story', 'batchReview'))
{
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->story->review, '', "id='reviewItem'");
echo "<ul class='dropdown-menu'>";
unset($lang->story->reviewResultList['']);
unset($lang->story->reviewResultList['revert']);
foreach($lang->story->reviewResultList as $key => $result)
{
$actionLink = $this->createLink('story', 'batchReview', "result=$key");
if($key == 'reject')
{
echo "<li class='dropdown-submenu'>";
echo html::a('#', $result, '', "id='rejectItem'");
echo "<ul class='dropdown-menu'>";
unset($lang->story->reasonList['']);
unset($lang->story->reasonList['subdivided']);
unset($lang->story->reasonList['duplicate']);
foreach($lang->story->reasonList as $key => $reason)
{
$actionLink = $this->createLink('story', 'batchReview', "result=reject&reason=$key");
echo "<li>";
echo html::a('#', $reason, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"");
echo "</li>";
}
echo '</ul></li>';
}
else
{
echo '<li>' . html::a('#', $result, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"") . '</li>';
}
}
echo '</ul></li>';
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->review, '', $class) . '</li>';
}
if(common::hasPriv('story', 'batchChangeBranch') and $this->session->currentProductType != 'normal')
{
$withSearch = count($branches) > 8;
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->product->branchName[$this->session->currentProductType], '', "id='branchItem'");
echo "<div class='dropdown-menu" . ($withSearch ? ' with-search':'') . "'>";
echo '<ul class="dropdown-list">';
foreach($branches as $branchID => $branchName)
{
$actionLink = $this->createLink('story', 'batchChangeBranch', "branchID=$branchID");
echo "<li class='option' data-key='$branchID'>" . html::a('#', $branchName, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin', this)\"") . "</li>";
}
echo '</ul>';
if($withSearch) echo "<div class='menu-search'><div class='input-group input-group-sm'><input type='text' class='form-control' placeholder=''><span class='input-group-addon'><i class='icon-search'></i></span></div></div>";
echo '</div></li>';
}
if(common::hasPriv('story', 'batchChangeModule'))
{
$withSearch = count($modules) > 8;
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->story->moduleAB, '', "id='moduleItem'");
echo "<div class='dropdown-menu" . ($withSearch ? ' with-search':'') . "'>";
echo '<ul class="dropdown-list">';
foreach($modules as $moduleId => $module)
{
$actionLink = $this->createLink('story', 'batchChangeModule', "moduleID=$moduleId");
echo "<li class='option' data-key='$moduleId'>" . html::a('#', $module, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"") . "</li>";
}
echo '</ul>';
if($withSearch) echo "<div class='menu-search'><div class='input-group input-group-sm'><input type='text' class='form-control' placeholder=''><span class='input-group-addon'><i class='icon-search'></i></span></div></div>";
echo '</div></li>';
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->moduleAB, '', $class) . '</li>';
}
if(common::hasPriv('story', 'batchChangePlan'))
{
unset($plans['']);
unset($plans[$plan->id]);
$plans = array(0 => $lang->null) + $plans;
$withSearch = count($plans) > 8;
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->story->planAB, '', "id='planItem'");
echo "<div class='dropdown-menu" . ($withSearch ? ' with-search':'') . "'>";
echo '<ul class="dropdown-list">';
foreach($plans as $planID => $planName)
{
$actionLink = $this->createLink('story', 'batchChangePlan', "planID=$planID&oldPlanID=$plan->id");
echo "<li class='option' data-key='$planID'>" . html::a('#', $planName, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"") . "</li>";
}
echo '</ul>';
if($withSearch) echo "<div class='menu-search'><div class='input-group input-group-sm'><input type='text' class='form-control' placeholder=''><span class='input-group-addon'><i class='icon-search'></i></span></div></div>";
echo '</div></li>';
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->planAB, '', $class) . '</li>';
}
if(common::hasPriv('story', 'batchChangeStage'))
{
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->story->stageAB, '', "id='stageItem'");
echo "<ul class='dropdown-menu'>";
$lang->story->stageList[''] = $lang->null;
foreach($lang->story->stageList as $key => $stage)
{
$actionLink = $this->createLink('story', 'batchChangeStage', "stage=$key");
echo "<li>" . html::a('#', $stage, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"") . "</li>";
}
echo '</ul></li>';
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->stageAB, '', $class) . '</li>';
}
if(common::hasPriv('story', 'batchAssignTo'))
{
$withSearch = count($users) > 10;
$actionLink = $this->createLink('story', 'batchAssignTo', "productID=$plan->product");
echo html::select('assignedTo', $users, '', 'class="hidden"');
echo "<li class='dropdown-submenu'>";
echo html::a('javascript::', $lang->story->assignedTo, '', 'id="assignItem"');
echo "<div class='dropdown-menu" . ($withSearch ? ' with-search':'') . "'>";
echo '<ul class="dropdown-list">';
foreach ($users as $key => $value)
{
if(empty($key) or $key == 'closed') continue;
echo "<li class='option' data-key='$key'>" . html::a("javascript:$(\".table-actions #assignedTo\").val(\"$key\");setFormAction(\"$actionLink\", false, \"#storyList\")", $value, '', '') . '</li>';
}
echo "</ul>";
if($withSearch) echo "<div class='menu-search'><div class='input-group input-group-sm'><input type='text' class='form-control' placeholder=''><span class='input-group-addon'><i class='icon-search'></i></span></div></div>";
echo "</div></li>";
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->assignedTo, '', $class) . '</li>';
}
?>
</ul>
</div>
</div>
<div class='text'><?php echo $summary;?></div>
</div>
<?php endif;?>
</form>
</div>
<div id='bugs' class='tab-pane <?php if($type == 'bug') echo 'active';?>'>
<?php if(common::hasPriv('productplan', 'linkBug')):?>
<div class='action'>
<?php echo html::a("javascript:showLink($plan->id, \"bug\")", '<i class="icon-bug"></i> ' . $lang->productplan->linkBug, '', "class='btn btn-sm btn-primary'");?>
</div>
<div class='linkBox'></div>
<?php endif;?>
<form class='main-table table-bug' data-ride='table' method='post' target='hiddenwin' action="<?php echo inLink('batchUnlinkBug', "planID=$plan->id&orderBy=$orderBy");?>">
<table class='table has-sort-head' id='bugList'>
<?php $canBatchUnlink = common::hasPriv('productplan', 'batchUnlinkBug');?>
<?php $vars = "planID={$plan->id}&type=bug&orderBy=%s&link=$link&param=$param"; ?>
<thead>
<tr>
<th class='c-id'>
<?php if($canBatchUnlink):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
</th>
<th class='w-80px'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<th class='w-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-user'> <?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->bug->assignedToAB);?></th>
<th class='w-100px'><?php common::printOrderLink('status', $orderBy, $vars, $lang->bug->status);?></th>
<th class='w-50px'> <?php echo $lang->actions?></th>
</tr>
</thead>
<tbody>
<?php foreach($planBugs as $bug):?>
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkBugs[]' value='<?php echo $bug->id;?>'/>
<label></label>
<?php endif;?>
<?php echo sprintf('%03d', $bug->id);?>
</div>
</td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bug->pri, $bug->pri)?>'><?php echo zget($lang->bug->priList, $bug->pri, $bug->pri);?></span></td>
<td class='nobr' title='<?php echo $bug->title?>'><?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id"), $bug->title);?></td>
<td><?php echo zget($users, $bug->openedBy);?></td>
<td><?php echo zget($users, $bug->assignedTo);?></td>
<td class='status-<?php echo $bug->status?>'><span class='label label-dot'></span> <?php echo $lang->bug->statusList[$bug->status];?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('productplan', 'unlinkBug'))
{
$unlinkURL = $this->createLink('productplan', 'unlinkBug', "story=$bug->id&confirm=yes");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"bugList\",confirmUnlinkBug)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->productplan->unlinkBug}'");
}
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if($countBugs && $canBatchUnlink):?>
<div class='table-footer'>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->productplan->batchUnlink);?>
</div>
<div class='text'><?php echo sprintf($lang->productplan->bugSummary, count($planBugs));?></div>
</div>
<?php endif;?>
</form>
</div>
<div id='planInfo' class='tab-pane'>
<div class="main-row">
<div class="main-col col-8">
<div class='cell'>
<div class='detail'>
<div class='detail-title'><?php echo $lang->productplan->info?></div>
<div class='detail-content'>
<table class='table table-data table-condensed table-borderless'>
<tr>
<th class='w-80px strong'><?php echo $lang->productplan->title;?></th>
<td><?php echo $plan->title;?></td>
</tr>
<?php if($product->type != 'normal'):?>
<tr>
<th><?php echo $lang->product->branch;?></th>
<td><?php echo $branches[$plan->branch];?></td>
</tr>
<?php endif;?>
<tr>
<th><?php echo $lang->productplan->begin;?></th>
<td><?php echo $plan->begin;?></td>
</tr>
<tr>
<th><?php echo $lang->productplan->end;?></th>
<td><?php echo $plan->end == '2030-01-01' ? $lang->productplan->future : $plan->end;?></td>
</tr>
<tr>
<th><?php echo $lang->productplan->desc;?></th>
<td><?php echo $plan->desc;?></td>
</tr>
</table>
</div>
</div>
</div>
<div class="detail">
<?php include '../../common/view/action.html.php';?>
</div>
</div>
</div>
</div>
<div class='tabs'>
<ul class='nav nav-tabs'>
<li class='<?php if($type == 'story') echo 'active'?>'><a href='#stories' data-toggle='tab'><?php echo html::icon($lang->icons['story']) . ' ' . $lang->productplan->linkedStories;?></a></li>
<?php if($config->global->flow != 'onlyStory'):?>
<li class='<?php if($type == 'bug') echo 'active'?>'><a href='#bugs' data-toggle='tab'><?php echo html::icon($lang->icons['bug']) . ' ' . $lang->productplan->linkedBugs;?></a></li>
<?php endif;?>
<li><a href='#planInfo' data-toggle='tab'><?php echo html::icon($lang->icons['plan']) . ' ' . $lang->productplan->view;?></a></li>
</ul>
<div class='tab-content'>
<div id='stories' class='tab-pane <?php if($type == 'story') echo 'active'?>'>
<?php if(common::hasPriv('productplan', 'linkStory')):?>
<?php $canOrder = common::hasPriv('project', 'storySort');?>
<div class='action'>
<?php echo html::a("javascript:showLink($plan->id, \"story\")", '<i class="icon-link"></i> ' . $lang->productplan->linkStory, '', "class='btn btn-sm btn-primary'");?>
</div>
<div class='linkBox'></div>
<?php endif;?>
<form class='main-table table-story' data-ride='table' method='post' target='hiddenwin' action="<?php echo inlink('batchUnlinkStory', "planID=$plan->id&orderBy=$orderBy");?>">
<table class='table has-sort-head' id='storyList'>
<?php
$canBatchUnlink = common::hasPriv('productPlan', 'batchUnlinkStory');
$canBatchClose = common::hasPriv('story', 'batchClose');
$canBatchEdit = common::hasPriv('story', 'batchEdit');
$canBatchReview = common::hasPriv('story', 'batchReview');
$canBatchChangeBranch = common::hasPriv('story', 'batchChangeBranch');
$canBatchChangeModule = common::hasPriv('story', 'batchChangeModule');
$canBatchChangePlan = common::hasPriv('story', 'batchChangePlan');
$canBatchChangeStage = common::hasPriv('story', 'batchChangeStage');
$canBatchAssignTo = common::hasPriv('story', 'batchAssignTo');
$canBatchAction = $canBatchUnlink or $canBatchClose or $canBatchEdit or $canBatchReview or $canBatchChangeBranch or $canBatchChangeModule or $canBatchChangePlan or $canBatchChangeStage or $canBatchAssignTo;
$vars = "planID={$plan->id}&type=story&orderBy=%s&link=$link&param=$param";
?>
<thead>
<tr>
<th class='c-id'>
<?php if($planStories && $canBatchAction):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
</th>
<?php if($canOrder):?>
<th class='w-70px'><?php common::printOrderLink('order', $orderBy, $vars, $lang->productplan->updateOrder);?></th>
<?php endif;?>
<th class='w-70px'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th class='w-150px'><?php common::printOrderLink('module', $orderBy, $vars, $lang->story->module);?></th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->story->title);?></th>
<th class='w-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-user'> <?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->assignedToAB);?></th>
<th class='w-70px'> <?php common::printOrderLink('estimate', $orderBy, $vars, $lang->story->estimateAB);?></th>
<th class='w-70px'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->statusAB);?></th>
<th class='w-80px'> <?php common::printOrderLink('stage', $orderBy, $vars, $lang->story->stageAB);?></th>
<th class='w-50px'> <?php echo $lang->actions?></th>
</tr>
</thead>
<tbody>
<?php
$totalEstimate = 0.0;
?>
<?php foreach($planStories as $story):?>
<?php
$viewLink = $this->createLink('story', 'view', "storyID=$story->id");
$totalEstimate += $story->estimate;
?>
<tr data-id='<?php echo $story->id;?>'>
<td class='cell-id'>
<?php if($canBatchAction):?>
<?php echo html::checkbox('storyIDList', array($story->id => sprintf('%03d', $story->id)));?>
<?php else:?>
<?php printf('%03d', $story->id);?>
<?php endif;?>
</td>
<?php if($canOrder):?><td class='sort-handler'><i class='icon-move'></i></td><?php endif;?>
<td><span class='label-pri <?php echo 'label-pri-' . $story->pri;?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri);?></span></td>
<td class='nobr'><?php echo zget($modulePairs, $story->module, '');?></td>
<td class='nobr' title='<?php echo $story->title?>'><?php echo html::a($viewLink , $story->title);?></td>
<td><?php echo zget($users, $story->openedBy);?></td>
<td><?php echo zget($users, $story->assignedTo);?></td>
<td><?php echo $story->estimate;?></td>
<td class='status-<?php echo $story->status?>'><span class='label label-dot'></span> <?php echo $lang->story->statusList[$story->status];?><span></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('productplan', 'unlinkStory'))
{
$unlinkURL = $this->createLink('productplan', 'unlinkStory', "story=$story->id&plan=$plan->id&confirm=yes");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"storyList\",confirmUnlinkStory)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->productplan->unlinkStory}'");
}
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if($planStories):?>
<div class='table-footer'>
<?php if($canBatchAction):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class='table-actions btn-toolbar'>
<?php $actionLink = inlink('batchUnlinkStory', "planID=$plan->id&orderBy=$orderBy");?>
<div class='btn-group dropup'>
<?php echo html::commonButton($lang->productplan->unlinkStory, ($canBatchUnlink ? '' : 'disabled') . "onclick=\"setFormAction('$actionLink', 'hiddenwin', this)\"");?>
<button type='button' class='btn dropdown-toggle' data-toggle='dropdown'><span class='caret'></span></button>
<ul class='dropdown-menu'>
<?php
$class = "class='disabled'";
$actionLink = $this->createLink('story', 'batchClose', "productID=$plan->product");
$misc = $canBatchClose ? "onclick=\"setFormAction('$actionLink', '', this)\"" : $class;
echo "<li>" . html::a('#', $lang->close, '', $misc) . "</li>";
$actionLink = $this->createLink('story', 'batchEdit', "productID=$plan->product&projectID=0&branch=$branch");
$misc = $canBatchEdit ? "onclick=\"setFormAction('$actionLink', '', this)\"" : $class;
echo "<li>" . html::a('#', $lang->edit, '', $misc) . "</li>";
if($canBatchReview)
{
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->story->review, '', "id='reviewItem'");
echo "<ul class='dropdown-menu'>";
unset($lang->story->reviewResultList['']);
unset($lang->story->reviewResultList['revert']);
foreach($lang->story->reviewResultList as $key => $result)
{
$actionLink = $this->createLink('story', 'batchReview', "result=$key");
if($key == 'reject')
{
echo "<li class='dropdown-submenu'>";
echo html::a('#', $result, '', "id='rejectItem'");
echo "<ul class='dropdown-menu'>";
unset($lang->story->reasonList['']);
unset($lang->story->reasonList['subdivided']);
unset($lang->story->reasonList['duplicate']);
foreach($lang->story->reasonList as $key => $reason)
{
$actionLink = $this->createLink('story', 'batchReview', "result=reject&reason=$key");
echo "<li>";
echo html::a('#', $reason, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"");
echo "</li>";
}
echo '</ul></li>';
}
else
{
echo '<li>' . html::a('#', $result, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"") . '</li>';
}
}
echo '</ul></li>';
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->review, '', $class) . '</li>';
}
if($canBatchChangeBranch and $this->session->currentProductType != 'normal')
{
$withSearch = count($branches) > 8;
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->product->branchName[$this->session->currentProductType], '', "id='branchItem'");
echo "<div class='dropdown-menu" . ($withSearch ? ' with-search':'') . "'>";
echo '<ul class="dropdown-list">';
foreach($branches as $branchID => $branchName)
{
$actionLink = $this->createLink('story', 'batchChangeBranch', "branchID=$branchID");
echo "<li class='option' data-key='$branchID'>" . html::a('#', $branchName, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin', this)\"") . "</li>";
}
echo '</ul>';
if($withSearch) echo "<div class='menu-search'><div class='input-group input-group-sm'><input type='text' class='form-control' placeholder=''><span class='input-group-addon'><i class='icon-search'></i></span></div></div>";
echo '</div></li>';
}
if($canBatchChangeModule)
{
$withSearch = count($modules) > 8;
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->story->moduleAB, '', "id='moduleItem'");
echo "<div class='dropdown-menu" . ($withSearch ? ' with-search':'') . "'>";
echo '<ul class="dropdown-list">';
foreach($modules as $moduleId => $module)
{
$actionLink = $this->createLink('story', 'batchChangeModule', "moduleID=$moduleId");
echo "<li class='option' data-key='$moduleId'>" . html::a('#', $module, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"") . "</li>";
}
echo '</ul>';
if($withSearch) echo "<div class='menu-search'><div class='input-group input-group-sm'><input type='text' class='form-control' placeholder=''><span class='input-group-addon'><i class='icon-search'></i></span></div></div>";
echo '</div></li>';
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->moduleAB, '', $class) . '</li>';
}
if($canBatchChangePlan)
{
unset($plans['']);
unset($plans[$plan->id]);
$plans = array(0 => $lang->null) + $plans;
$withSearch = count($plans) > 8;
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->story->planAB, '', "id='planItem'");
echo "<div class='dropdown-menu" . ($withSearch ? ' with-search':'') . "'>";
echo '<ul class="dropdown-list">';
foreach($plans as $planID => $planName)
{
$actionLink = $this->createLink('story', 'batchChangePlan', "planID=$planID&oldPlanID=$plan->id");
echo "<li class='option' data-key='$planID'>" . html::a('#', $planName, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"") . "</li>";
}
echo '</ul>';
if($withSearch) echo "<div class='menu-search'><div class='input-group input-group-sm'><input type='text' class='form-control' placeholder=''><span class='input-group-addon'><i class='icon-search'></i></span></div></div>";
echo '</div></li>';
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->planAB, '', $class) . '</li>';
}
if($canBatchChangeStage)
{
echo "<li class='dropdown-submenu'>";
echo html::a('javascript:;', $lang->story->stageAB, '', "id='stageItem'");
echo "<ul class='dropdown-menu'>";
$lang->story->stageList[''] = $lang->null;
foreach($lang->story->stageList as $key => $stage)
{
$actionLink = $this->createLink('story', 'batchChangeStage', "stage=$key");
echo "<li>" . html::a('#', $stage, '', "onclick=\"setFormAction('$actionLink','hiddenwin', this)\"") . "</li>";
}
echo '</ul></li>';
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->stageAB, '', $class) . '</li>';
}
if($canBatchAssignTo)
{
$withSearch = count($users) > 10;
$actionLink = $this->createLink('story', 'batchAssignTo', "productID=$plan->product");
echo html::select('assignedTo', $users, '', 'class="hidden"');
echo "<li class='dropdown-submenu'>";
echo html::a('javascript::', $lang->story->assignedTo, '', 'id="assignItem"');
echo "<div class='dropdown-menu" . ($withSearch ? ' with-search':'') . "'>";
echo '<ul class="dropdown-list">';
foreach ($users as $key => $value)
{
if(empty($key) or $key == 'closed') continue;
echo "<li class='option' data-key='$key'>" . html::a("javascript:$(\".table-actions #assignedTo\").val(\"$key\");setFormAction(\"$actionLink\", false, \"#storyList\")", $value, '', '') . '</li>';
}
echo "</ul>";
if($withSearch) echo "<div class='menu-search'><div class='input-group input-group-sm'><input type='text' class='form-control' placeholder=''><span class='input-group-addon'><i class='icon-search'></i></span></div></div>";
echo "</div></li>";
}
else
{
echo '<li>' . html::a('javascript:;', $lang->story->assignedTo, '', $class) . '</li>';
}
?>
</ul>
</div>
</div>
<?php endif;?>
<div class='text'><?php echo $summary;?></div>
</div>
<?php endif;?>
</form>
</div>
<div id='bugs' class='tab-pane <?php if($type == 'bug') echo 'active';?>'>
<?php if(common::hasPriv('productplan', 'linkBug')):?>
<div class='action'>
<?php echo html::a("javascript:showLink($plan->id, \"bug\")", '<i class="icon-bug"></i> ' . $lang->productplan->linkBug, '', "class='btn btn-sm btn-primary'");?>
</div>
<div class='linkBox'></div>
<?php endif;?>
<form class='main-table table-bug' data-ride='table' method='post' target='hiddenwin' action="<?php echo inLink('batchUnlinkBug', "planID=$plan->id&orderBy=$orderBy");?>">
<table class='table has-sort-head' id='bugList'>
<?php $canBatchUnlink = common::hasPriv('productplan', 'batchUnlinkBug');?>
<?php $vars = "planID={$plan->id}&type=bug&orderBy=%s&link=$link&param=$param"; ?>
<thead>
<tr>
<th class='c-id'>
<?php if($planBugs && $canBatchUnlink):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
</th>
<th class='w-70px'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<th class='w-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-user'> <?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->bug->assignedToAB);?></th>
<th class='w-100px'><?php common::printOrderLink('status', $orderBy, $vars, $lang->bug->status);?></th>
<th class='w-50px'> <?php echo $lang->actions?></th>
</tr>
</thead>
<tbody>
<?php foreach($planBugs as $bug):?>
<tr>
<td class='c-id'>
<?php if($canBatchUnlink):?>
<?php echo html::checkbox('unlinkBugs', array($bug->id => sprintf('%03d', $bug->id)));?>
<?php else:?>
<?php printf('%03d', $bug->id);?>
<?php endif;?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bug->pri, $bug->pri)?>'><?php echo zget($lang->bug->priList, $bug->pri, $bug->pri);?></span></td>
<td class='nobr' title='<?php echo $bug->title?>'><?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id"), $bug->title);?></td>
<td><?php echo zget($users, $bug->openedBy);?></td>
<td><?php echo zget($users, $bug->assignedTo);?></td>
<td class='status-<?php echo $bug->status?>'><span class='label label-dot'></span> <?php echo $lang->bug->statusList[$bug->status];?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('productplan', 'unlinkBug'))
{
$unlinkURL = $this->createLink('productplan', 'unlinkBug', "story=$bug->id&confirm=yes");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"bugList\",confirmUnlinkBug)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->productplan->unlinkBug}'");
}
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if($planBugs):?>
<div class='table-footer'>
<?php if($canBatchUnlink):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php echo html::submitButton($lang->productplan->batchUnlink);?>
</div>
<?php endif;?>
<div class='text'><?php echo sprintf($lang->productplan->bugSummary, count($planBugs));?></div>
</div>
<?php endif;?>
</form>
</div>
<div id='planInfo' class='tab-pane'>
<div class='cell'>
<div class='detail'>
<div class='detail-title'><?php echo $lang->productplan->basicInfo;?></div>
<div class='detail-content'>
<table class='table table-data table-condensed table-borderless'>
<tr>
<th class='w-80px strong'><?php echo $lang->productplan->title;?></th>
<td><?php echo $plan->title;?></td>
</tr>
<?php if($product->type != 'normal'):?>
<tr>
<th><?php echo $lang->product->branch;?></th>
<td><?php echo $branches[$plan->branch];?></td>
</tr>
<?php endif;?>
<tr>
<th><?php echo $lang->productplan->begin;?></th>
<td><?php echo $plan->begin;?></td>
</tr>
<tr>
<th><?php echo $lang->productplan->end;?></th>
<td><?php echo $plan->end == '2030-01-01' ? $lang->productplan->future : $plan->end;?></td>
</tr>
<tr>
<th><?php echo $lang->productplan->desc;?></th>
<td><?php echo $plan->desc;?></td>
</tr>
</table>
</div>
</div>
<?php include '../../common/view/action.html.php';?>
</div>
</div>
</div>
</div>
+1 -2
View File
@@ -94,7 +94,7 @@ class project extends control
$actions = $this->loadModel('action')->getList('project', $projectID);
/* Set menu. */
$this->project->setMenu($this->projects, $projectID, $extra);
$this->project->setMenu($this->projects, $projectID, $buildID = 0, $extra);
/* Assign. */
$this->view->projects = $this->projects;
@@ -1960,7 +1960,6 @@ class project extends control
$this->view->pager = $pager;
$this->view->param = $param;
$this->view->dateGroups = $this->action->buildDateGroup($actions, $direction);
$this->view->allCount = $this->action->getCount('project', $projectID);
$this->view->direction = $direction;
$this->display();
}
-4
View File
@@ -1,7 +1,3 @@
.container {max-width: 950px!important;}
.container .actions {margin-bottom: 10px; padding: 0}
.container .actions > .text {padding: 5px 5px 5px 15px; line-height: 20px}
.mw-220px {max-width: 220px!important}
#wrap h1{font-size:14px;}
#interval{margin-right:10px;}
.canvas-wrapper {padding: 15px; border: 1px solid #ddd;}
-4
View File
@@ -1,4 +0,0 @@
$(document).ready(function()
{
ajaxGetSearchForm();
});
+2
View File
@@ -147,6 +147,7 @@ $lang->project->storySort = '需求排序';
$lang->project->importPlanStory = '創建' . $lang->projectCommon . '成功!\n是否導入計劃關聯的相關需求?';
$lang->project->iteration = '版本迭代';
$lang->project->iterationInfo = '迭代%s次';
$lang->project->viewAll = '查看所有';
/* 分組瀏覽。*/
$lang->project->allTasks = '所有';
@@ -213,6 +214,7 @@ $lang->project->copyFromProject = "複製自{$lang->projectCommon} <strong>%s</s
$lang->project->cancelCopy = '取消複製';
$lang->project->byPeriod = '按時間段';
$lang->project->byUser = '按用戶';
$lang->project->noProject = '暫時沒有項目,您現在可以';
/* 交互提示。*/
$lang->project->confirmDelete = "您確定刪除{$lang->projectCommon}[%s]嗎?";
+39 -3
View File
@@ -78,9 +78,9 @@ class projectModel extends model
if($project and $project->type == 'ops')
{
unset($this->lang->project->menu->story);
unset($this->lang->project->menu->bug);
unset($this->lang->project->menu->build);
unset($this->lang->project->menu->testtask);
unset($this->lang->project->subMenu->qa->bug);
unset($this->lang->project->subMenu->qa->build);
unset($this->lang->project->subMenu->qa->testtask);
}
if($projects and !isset($projects[$projectID]) and !$this->checkPriv($project))
@@ -118,6 +118,42 @@ class projectModel extends model
foreach($this->lang->project->menu as $key => $menu)
{
$replace = $projectID;
/* Replace for dropdown submenu. */
if(isset($this->lang->project->subMenu->$key))
{
$dropTitle = '';
$hasActive = false;
$replace = "<ul class='dropdown-menu'>";
foreach($this->lang->project->subMenu->$key as $subMenuKey => $subMenuLink)
{
$subModule = '';
if(is_array($subMenuLink))
{
if(isset($subMenuLink['subModule'])) $subModule = $subMenuLink['subModule'];
$subMenuLink = $subMenuLink['link'];
}
list($subMenuName, $subMenuModule, $subMenuMethod, $subMenuParams) = explode('|', $subMenuLink);
if(!commonModel::hasPriv($subMenuModule, $subMenuMethod)) continue;
if(empty($dropTitle)) $dropTitle = $subMenuName;
$active = '';
if(($moduleName == $subMenuModule and $methodName == $subMenuMethod) or strpos(",$subModule,", ",$moduleName,") !== false)
{
$active = "class='active'";
$dropTitle = $subMenuName;
}
$replace .= "<li $active>" . html::a(helper::createLink($subMenuModule, $subMenuMethod, sprintf($subMenuParams, $projectID)), $subMenuName) . '</li>';
if($active) $hasActive = true;
}
$replace .= '</ul>';
$replace = "<a data-toggle='dropdown'>$dropTitle <span class='caret'></span></a>" . $replace;
$this->lang->project->menu->$key['class'] = 'dropdown';
if($hasActive) $this->lang->project->menu->$key['class'] .= ' active';
}
common::setMenuVars($this->lang->project->menu, $key, $replace);
}
}
+34 -28
View File
@@ -15,78 +15,83 @@
<div class="btn-toolbar pull-left">
<span class='btn btn-link btn-active-text'>
<span class='text'><?php echo html::icon($lang->icons['bug']);?> <?php echo $lang->project->bug;?></span>
<?php if($build) echo ' <span class="label label-danger">Build:' . $build->name . '</span>'; ?>
<span class="label label-light label-badge"><?php echo $pager->recTotal;?></span>
<?php if($build) echo ' <span class="label label-danger">Build:' . $build->name . '</span>';?>
</span>
<a class="btn btn-link querybox-toggle" id="bysearchTab"><i class="icon icon-search muted"></i> <?php echo $lang->bug->search;?></a>
</div>
<div class="btn-toolbar pull-right">
<?php common::printIcon('bug', 'export', "productID=$productID&orderBy=$orderBy", '', 'button', '', '', "export iframe");?>
<?php common::printIcon('bug', 'create', "productID=$productID&branch=$branchID&extra=projectID=$project->id");?>
<?php common::printLink('bug', 'export', "productID=$productID&orderBy=$orderBy", "<i class='icon icon-export'> </i>" . $lang->bug->export, '', "class='btn btn-link export iframe'");?>
<?php common::printLink('bug', 'create', "productID=$productID&branch=$branchID&extra=projectID=$project->id", "<i class='icon icon-plus'> </i>" . $lang->bug->create, '', "class='btn btn-primary'");?>
</div>
</div>
<div id="mainContent" class='main-content'>
<div id='queryBox' class='show'></div>
<div class="cell" id="queryBox"></div>
<form class='main-table' method='post' id='projectBugForm' data-ride="table">
<table class='table has-sort-head' id='bugList'>
<?php $canBatchAssignTo = common::hasPriv('bug', 'batchAssignTo');?>
<?php $vars = "projectID={$project->id}&orderBy=%s&build=$buildID&type=$type&param=$param&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}"; ?>
<thead>
<tr>
<?php $vars = "projectID={$project->id}&orderBy=%s&build=$buildID&type=$type&param=$param&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}"; ?>
<th class='c-id'>
<?php if($canBatchAssignTo):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
</th>
<th class='w-80px'> <?php common::printOrderLink('severity', $orderBy, $vars, $lang->bug->severityAB);?></th>
<th class='w-pri'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th class='c-pri'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<th class='w-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-user'> <?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->assignedToAB);?></th>
<th class='w-100px text-center'><?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->assignedToAB);?></th>
<th class='w-user'> <?php common::printOrderLink('resolvedBy', $orderBy, $vars, $lang->bug->resolvedBy);?></th>
<th class='w-resolution'><?php common::printOrderLink('resolution', $orderBy, $vars, $lang->bug->resolutionAB);?></th>
<th class='w-150px'><?php echo $lang->actions;?></th>
<th class='w-130px text-center'><?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($bugs as $bug):?>
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<input type='checkbox' name='bugIDList[]' value='<?php echo $bug->id;?>'/>
<label></label>
<?php printf('%03d', $bug->id);?>
</div>
<td class='cell-id'>
<?php if($canBatchAssignTo):?>
<?php echo html::checkbox('bugIDList', array($bug->id => sprintf('%03d', $bug->id)));?>
<?php else:?>
<?php printf('%03d', $bug->id);?>
<?php endif;?>
</td>
<td><span class='<?php echo 'severity' . zget($lang->bug->severityList, $bug->severity, $bug->severity)?>'><?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity)?></span></td>
<td><span class='label-pri <?php echo 'label-pri-' . $bug->pri?>'><?php echo zget($lang->bug->priList, $bug->pri, $bug->pri)?></span></td>
<td class='text-left' title="<?php echo $bug->title?>"><?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id"), $bug->title, null, "style='color: $bug->color'");?></td>
<td><?php echo zget($users, $bug->openedBy, $bug->openedBy);?></td>
<td><?php echo zget($users, $bug->assignedTo, $bug->assignedTo);?></td>
<td class='c-actions'>
<?php $params = "bugID=$bug->id";?>
<?php common::printIcon('bug', 'assignTo', $params, $bug, 'list', '', '', 'iframe', true);?>
<?php echo zget($users, $bug->assignedTo, $bug->assignedTo);?>
</td>
<td><?php echo zget($users, $bug->resolvedBy, $bug->resolvedBy);?></td>
<td><?php echo $lang->bug->resolutionList[$bug->resolution];?></td>
<td class='c-actions'>
<?php $params = "bugID=$bug->id";?>
<div class='more'>
<?php
common::printIcon('bug', 'confirmBug', $params, $bug, 'list', 'search', '', 'iframe', true);
common::printIcon('bug', 'create', "product=$bug->product&branch=$bug->branch&extra=bugID=$bug->id", $bug, 'list', 'copy');
?>
<?php if($bug->status == 'active') common::printIcon('bug', 'confirmBug', $params, $bug, 'list', 'search', '', 'iframe', true);?>
</div>
<?php
common::printIcon('bug', 'assignTo', $params, $bug, 'list', '', '', 'iframe', true);
common::printIcon('bug', 'resolve', $params, $bug, 'list', '', '', 'iframe', true);
common::printIcon('bug', 'close', $params, $bug, 'list', '', '', 'iframe', true);
common::printIcon('bug', 'edit', $params, $bug, 'list');
if($bug->status == 'active') common::printIcon('bug', 'resolve', $params, $bug, 'list', 'check', '', 'iframe', true);
if($bug->status != 'active') common::printIcon('bug', 'close', $params, $bug, 'list', '', '', 'iframe', true);
common::printIcon('bug', 'create', "product=$bug->product&branch=$bug->branch&extra=$params", $bug, 'list', 'copy');
common::printIcon('bug', 'edit', $params, $bug, 'list');
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if(count($bugs)):?>
<?php if($bugs):?>
<div class='table-footer'>
<?php if($canBatchAssignTo):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="table-actions btn-toolbar">
<?php if(common::hasPriv('bug', 'batchAssignTo')):?>
<div class="btn-group dropup">
<button data-toggle="dropdown" type="button" class="btn"><?php echo $lang->bug->assignedTo?> <span class="caret"></span></button>
<?php
@@ -111,12 +116,13 @@
echo "</div>";
?>
</div>
<?php endif;?>
</div>
<?php endif;?>
<?php $pager->show('right', 'pagerjs');?>
</div>
<?php endif;?>
</form>
</div>
<?php js::set('replaceID', 'bugList')?>
<?php js::set('replaceID', 'bugList');?>
<?php js::set('browseType', $type);?>
<?php include '../../common/view/footer.html.php';?>
+4 -1
View File
@@ -14,7 +14,10 @@
<?php js::set('confirmDelete', $lang->build->confirmDelete)?>
<div id="mainMenu" class="clearfix">
<div class="btn-toolbar pull-left">
<span class='btn btn-link btn-active-text'> <span class='text'><?php echo $lang->project->build;?></span></span>
<span class='btn btn-link btn-active-text'>
<span class='text'><?php echo $lang->project->build;?></span>
<span class='label label-light label-badge'><?php echo count($builds);?></span>
</span>
</div>
<div class="btn-toolbar pull-right">
<?php common::printLink('build', 'create', "project=$project->id", "<i class='icon icon-plus'> </i>" . $lang->build->create, '', "class='btn btn-primary'");?>
+11 -8
View File
@@ -13,15 +13,18 @@
<?php include '../../common/view/header.html.php';?>
<div id="mainMenu" class="clearfix">
<div class="btn-toolbar pull-left">
<?php
echo html::a(inlink('dynamic', "projectID=$projectID&type=all"), "<span class='text'>{$lang->action->dynamic->all}</span> <span class='label label-light label-badge'>{$allCount}</span>", '', "class='btn btn-link " . ($type == 'all' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "projectID=$projectID&type=today"), "<span class='text'>{$lang->action->dynamic->today}</span>", '', "class='btn btn-link " . ($type == 'today' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "projectID=$projectID&type=yesterday"), "<span class='text'>{$lang->action->dynamic->yesterday}</span>", '', "class='btn btn-link " . ($type == 'yesterday' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "projectID=$projectID&type=thisweek"), "<span class='text'>{$lang->action->dynamic->thisWeek}</span>", '', "class='btn btn-link " . ($type == 'thisweek' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "projectID=$projectID&type=lastweek"), "<span class='text'>{$lang->action->dynamic->lastWeek}</span>", '', "class='btn btn-link " . ($type == 'lastweek' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "projectID=$projectID&type=thismonth"), "<span class='text'>{$lang->action->dynamic->thisMonth}</span>", '', "class='btn btn-link " . ($type == 'thismonth' ? 'btn-active-text' : '') . "'");
echo html::a(inlink('dynamic', "projectID=$projectID&type=lastmonth"), "<span class='text'>{$lang->action->dynamic->lastMonth}</span>", '', "class='btn btn-link " . ($type == 'lastmonth' ? 'btn-active-text' : '') . "'");
<?php foreach($lang->action->periods as $period => $label):?>
<?php
$label = "<span class='text'>$label</span>";
$active = '';
if($period == $type)
{
$active = 'btn-active-text';
$label .= " <span class='label label-light label-badge'>{$pager->recTotal}</span>";
}
echo html::a(inlink('dynamic', "projectID=$projectID&type=$period"), $label, '', "class='btn btn-link $active' id='{$period}'")
?>
<?php endforeach;?>
<div class="input-control space w-150px">
<?php echo html::select('account', $users, $account, "onchange='changeUser(this.value, $projectID)' class='form-control chosen'");?>
</div>
+2 -1
View File
@@ -11,7 +11,8 @@ function showLink(releaseID, type, param)
var formID = type == 'story' ? '#unlinkedStoriesForm' : (type == 'leftBug' ? '#unlinkedLeftBugsForm' : '#unlinkedBugsForm');
setTimeout(function(){fixedTfootAction(formID)}, 100);
checkTable($(formID).find('table'));
$('[data-ride="table"]').table();
});
}
$(function()
+30 -30
View File
@@ -9,15 +9,15 @@
* @version $Id: en.php 4129 2013-01-18 01:58:14Z wwccss $
* @link http://www.zentao.net
*/
$lang->release->common = 'Release';
$lang->release->create = "Create";
$lang->release->edit = "Edit";
$lang->release->linkStory = "Link Story";
$lang->release->linkBug = "Link Bug";
$lang->release->delete = "Delete";
$lang->release->deleted = 'Deleted';
$lang->release->view = "Overview";
$lang->release->browse = "Browse";
$lang->release->common = 'Release';
$lang->release->create = "Create";
$lang->release->edit = "Edit";
$lang->release->linkStory = "Link Story";
$lang->release->linkBug = "Link Bug";
$lang->release->delete = "Delete";
$lang->release->deleted = 'Deleted';
$lang->release->view = "Overview";
$lang->release->browse = "Browse";
$lang->release->changeStatus = "Change Status";
$lang->release->batchUnlink = "Batch Unlink";
$lang->release->batchUnlinkStory = "Batch Unlink Story";
@@ -29,27 +29,27 @@ $lang->release->confirmUnlinkBug = "Do you want to remove this Bug?";
$lang->release->basicInfo = 'Basic Info';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = 'Platform/Branch';
$lang->release->build = 'Build';
$lang->release->name = 'Name';
$lang->release->marker = 'Marker';
$lang->release->date = 'Date';
$lang->release->desc = 'Description';
$lang->release->status = 'Status';
$lang->release->last = 'Last Release';
$lang->release->unlinkStory = 'Unlink Story';
$lang->release->unlinkBug = 'Unlink Bug';
$lang->release->stories = 'Finished Story';
$lang->release->bugs = 'Solved Bug';
$lang->release->leftBugs = 'Remained Bug';
$lang->release->generatedBugs = 'Remained Bug';
$lang->release->finishStories = 'Finished %s Story';
$lang->release->resolvedBugs = 'Solved %s Bug';
$lang->release->createdBugs = 'Generated %s Bug';
$lang->release->export = 'Export as HTML';
$lang->release->yesterday = 'Released Yesterday';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = 'Platform/Branch';
$lang->release->build = 'Build';
$lang->release->name = 'Name';
$lang->release->marker = 'Marker';
$lang->release->date = 'Date';
$lang->release->desc = 'Description';
$lang->release->status = 'Status';
$lang->release->last = 'Last Release';
$lang->release->unlinkStory = 'Unlink Story';
$lang->release->unlinkBug = 'Unlink Bug';
$lang->release->stories = 'Finished Story';
$lang->release->bugs = 'Solved Bug';
$lang->release->leftBugs = 'Remained Bug';
$lang->release->generatedBugs = 'Remained Bug';
$lang->release->finishStories = 'Finished %s Story';
$lang->release->resolvedBugs = 'Solved %s Bug';
$lang->release->createdBugs = 'Generated %s Bug';
$lang->release->export = 'Export as HTML';
$lang->release->yesterday = 'Released Yesterday';
$lang->release->filePath = 'Download : ';
$lang->release->scmPath = 'SCM Path : ';
+30 -30
View File
@@ -9,15 +9,15 @@
* @version $Id: zh-cn.php 4129 2013-01-18 01:58:14Z wwccss $
* @link http://www.zentao.net
*/
$lang->release->common = '发布';
$lang->release->create = "创建发布";
$lang->release->edit = "编辑发布";
$lang->release->linkStory = "关联需求";
$lang->release->linkBug = "关联Bug";
$lang->release->delete = "删除发布";
$lang->release->deleted = '已删除';
$lang->release->view = "发布详情";
$lang->release->browse = "浏览发布";
$lang->release->common = '发布';
$lang->release->create = "创建发布";
$lang->release->edit = "编辑发布";
$lang->release->linkStory = "关联需求";
$lang->release->linkBug = "关联Bug";
$lang->release->delete = "删除发布";
$lang->release->deleted = '已删除';
$lang->release->view = "发布详情";
$lang->release->browse = "浏览发布";
$lang->release->changeStatus = "修改状态";
$lang->release->batchUnlink = "批量移除";
$lang->release->batchUnlinkStory = "批量移除需求";
@@ -29,27 +29,27 @@ $lang->release->confirmUnlinkBug = "您确认移除该Bug吗?";
$lang->release->basicInfo = '基本信息';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = '平台/分支';
$lang->release->build = '版本';
$lang->release->name = '发布名称';
$lang->release->marker = '里程碑';
$lang->release->date = '发布日期';
$lang->release->desc = '描述';
$lang->release->status = '状态';
$lang->release->last = '上次发布';
$lang->release->unlinkStory = '移除需求';
$lang->release->unlinkBug = '移除Bug';
$lang->release->stories = '完成的需求';
$lang->release->bugs = '解决的Bug';
$lang->release->leftBugs = '遗留的Bug';
$lang->release->generatedBugs = '遗留的Bug';
$lang->release->finishStories = '本次共完成 %s 个需求';
$lang->release->resolvedBugs = '本次共解决 %s 个Bug';
$lang->release->createdBugs = '本次共遗留 %s 个Bug';
$lang->release->export = '导出HTML';
$lang->release->yesterday = '昨日发布';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = '平台/分支';
$lang->release->build = '版本';
$lang->release->name = '发布名称';
$lang->release->marker = '里程碑';
$lang->release->date = '发布日期';
$lang->release->desc = '描述';
$lang->release->status = '状态';
$lang->release->last = '上次发布';
$lang->release->unlinkStory = '移除需求';
$lang->release->unlinkBug = '移除Bug';
$lang->release->stories = '完成的需求';
$lang->release->bugs = '解决的Bug';
$lang->release->leftBugs = '遗留的Bug';
$lang->release->generatedBugs = '遗留的Bug';
$lang->release->finishStories = '本次共完成 %s 个需求';
$lang->release->resolvedBugs = '本次共解决 %s 个Bug';
$lang->release->createdBugs = '本次共遗留 %s 个Bug';
$lang->release->export = '导出HTML';
$lang->release->yesterday = '昨日发布';
$lang->release->filePath = '下载地址:';
$lang->release->scmPath = '版本库地址:';
+30 -29
View File
@@ -9,15 +9,15 @@
* @version $Id: zh-tw.php 4129 2013-01-18 01:58:14Z wwccss $
* @link http://www.zentao.net
*/
$lang->release->common = '發佈';
$lang->release->create = "創建發佈";
$lang->release->edit = "編輯發佈";
$lang->release->linkStory = "關聯需求";
$lang->release->linkBug = "關聯Bug";
$lang->release->delete = "刪除發佈";
$lang->release->deleted = '已刪除';
$lang->release->view = "發佈詳情";
$lang->release->browse = "瀏覽發佈";
$lang->release->common = '發佈';
$lang->release->create = "創建發佈";
$lang->release->edit = "編輯發佈";
$lang->release->linkStory = "關聯需求";
$lang->release->linkBug = "關聯Bug";
$lang->release->delete = "刪除發佈";
$lang->release->deleted = '已刪除';
$lang->release->view = "發佈詳情";
$lang->release->browse = "瀏覽發佈";
$lang->release->changeStatus = "修改狀態";
$lang->release->batchUnlink = "批量移除";
$lang->release->batchUnlinkStory = "批量移除需求";
@@ -29,26 +29,27 @@ $lang->release->confirmUnlinkBug = "您確認移除該Bug嗎?";
$lang->release->basicInfo = '基本信息';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = '平台/分支';
$lang->release->build = '版本';
$lang->release->name = '發佈名稱';
$lang->release->date = '發佈日期';
$lang->release->desc = '描述';
$lang->release->status = '狀態';
$lang->release->last = '上次發佈';
$lang->release->unlinkStory = '移除需求';
$lang->release->unlinkBug = '移除Bug';
$lang->release->stories = '完成的需求';
$lang->release->bugs = '解決的Bug';
$lang->release->leftBugs = '遺留的Bug';
$lang->release->generatedBugs = '遺留的Bug';
$lang->release->finishStories = '本次共完成 %s 個需求';
$lang->release->resolvedBugs = '本次共解決 %s 個Bug';
$lang->release->createdBugs = '本次共遺留 %s 個Bug';
$lang->release->export = '導出HTML';
$lang->release->yesterday = '昨日發佈';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = '平台/分支';
$lang->release->build = '版本';
$lang->release->name = '發佈名稱';
$lang->release->marker = '里程碑';
$lang->release->date = '發佈日期';
$lang->release->desc = '描述';
$lang->release->status = '狀態';
$lang->release->last = '上次發佈';
$lang->release->unlinkStory = '移除需求';
$lang->release->unlinkBug = '移除Bug';
$lang->release->stories = '完成的需求';
$lang->release->bugs = '解決的Bug';
$lang->release->leftBugs = '遺留的Bug';
$lang->release->generatedBugs = '遺留的Bug';
$lang->release->finishStories = '本次共完成 %s 個需求';
$lang->release->resolvedBugs = '本次共解決 %s 個Bug';
$lang->release->createdBugs = '本次共遺留 %s 個Bug';
$lang->release->export = '導出HTML';
$lang->release->yesterday = '昨日發佈';
$lang->release->filePath = '下載地址:';
$lang->release->scmPath = '版本庫地址:';
+22 -21
View File
@@ -16,19 +16,26 @@ $releaseBugs = $type == 'bug' ? $release->bugs : $release->leftBugs;
$formID = $type == 'leftBug' ? 'unlinkedLeftBugsForm' : 'unlinkedBugsForm';
?>
<div id='<?php echo $type == 'bug' ? 'unlinkBugList' : 'unlinkLeftBugList';?>'>
<form class='main-table' method='post' target='hiddenwin' id='<?php echo $formID?>' action='<?php echo $this->createLink('release', 'linkBug', "releaseID=$release->id&browseType=$browseType&param=$param&type=$type")?>'>
<form class='main-table' method='post' target='hiddenwin' id='<?php echo $formID?>' action='<?php echo $this->createLink('release', 'linkBug', "releaseID=$release->id&browseType=$browseType&param=$param&type=$type")?>' data-ride='table'>
<div class='table-header'>
<div class='table-statistic'><?php echo html::icon('unlink');?> &nbsp;<strong><?php echo $lang->productplan->unlinkedBugs;?></strong></div>
</div>
<table class='table'>
<thead>
<tr>
<th class='c-id'> <?php echo $lang->idAB;?></th>
<th class='c-id'>
<?php if($allBugs):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php echo $lang->idAB;?>
</th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th> <?php echo $lang->bug->title;?></th>
<th class='w-user text-left'> <?php echo $lang->openedByAB;?></th>
<th class='w-user'> <?php echo $lang->bug->resolvedBy;?></th>
<th class='w-80px'> <?php echo $lang->statusAB;?></th>
<th class='w-user text-left'><?php echo $lang->openedByAB;?></th>
<th class='w-user'><?php echo $lang->bug->resolvedBy;?></th>
<th class='w-80px'><?php echo $lang->statusAB;?></th>
</tr>
</thead>
<tbody>
@@ -37,8 +44,7 @@ $formID = $type == 'leftBug' ? 'unlinkedLeftBugsForm' : 'unlinkedBugsForm';
<?php if(strpos(",{$releaseBugs},", ",$bug->id,") !== false) continue;?>
<tr>
<td class='c-id'>
<input class='ml-10px' type='checkbox' name='bugs[<?php echo $bug->id?>]' value='<?php echo $bug->id;?>' <?php if($type == 'leftBug' or $bug->status == 'resolved' or $bug->status == 'closed') echo "checked";?> />
<?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id"), $bug->id);?>
<?php echo html::checkbox('bugs', array($bug->id => sprintf('%03d', $bug->id)), ($type == 'leftBug' or $bug->status == 'resolved' or $bug->status == 'closed') ? $bud->id : '');?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bug->pri, $bug->pri);?>'><?php echo zget($lang->bug->priList, $bug->pri, $bug->pri)?></span></td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($this->createLink('bug', 'view', "bugID=$bug->id", '', true), $bug->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
@@ -49,21 +55,16 @@ $formID = $type == 'leftBug' ? 'unlinkedLeftBugsForm' : 'unlinkedBugsForm';
<?php $unlinkedCount++;?>
<?php endforeach;?>
</tbody>
<?php if($unlinkedCount):?>
<tfoot>
<tr>
<td colspan='6' class='text-left table-footer'>
<div class='clearfix'>
<?php
echo html::selectButton() . html::submitButton($lang->release->linkBug);
echo html::a(inlink('view', "releaseID=$release->id&type=$type"), $lang->goback, '', "class='btn'");
?>
</div>
</td>
</tr>
</tfoot>
<?php endif;?>
</table>
<div class='table-footer'>
<?php if($unlinkedCount):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class="btn-toolbar">
<?php echo html::submitButton($lang->release->linkBug);?>
</div>
<?php endif;?>
<?php echo html::a(inlink('view', "releaseID=$release->id&type=$type"), $lang->goback, '', "class='btn'");?>
</div>
</form>
</div>
<script>
+23 -18
View File
@@ -12,14 +12,21 @@
?>
<div id='queryBox' class='show'></div>
<div id='unlinkStoryList'>
<form class='main-table' method='post' target='hiddenwin' id='unlinkedStoriesForm' action='<?php echo $this->createLink('release', 'linkStory', "releaseID=$release->id&browseType=$browseType&param=$param")?>'>
<form class='main-table' method='post' target='hiddenwin' id='unlinkedStoriesForm' action='<?php echo $this->createLink('release', 'linkStory', "releaseID=$release->id&browseType=$browseType&param=$param")?>' data-ride='table'>
<div class='table-header'>
<div class='table-statistic'><?php echo html::icon('unlink');?> &nbsp;<strong><?php echo $lang->productplan->unlinkedStories;?></strong></div>
</div>
<table class='table'>
<thead>
<tr>
<th class='c-id'> <?php echo $lang->idAB;?></th>
<th class='c-id'>
<?php if($allStories):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
</div>
<?php endif;?>
<?php echo $lang->idAB;?>
</th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th> <?php echo $lang->story->title;?></th>
<th class='w-user text-left'> <?php echo $lang->openedByAB;?></th>
@@ -36,8 +43,11 @@
<?php if($release->product != $story->product) continue; ?>
<tr>
<td class='c-id'>
<input class='ml-10px' type='checkbox' name='stories[]' value='<?php echo $story->id;?>' <?php if($story->stage == 'developed' or $story->status == 'closed') echo 'checked';?> />
<?php printf('%03d', $story->id);?>
<div class="checkbox-primary">
<input type='checkbox' name='stories[]' value='<?php echo $story->id;?>' <?php if($story->stage == 'developed' or $story->status == 'closed') echo 'checked';?> />
<label></label>
</div>
<?php printf('%03d', $story->id);?>
</td>
<td><span class='label-pri <?php echo 'label-pri-' . $story->pri;?>'><?php echo zget($lang->story->priList, $story->pri)?></span></td>
<td class='text-left nobr' title='<?php echo $story->title?>'><?php echo html::a($this->createLink('story', 'view', "storyID=$story->id", '', true), $story->title, '', "data-toggle='modal' data-type='iframe' data-width='90%'");?></td>
@@ -50,21 +60,16 @@
<?php $unlinkedCount++;?>
<?php endforeach;?>
</tbody>
<?php if($unlinkedCount):?>
<tfoot>
<tr>
<td colspan='8' class='text-left table-footer'>
<div class='clearfix'>
<?php
echo html::selectButton() . html::submitButton($lang->story->linkStory);
echo html::a(inlink('view', "releaseID=$release->id&type=story"), $lang->goback, '', "class='btn'");
?>
</div>
</td>
</tr>
</tfoot>
<?php endif;?>
</table>
<div class='table-footer'>
<?php if($unlinkedCount):?>
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
<div class='btn-toolbar'>
<?php echo html::submitButton($lang->release->linkStory);?>
</div>
<?php endif;?>
<?php echo html::a(inlink('view', "releaseID=$release->id&type=story"), $lang->goback, '', "class='btn'");?>
</div>
</form>
</div>
<script>
+106 -100
View File
@@ -93,35 +93,37 @@
<th class='w-50px'> <?php echo $lang->actions?></th>
</tr>
</thead>
<?php foreach($stories as $storyID => $story):?>
<?php $storyLink = $this->createLink('story', 'view', "storyID=$story->id", '', true);?>
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkStories[]' value='<?php echo $story->id;?>'/>
<label></label>
<?php endif;?>
<?php echo sprintf('%03d', $story->id);?>
</div>
</td>
<td><span class='label-pri <?php echo 'label-pri-' . $story->pri;?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri);?></span></td>
<td class='text-left nobr' title='<?php echo $story->title?>'><?php echo html::a($storyLink,$story->title, '', "class='preview'");?></td>
<td><?php echo $users[$story->openedBy];?></td>
<td><?php echo $story->estimate;?></td>
<td><span class='status-<?php echo $story->status;?>'><span class="label label-dot"></span> <?php echo $lang->story->statusList[$story->status];?></span></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('release', 'unlinkStory'))
{
$unlinkURL = $this->createLink('release', 'unlinkStory', "releaseID=$release->id&story=$story->id");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"storyList\",confirmUnlinkStory)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->release->unlinkStory}'");
}
?>
</td>
</tr>
<?php endforeach;?>
<tbody>
<?php foreach($stories as $storyID => $story):?>
<?php $storyLink = $this->createLink('story', 'view', "storyID=$story->id", '', true);?>
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkStories[]' value='<?php echo $story->id;?>'/>
<label></label>
<?php endif;?>
<?php echo sprintf('%03d', $story->id);?>
</div>
</td>
<td><span class='label-pri <?php echo 'label-pri-' . $story->pri;?>'><?php echo zget($lang->story->priList, $story->pri, $story->pri);?></span></td>
<td class='text-left nobr' title='<?php echo $story->title?>'><?php echo html::a($storyLink,$story->title, '', "class='preview'");?></td>
<td><?php echo $users[$story->openedBy];?></td>
<td><?php echo $story->estimate;?></td>
<td><span class='status-<?php echo $story->status;?>'><span class="label label-dot"></span> <?php echo $lang->story->statusList[$story->status];?></span></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('release', 'unlinkStory'))
{
$unlinkURL = $this->createLink('release', 'unlinkStory', "releaseID=$release->id&story=$story->id");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"storyList\",confirmUnlinkStory)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->release->unlinkStory}'");
}
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if($countStories and $canBatchUnlink):?>
<div class='table-footer'>
@@ -162,35 +164,37 @@
<th class='w-50px'> <?php echo $lang->actions;?></th>
</tr>
</thead>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id", '', true);?>
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkBugs[]' value='<?php echo $bug->id;?>'/>
<label></label>
<?php endif;?>
<?php echo sprintf('%03d', $bug->id);?>
</div>
</td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><span class='status-<?php echo $bug->status?>'><span class="label label-dot"></span> <?php echo zget($lang->bug->statusList, $bug->status);?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('release', 'unlinkBug'))
{
$unlinkURL = $this->createLink('release', 'unlinkBug', "releaseID=$release->id&bug=$bug->id");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"bugList\",confirmUnlinkBug)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->release->unlinkBug}'");
}
?>
</td>
</tr>
<?php endforeach;?>
<tbody>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id", '', true);?>
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkBugs[]' value='<?php echo $bug->id;?>'/>
<label></label>
<?php endif;?>
<?php echo sprintf('%03d', $bug->id);?>
</div>
</td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><span class='status-<?php echo $bug->status?>'><span class="label label-dot"></span> <?php echo zget($lang->bug->statusList, $bug->status);?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('release', 'unlinkBug'))
{
$unlinkURL = $this->createLink('release', 'unlinkBug', "releaseID=$release->id&bug=$bug->id");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"bugList\",confirmUnlinkBug)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->release->unlinkBug}'");
}
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if($countBugs and $canBatchUnlink):?>
<div class='table-footer'>
@@ -230,34 +234,36 @@
<th class='w-50px'> <?php echo $lang->actions;?></th>
</tr>
</thead>
<?php foreach($leftBugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id", '', true);?>
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkBugs[]' value='<?php echo $bug->id;?>'/>
<label></label>
<?php endif;?>
<?php echo sprintf('%03d', $bug->id);?>
</div>
</td>
<td><span class='severity<?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity)?>'><?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity);?></span></td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><span class='status-<?php echo $bug->status?>'><span class="label label-dot"></span> <?php echo zget($lang->bug->statusList, $bug->status);?></span></td>
<td><?php echo zget($users, $bug->openedBy);?></td>
<td><?php echo $bug->openedDate?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('release', 'unlinkBug'))
{
$unlinkURL = $this->createLink('release', 'unlinkBug', "releaseID=$release->id&bug=$bug->id&type=leftBug");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"leftBugList\",confirmUnlinkBug)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->release->unlinkBug}'");
}
?>
</td>
</tr>
<?php endforeach;?>
<tbody>
<?php foreach($leftBugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id", '', true);?>
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<?php if($canBatchUnlink):?>
<input type='checkbox' name='unlinkBugs[]' value='<?php echo $bug->id;?>'/>
<label></label>
<?php endif;?>
<?php echo sprintf('%03d', $bug->id);?>
</div>
</td>
<td><span class='severity<?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity)?>'><?php echo zget($lang->bug->severityList, $bug->severity, $bug->severity);?></span></td>
<td class='text-left nobr' title='<?php echo $bug->title?>'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><span class='status-<?php echo $bug->status?>'><span class="label label-dot"></span> <?php echo zget($lang->bug->statusList, $bug->status);?></span></td>
<td><?php echo zget($users, $bug->openedBy);?></td>
<td><?php echo $bug->openedDate?></td>
<td class='c-actions'>
<?php
if(common::hasPriv('release', 'unlinkBug'))
{
$unlinkURL = $this->createLink('release', 'unlinkBug', "releaseID=$release->id&bug=$bug->id&type=leftBug");
echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"leftBugList\",confirmUnlinkBug)", '<i class="icon-unlink"></i>', '', "class='btn-icon' title='{$lang->release->unlinkBug}'");
}
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if($countLeftBugs and $canBatchUnlink):?>
<div class='table-footer'>
@@ -317,20 +323,20 @@
<div class='detail'>
<div class='detail-title'><?php echo $lang->files?></div>
<div class='detail-content article-content'>
<?php
if($release->files)
{
echo $this->fetch('file', 'printFiles', array('files' => $release->files, 'fieldset' => 'false'));
}
elseif($release->filePath)
{
echo $lang->release->filePath . html::a($release->filePath, $release->filePath, '_blank');
}
elseif($release->scmPath)
{
echo $lang->release->scmPath . html::a($release->scmPath, $release->scmPath, '_blank');
}
?>
<?php
if($release->files)
{
echo $this->fetch('file', 'printFiles', array('files' => $release->files, 'fieldset' => 'false'));
}
elseif($release->filePath)
{
echo $lang->release->filePath . html::a($release->filePath, $release->filePath, '_blank');
}
elseif($release->scmPath)
{
echo $lang->release->scmPath . html::a($release->scmPath, $release->scmPath, '_blank');
}
?>
</div>
</div>
<?php include '../../common/view/action.html.php';?>
-12
View File
@@ -2614,16 +2614,4 @@ class storyModel extends model
return array($toList, $ccList);
}
/**
* Get story count.
*
* @param int $productID
* @access public
* @return int
*/
public function getCount($productID)
{
return $this->dao->select('count(*) as count')->from(TABLE_STORY)->where('deleted')->eq(0)->andWhere('product')->eq($productID)->fetch('count');
}
}
+9 -3
View File
@@ -114,11 +114,17 @@
break;
}
}
$priList = $lang->story->priList;
if(end($priList))
{
unset($priList[0]);
$priList[0] = '';
}
?>
<?php if($hasCustomPri):?>
<?php echo html::select('pri', (array)$lang->story->priList, $pri, "class='form-control chosen'");?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control chosen'");?>
<?php else: ?>
<?php echo html::select('pri', (array)$lang->story->priList, $pri, "class='form-control' data-provide='labelSelector'");?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector'");?>
<?php endif; ?>
</td>
</tr>
@@ -137,7 +143,7 @@
<td>
<div class='checkbox-primary'>
<input id='needNotReview' name='needNotReview' value='1' type='checkbox' class='no-margin' <?php echo $needReview;?>/>
<label for='marker'><?php echo $lang->story->needNotReview;?></label>
<label for='needNotReview'><?php echo $lang->story->needNotReview;?></label>
</div>
</td>
<?php endif;?>
+39 -41
View File
@@ -317,54 +317,52 @@
</div>
<div id="mainActions">
<?php common::printPreAndNext($preAndNext);?>
<div class="btn-toolbar">
<?php if(!$story->deleted):?>
<?php
common::printIcon('story', 'change', "storyID=$story->id", $story);
common::printIcon('story', 'review', "storyID=$story->id", $story);
if($story->status != 'closed' and !isonlybody())
{
$misc = "class='btn' data-toggle='modal' data-type='iframe' data-width='95%'";
$link = $this->createLink('story', 'batchCreate', "productID=$story->product&branch=$story->branch&moduleID=$story->module&storyID=$story->id", '', true);
if(common::hasPriv('story', 'batchCreate')) echo html::a($link, "<i class='icon icon-sitemap'></i> " . $lang->story->subdivide, '', $misc);
}
<?php common::printPreAndNext($preAndNext);?>
<div class="btn-toolbar">
<?php common::printBack($browseLink);?>
<?php if(!$story->deleted):?>
<div class='divider'></div>
<?php
common::printIcon('story', 'change', "storyID=$story->id", $story);
common::printIcon('story', 'review', "storyID=$story->id", $story);
if($story->status != 'closed' and !isonlybody())
{
$misc = "class='btn' data-toggle='modal' data-type='iframe' data-width='95%'";
$link = $this->createLink('story', 'batchCreate', "productID=$story->product&branch=$story->branch&moduleID=$story->module&storyID=$story->id", '', true);
if(common::hasPriv('story', 'batchCreate')) echo html::a($link, "<i class='icon icon-sitemap'></i> " . $lang->story->subdivide, '', $misc);
}
common::printIcon('story', 'close', "storyID=$story->id", $story, 'button', '', '', 'iframe', true);
common::printIcon('story', 'activate', "storyID=$story->id", $story, 'button', '', '', 'iframe', true);
common::printIcon('story', 'close', "storyID=$story->id", $story, 'button', '', '', 'iframe', true);
common::printIcon('story', 'activate', "storyID=$story->id", $story, 'button', '', '', 'iframe', true);
if($this->config->global->flow != 'onlyStory' and !isonlybody() and (common::hasPriv('testcase', 'create') or common::hasPriv('testcase', 'batchCreate')))
{
$this->app->loadLang('testcase');
echo "<div class='btn-group dropup'>";
echo "<button type='button' class='btn btn-default dropdown-toggle' data-toggle='dropdown'><i class='icon icon-sitemap'></i> " . $lang->testcase->common . " <span class='caret'></span></button>";
echo "<ul class='dropdown-menu' id='createCaseActionMenu'>";
if($this->config->global->flow != 'onlyStory' and !isonlybody() and (common::hasPriv('testcase', 'create') or common::hasPriv('testcase', 'batchCreate')))
{
$this->app->loadLang('testcase');
echo "<div class='btn-group dropup'>";
echo "<button type='button' class='btn btn-default dropdown-toggle' data-toggle='dropdown'><i class='icon icon-sitemap'></i> " . $lang->testcase->common . " <span class='caret'></span></button>";
echo "<ul class='dropdown-menu' id='createCaseActionMenu'>";
$misc = "data-toggle='modal' data-type='iframe' data-width='95%'";
$link = $this->createLink('testcase', 'create', "productID=$story->product&branch=$story->branch&moduleID=0&from=&param=0&storyID=$story->id", '', true);
if(common::hasPriv('testcase', 'create', $story)) echo "<li>" . html::a($link, $lang->testcase->create, '', $misc) . "</li>";
$misc = "data-toggle='modal' data-type='iframe' data-width='95%'";
$link = $this->createLink('testcase', 'create', "productID=$story->product&branch=$story->branch&moduleID=0&from=&param=0&storyID=$story->id", '', true);
if(common::hasPriv('testcase', 'create', $story)) echo "<li>" . html::a($link, $lang->testcase->create, '', $misc) . "</li>";
$misc = "data-toggle='modal' data-type='iframe' data-width='95%'";
$link = $this->createLink('testcase', 'batchCreate', "productID=$story->product&branch=$story->branch&moduleID=0&storyID=$story->id", '', true);
if(common::hasPriv('testcase', 'batchCreate')) echo "<li>" . html::a($link, $lang->testcase->batchCreate, '', $misc) . "</li>";
$misc = "data-toggle='modal' data-type='iframe' data-width='95%'";
$link = $this->createLink('testcase', 'batchCreate', "productID=$story->product&branch=$story->branch&moduleID=0&storyID=$story->id", '', true);
if(common::hasPriv('testcase', 'batchCreate')) echo "<li>" . html::a($link, $lang->testcase->batchCreate, '', $misc) . "</li>";
echo "</ul>";
echo "</div>";
}
echo "</ul>";
echo "</div>";
}
if($from == 'project') common::printIcon('task', 'create', "project=$param&storyID=$story->id&moduleID=$story->module", $story, 'button', 'smile');
if($from == 'project') common::printIcon('task', 'create', "project=$param&storyID=$story->id&moduleID=$story->module", $story, 'button', 'smile');
echo "<div class='divider'></div>";
common::printIcon('story', 'edit', "storyID=$story->id", $story);
common::printIcon('story', 'create', "productID=$story->product&branch=$story->branch&moduleID=$story->module&storyID=$story->id", $story, 'button', 'copy');
common::printIcon('story', 'delete', "storyID=$story->id", $story, 'button', '', 'hiddenwin');
echo "<div class='divider'></div>";
common::printBack($browseLink);
?>
<?php else:?>
<?php common::printBack($browseLink);?>
<?php endif;?>
echo "<div class='divider'></div>";
common::printIcon('story', 'edit', "storyID=$story->id", $story);
common::printIcon('story', 'create', "productID=$story->product&branch=$story->branch&moduleID=$story->module&storyID=$story->id", $story, 'button', 'copy');
common::printIcon('story', 'delete', "storyID=$story->id", $story, 'button', '', 'hiddenwin');
?>
<?php endif;?>
</div>
</div>
<?php
js::set('canCreate', common::hasPriv('story', 'story'));
+1
View File
@@ -167,6 +167,7 @@ $lang->task->confirmRecord = '"剩餘"為0,任務將標記為"已完
$lang->task->noticeLinkStory = "沒有可關聯的相關需求,您可以為當前項目%s,然後%s";
$lang->task->noticeSaveRecord = '您有尚未保存的工時記錄,請先將其保存。';
$lang->task->commentActions = '%s. %s, 由 <strong>%s</strong> 添加備註。';
$lang->task->noData = '暫無';
$lang->task->error = new stdclass();
$lang->task->error->consumedNumber = '"已經消耗"必須為數字';
+1
View File
@@ -452,6 +452,7 @@ class testreport extends control
{
$this->projects = $this->project->getPairs('nocode');
$projectID = $this->project->saveState($objectID, $this->projects);
$this->lang->testreport->dividerMenu = $this->lang->project->dividerMenu;
$this->project->setMenu($this->projects, $projectID);
$this->lang->testreport->menu = $this->lang->project->menu;
$this->lang->testreport->menu->testtask['subModule'] = 'testreport';
+1 -1
View File
@@ -1,5 +1,5 @@
<?php $sysURL = $this->session->notHead ? common::getSysURL() : '';?>
<table class='table' id='bugs'>
<table class='table main-table' id='bugs'>
<thead>
<tr>
<th class='w-id'> <?php echo $lang->idAB;?></th>
+2 -2
View File
@@ -1,11 +1,11 @@
<?php $sysURL = $this->session->notHead ? common::getSysURL() : '';?>
<table class='table' id='builds'>
<table class='table main-table' id='builds'>
<thead>
<tr>
<th class='w-id'> <?php echo $lang->build->id;?></th>
<th> <?php echo $lang->build->name;?></th>
<th class='w-user'><?php echo $lang->build->builder;?></th>
<th class='w-date'><?php echo $lang->build->date;?></th>
<th class='w-100px'><?php echo $lang->build->date;?></th>
</tr>
</thead>
<?php if($builds):?>
+3 -3
View File
@@ -1,5 +1,5 @@
<?php $sysURL = $this->session->notHead ? common::getSysURL() : '';?>
<table class='table' id='cases'>
<table class='table main-table' id='cases'>
<thead>
<tr>
<th class='w-id'> <?php echo $lang->idAB;?></th>
@@ -8,9 +8,9 @@
<th class='w-type'> <?php echo $lang->testcase->type;?></th>
<th class='w-user'> <?php echo $lang->testtask->assignedTo;?></th>
<th class='w-user'> <?php echo $lang->testtask->lastRunAccount;?></th>
<th class='w-130px'> <?php echo $lang->testtask->lastRunTime;?></th>
<th class='w-150px'> <?php echo $lang->testtask->lastRunTime;?></th>
<th class='w-80px'> <?php echo $lang->testtask->lastRunResult;?></th>
<th class='w-status'><?php echo $lang->statusAB;?></th>
<th class='w-100px'><?php echo $lang->statusAB;?></th>
</tr>
</thead>
<?php if($cases):?>
@@ -1,5 +1,5 @@
<?php $sysURL = $this->session->notHead ? common::getSysURL() : '';?>
<table class='table' id='legacyBugs'>
<table class='table main-table' id='legacyBugs'>
<thead>
<tr>
<th class='w-id'> <?php echo $lang->idAB;?></th>
@@ -7,8 +7,8 @@
<th> <?php echo $lang->bug->title;?></th>
<th class='w-user'> <?php echo $lang->openedByAB;?></th>
<th class='w-user'> <?php echo $lang->bug->resolvedBy;?></th>
<th class='w-130px'><?php echo $lang->bug->resolvedDate;?></th>
<th class='w-80px'> <?php echo $lang->statusAB;?></th>
<th class='w-150px'><?php echo $lang->bug->resolvedDate;?></th>
<th class='w-100px'> <?php echo $lang->statusAB;?></th>
</tr>
</thead>
<?php if($legacyBugs):?>
+3 -3
View File
@@ -1,5 +1,5 @@
<?php $sysURL = $this->session->notHead ? common::getSysURL() : '';?>
<table class='table' id='stories'>
<table class='table main-table' id='stories'>
<thead>
<tr>
<th class='w-id'> <?php echo $lang->idAB;?></th>
@@ -8,8 +8,8 @@
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-80px'><?php echo $lang->assignedToAB;?></th>
<th class='w-hour'><?php echo $lang->story->estimateAB;?></th>
<th class='w-hour'><?php echo $lang->statusAB;?></th>
<th class='w-70px'><?php echo $lang->story->stageAB;?></th>
<th class='w-80px'><?php echo $lang->statusAB;?></th>
<th class='w-80px'><?php echo $lang->story->stageAB;?></th>
</tr>
</thead>
<?php if($stories):?>
+46 -42
View File
@@ -11,51 +11,55 @@
*/
?>
<?php include '../../common/view/header.html.php';?>
<div id='titlebar'>
<div class='heading'>
<strong><?php echo $lang->testreport->browse;?></strong>
<div id='mainMenu' class='clearfix'>
<div class='pull-left btn-toolbar'>
<span class='btn btn-link btn-active-text'><span class='text'><?php echo $lang->testreport->browse;?></span></span>
</div>
</div>
<table class='table table-condensed table-hover table-striped tablesorter table-fixed table-selectable' id='reportList'>
<?php $vars = "objectID=$objectID&objectType=$objectType&extra=$extra&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}";?>
<thead>
<tr>
<th class='w-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->testreport->title);?></th>
<th class='w-user'> <?php common::printOrderLink('createdBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-120px'><?php common::printOrderLink('createdDate', $orderBy, $vars, $lang->testreport->createdDate);?></th>
<th class='w-250px'><?php common::printOrderLink('project', $orderBy, $vars, $lang->testreport->project);?></th>
<th class='w-250px'><?php echo $lang->testreport->testtask;?></th>
<th class='w-60px'> <?php echo $lang->actions;?></th>
</tr>
</thead>
<?php if($reports):?>
<tbody class='text-center'>
<?php foreach($reports as $report):?>
<tr>
<td><?php echo $report->id?></td>
<td class='text-left' title='<?php $report->title?>'><?php echo html::a(inlink('view', "reportID=$report->id&from=$objectType"), $report->title)?></td>
<td><?php echo zget($users, $report->createdBy);?></td>
<td><?php echo substr($report->createdDate, 2);?></td>
<?php $projectName = '#' . $report->project . $projects[$report->project];?>
<td class='text-left' title='<?php echo $projectName?>'><?php echo $projectName;?></td>
<?php
$taskName = '';
foreach(explode(',', $report->tasks) as $taskID) $taskName .= '#' . $taskID . $tasks[$taskID] . ' ';
?>
<td class='text-left' title='<?php echo $taskName?>'><?php echo $taskName;?></td>
<td>
<div id='mainContent' class='main-content'>
<table class='table has-sort-head main-table table-fixed' id='reportList'>
<?php $vars = "objectID=$objectID&objectType=$objectType&extra=$extra&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}";?>
<thead>
<tr>
<th class='w-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->testreport->title);?></th>
<th class='w-user'> <?php common::printOrderLink('createdBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='w-150px'><?php common::printOrderLink('createdDate', $orderBy, $vars, $lang->testreport->createdDate);?></th>
<th class='w-250px'><?php common::printOrderLink('project', $orderBy, $vars, $lang->testreport->project);?></th>
<th class='w-250px'><?php echo $lang->testreport->testtask;?></th>
<th class='w-80px'> <?php echo $lang->actions;?></th>
</tr>
</thead>
<?php if($reports):?>
<tbody class='text-center'>
<?php foreach($reports as $report):?>
<tr>
<td><?php echo $report->id?></td>
<td class='text-left' title='<?php $report->title?>'><?php echo html::a(inlink('view', "reportID=$report->id&from=$objectType"), $report->title)?></td>
<td><?php echo zget($users, $report->createdBy);?></td>
<td><?php echo substr($report->createdDate, 2);?></td>
<?php $projectName = '#' . $report->project . $projects[$report->project];?>
<td class='text-left' title='<?php echo $projectName?>'><?php echo $projectName;?></td>
<?php
common::printIcon('testreport', 'edit', "id=$report->id", '', 'list');
common::printIcon('testreport', 'delete', "id=$report->id", '', 'list', 'remove', 'hiddenwin');
$taskName = '';
foreach(explode(',', $report->tasks) as $taskID) $taskName .= '#' . $taskID . $tasks[$taskID] . ' ';
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
<tfoot><tr><td colspan='7'><?php $pager->show();?></td></tr></tfoot>
<?php else:?>
<tbody><tr><td colspan='7'><?php echo $lang->testreport->noReport;?></td></tr></tbody>
<td class='text-left' title='<?php echo $taskName?>'><?php echo $taskName;?></td>
<td class='c-actions'>
<?php
common::printIcon('testreport', 'edit', "id=$report->id", '', 'list');
common::printIcon('testreport', 'delete', "id=$report->id", '', 'list', 'trash', 'hiddenwin');
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
<?php else:?>
<tbody><tr><td colspan='7'><?php echo $lang->testreport->noReport;?></td></tr></tbody>
<?php endif;?>
</table>
<?php if($reports):?>
<div class='table-footer'><?php $pager->show('right', 'pagerjs');?></div>
<?php endif;?>
</table>
</div>
<?php include '../../common/view/footer.html.php';?>
+88 -94
View File
@@ -14,101 +14,95 @@
<?php include '../../common/view/datepicker.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<?php include '../../common/view/chart.html.php';?>
<div class='container mw-1400px'>
<div id='titlebar'>
<div class='heading'>
<strong><small class='text-muted'><?php echo html::icon($lang->icons['create']);?></small> <?php echo $lang->testreport->create;?></strong>
<div id='mainContent' class='main-content'>
<div class='center-block mw-1400px'>
<div class='main-header'>
<h2><?php echo $lang->testreport->create;?></h2>
<div class='pull-right btn-toolbar'><?php echo html::backButton();?></div>
</div>
<div class='actions'>
<?php
echo html::backButton();
?>
</div>
</div>
<div class='main'>
<form class='form-condensed' method='post' enctype='multipart/form-data' target='hiddenwin'>
<fieldset>
<legend><?php echo $lang->testreport->legendBasic?></legend>
<table class='table table-form'>
<tr>
<th class='w-80px'><?php echo $lang->testreport->startEnd?></th>
<td class='w-p50'>
<div class='input-group'>
<?php echo html::input('begin', $begin, "class='form-control form-date'")?>
<span class='input-group-addon'> ~ </span>
<?php echo html::input('end', $end, "class='form-control form-date'")?>
<?php
echo html::hidden('product', $productIdList) . html::hidden('project', $project->id) . html::hidden('tasks', $tasks);
echo html::hidden('objectID', $objectID) . html::hidden('objectType', $objectType);
?>
</div>
</td>
<td>
<div class='input-group'>
<span class='input-group-addon'><?php echo $lang->testreport->owner?></span>
<?php echo html::select('owner', $users, $owner, "class='form-control chosen'")?>
</div>
</td>
</tr>
<tr>
<th><?php echo $lang->testreport->members?></th>
<td colspan='2'><?php echo html::select('members[]', $users, $members, "class='form-control chosen' multiple")?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->title?></th>
<td colspan='2'><?php echo html::input('title', $reportTitle, "class='form-control'")?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->goal?></th>
<td colspan='2'><?php echo $project->desc?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->profile?></th>
<td colspan='2'>
<?php
echo '<p>' . $storySummary . '</p>';
echo '<p>' . sprintf($lang->testreport->buildSummary, empty($builds) ? 1 : count($builds)) . $caseSummary . '</p>';
echo '<p>' . sprintf($lang->testreport->bugSummary, $bugInfo['foundBugs'], count($legacyBugs), $bugInfo['countBugByTask'], $bugInfo['bugConfirmedRate'] . '%', $bugInfo['bugCreateByCaseRate'] . '%') . '</p>';
unset($bugInfo['countBugByTask']); unset($bugInfo['bugConfirmedRate']); unset($bugInfo['bugCreateByCaseRate']); unset($bugInfo['foundBugs']);
?>
</td>
</tr>
<tr>
<th><?php echo $lang->testreport->report?></th>
<td colspan='2'><?php echo html::textarea('report', '', "class='form-control'")?></td>
</tr>
<tr>
<th><?php echo $lang->files?></th>
<td colspan='2'><?php echo $this->fetch('file', 'buildform');?></td>
</tr>
<tr>
<th></th>
<td><?php echo html::submitButton() . html::backButton();?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendStoryAndBug?></legend>
<?php include './blockstories.html.php'?>
<?php include './blockbugs.html.php'?>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendBuild?></legend>
<?php include './blockbuilds.html.php'?>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendCase?></legend>
<?php include './blockcases.html.php'?>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendLegacyBugs?></legend>
<?php include './blocklegacybugs.html.php'?>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendReport?></legend>
<?php include './blockbugreport.html.php'?>
</fieldset>
</form>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendBasic?></div>
<table class='table table-form'>
<tr>
<th class='w-80px'><?php echo $lang->testreport->startEnd?></th>
<td class='w-p50'>
<div class='input-group'>
<?php echo html::input('begin', $begin, "class='form-control form-date'")?>
<span class='input-group-addon'> ~ </span>
<?php echo html::input('end', $end, "class='form-control form-date'")?>
<?php
echo html::hidden('product', $productIdList) . html::hidden('project', $project->id) . html::hidden('tasks', $tasks);
echo html::hidden('objectID', $objectID) . html::hidden('objectType', $objectType);
?>
</div>
</td>
<td>
<div class='input-group'>
<span class='input-group-addon'><?php echo $lang->testreport->owner?></span>
<?php echo html::select('owner', $users, $owner, "class='form-control chosen'")?>
</div>
</td>
</tr>
<tr>
<th><?php echo $lang->testreport->members?></th>
<td colspan='2'><?php echo html::select('members[]', $users, $members, "class='form-control chosen' multiple")?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->title?></th>
<td colspan='2'><?php echo html::input('title', $reportTitle, "class='form-control'")?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->goal?></th>
<td colspan='2'><?php echo $project->desc?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->profile?></th>
<td colspan='2'>
<?php
echo '<p>' . $storySummary . '</p>';
echo '<p>' . sprintf($lang->testreport->buildSummary, empty($builds) ? 1 : count($builds)) . $caseSummary . '</p>';
echo '<p>' . sprintf($lang->testreport->bugSummary, $bugInfo['foundBugs'], count($legacyBugs), $bugInfo['countBugByTask'], $bugInfo['bugConfirmedRate'] . '%', $bugInfo['bugCreateByCaseRate'] . '%') . '</p>';
unset($bugInfo['countBugByTask']); unset($bugInfo['bugConfirmedRate']); unset($bugInfo['bugCreateByCaseRate']); unset($bugInfo['foundBugs']);
?>
</td>
</tr>
<tr>
<th><?php echo $lang->testreport->report?></th>
<td colspan='2'><?php echo html::textarea('report', '', "class='form-control'")?></td>
</tr>
<tr>
<th><?php echo $lang->files?></th>
<td colspan='2'><?php echo $this->fetch('file', 'buildform');?></td>
</tr>
<tr>
<th></th>
<td><?php echo html::submitButton() . html::backButton();?></td>
</tr>
</table>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendStoryAndBug?></div>
<?php include './blockstories.html.php'?>
<?php include './blockbugs.html.php'?>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendBuild?></div>
<?php include './blockbuilds.html.php'?>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendCase?></div>
<?php include './blockcases.html.php'?>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendLegacyBugs?></div>
<?php include './blocklegacybugs.html.php'?>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendReport?></div>
<?php include './blockbugreport.html.php'?>
</div>
</form>
</div>
</div>
<?php include '../../common/view/footer.html.php';?>
+87 -89
View File
@@ -14,96 +14,94 @@
<?php include '../../common/view/datepicker.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<?php include '../../common/view/chart.html.php';?>
<div class='container mw-1400px'>
<div id='titlebar'>
<div class='heading'>
<strong><small class='text-muted'><?php echo html::icon($lang->icons['edit']);?></small> <?php echo $lang->testreport->edit;?></strong>
<div id='mainContent' class='main-content'>
<div class='center-block mw-1400px'>
<div class='main-header'>
<h2><?php echo $lang->testreport->edit;?></h2>
<div class='btn-toolbar pull-right'><?php echo html::backButton();?></div>
</div>
<div class='actions'><?php echo html::backButton();?></div>
</div>
<div class='main'>
<form class='form-condensed' method='post' enctype='multipart/form-data' target='hiddenwin'>
<fieldset>
<legend><?php echo $lang->testreport->legendBasic?></legend>
<table class='table table-form'>
<tr>
<th class='w-80px'><?php echo $lang->testreport->startEnd?></th>
<td class='w-p50'>
<div class='input-group'>
<?php echo html::input('begin', $report->begin, "class='form-control form-date'")?>
<span class='input-group-addon'> ~ </span>
<?php echo html::input('end', $report->end, "class='form-control form-date'")?>
<?php
echo html::hidden('product', $productIdList) . html::hidden('project', $report->project) . html::hidden('tasks', $tasks);
?>
</div>
</td>
<td>
<div class='input-group'>
<span class='input-group-addon'><?php echo $lang->testreport->owner?></span>
<?php echo html::select('owner', $users, $report->owner, "class='form-control chosen'")?>
</div>
</td>
</tr>
<tr>
<th><?php echo $lang->testreport->members?></th>
<td colspan='2'><?php echo html::select('members[]', $users, $report->members, "class='form-control chosen' multiple")?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->title?></th>
<td colspan='2'><?php echo html::input('title', $report->title, "class='form-control'")?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->goal?></th>
<td colspan='2'><?php echo $project->desc?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->profile?></th>
<td colspan='2'>
<?php
echo '<p>' . $storySummary . '</p>';
echo '<p>' . sprintf($lang->testreport->buildSummary, empty($builds) ? 1 : count($builds)) . $caseSummary . '</p>';
echo '<p>' . sprintf($lang->testreport->bugSummary, $bugInfo['foundBugs'], count($legacyBugs), $bugInfo['countBugByTask'], $bugInfo['bugConfirmedRate'] . '%', $bugInfo['bugCreateByCaseRate'] . '%') . '</p>';
unset($bugInfo['countBugByTask']); unset($bugInfo['bugConfirmedRate']); unset($bugInfo['bugCreateByCaseRate']); unset($bugInfo['foundBugs']);
?>
</td>
</tr>
<tr>
<th><?php echo $lang->testreport->report?></th>
<td colspan='2'><?php echo html::textarea('report', $report->report, "class='form-control'")?></td>
</tr>
<tr>
<th><?php echo $lang->files?></th>
<td colspan='2'><?php echo $this->fetch('file', 'buildform');?></td>
</tr>
<tr>
<th></th>
<td><?php echo html::submitButton() . html::backButton();?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendStoryAndBug?></legend>
<?php include './blockstories.html.php'?>
<?php include './blockbugs.html.php'?>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendBuild?></legend>
<?php include './blockbuilds.html.php'?>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendCase?></legend>
<?php include './blockcases.html.php'?>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendLegacyBugs?></legend>
<?php include './blocklegacybugs.html.php'?>
</fieldset>
<fieldset>
<legend><?php echo $lang->testreport->legendReport?></legend>
<?php include './blockbugreport.html.php'?>
</fieldset>
</form>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendBasic?></div>
<table class='table table-form'>
<tr>
<th class='w-80px'><?php echo $lang->testreport->startEnd?></th>
<td class='w-p50'>
<div class='input-group'>
<?php echo html::input('begin', $report->begin, "class='form-control form-date'")?>
<span class='input-group-addon'> ~ </span>
<?php echo html::input('end', $report->end, "class='form-control form-date'")?>
<?php
echo html::hidden('product', $productIdList) . html::hidden('project', $report->project) . html::hidden('tasks', $tasks);
?>
</div>
</td>
<td>
<div class='input-group'>
<span class='input-group-addon'><?php echo $lang->testreport->owner?></span>
<?php echo html::select('owner', $users, $report->owner, "class='form-control chosen'")?>
</div>
</td>
</tr>
<tr>
<th><?php echo $lang->testreport->members?></th>
<td colspan='2'><?php echo html::select('members[]', $users, $report->members, "class='form-control chosen' multiple")?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->title?></th>
<td colspan='2'><?php echo html::input('title', $report->title, "class='form-control'")?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->goal?></th>
<td colspan='2'><?php echo $project->desc?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->profile?></th>
<td colspan='2'>
<?php
echo '<p>' . $storySummary . '</p>';
echo '<p>' . sprintf($lang->testreport->buildSummary, empty($builds) ? 1 : count($builds)) . $caseSummary . '</p>';
echo '<p>' . sprintf($lang->testreport->bugSummary, $bugInfo['foundBugs'], count($legacyBugs), $bugInfo['countBugByTask'], $bugInfo['bugConfirmedRate'] . '%', $bugInfo['bugCreateByCaseRate'] . '%') . '</p>';
unset($bugInfo['countBugByTask']); unset($bugInfo['bugConfirmedRate']); unset($bugInfo['bugCreateByCaseRate']); unset($bugInfo['foundBugs']);
?>
</td>
</tr>
<tr>
<th><?php echo $lang->testreport->report?></th>
<td colspan='2'><?php echo html::textarea('report', $report->report, "class='form-control'")?></td>
</tr>
<tr>
<th><?php echo $lang->files?></th>
<td colspan='2'><?php echo $this->fetch('file', 'buildform');?></td>
</tr>
<tr>
<th></th>
<td><?php echo html::submitButton() . html::backButton();?></td>
</tr>
</table>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendStoryAndBug?></div>
<?php include './blockstories.html.php'?>
<?php include './blockbugs.html.php'?>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendBuild?></div>
<?php include './blockbuilds.html.php'?>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendCase?></div>
<?php include './blockcases.html.php'?>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendLegacyBugs?></div>
<?php include './blocklegacybugs.html.php'?>
</div>
<div class='detail'>
<div class='detail-title'><?php echo $lang->testreport->legendReport?></div>
<?php include './blockbugreport.html.php'?>
</div>
</form>
</div>
</div>
<?php include '../../common/view/footer.html.php';?>
+91 -97
View File
@@ -13,108 +13,102 @@
<?php if(!$this->session->notHead):?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/chart.html.php';?>
<div class='container mw-1400px'>
<div id='titlebar'>
<div class='heading'>
<span class='prefix'><strong><?php echo $report->id;?></strong></span>
<strong><?php echo $report->title;?></strong>
</div>
<div class='actions'>
<?php
$browseLink = $this->session->reportList != false ? $app->session->reportList : $browseLink;
$actionLinks = '';
ob_start();
echo "<div class='btn-group'>";
if(common::hasPriv('testreport', 'create')) echo html::a(inLink('create', "objectID=$report->objectID&objectType=$report->objectType"), "<i class='icon-refresh'></i>", '', "class='btn' title='{$lang->testreport->recreate}'");
common::printIcon('testreport', 'edit', "reportID=$report->id", '', 'button');
common::printIcon('testreport', 'delete', "reportID=$report->id", '', 'button', '', 'hiddenwin');
echo '</div>';
echo "<div class='btn-group'>";
common::printRPN($browseLink);
echo '</div>';
$actionLinks = ob_get_contents();
ob_end_clean();
echo $actionLinks;
?>
<div id='mainMenu' class='clearfix'>
<div class='btn-toolbar pull-left'>
<?php $browseLink = $this->session->reportList != false ? $app->session->reportList : $browseLink;?>
<?php echo html::a($browseLink, "<i class='icon icon-back icon-sm'></i>" . $lang->goback, '', "class='btn btn-link'");?>
<div class='divider'></div>
<div class='page-title'>
<span class='label label-id'><?php echo $report->id;?></span>
<span class='text'><?php echo $report->title;?></span>
</div>
</div>
<?php endif;?>
<div class='main'>
<ul class='nav nav-tabs'>
<li class='active'><?php echo html::a('###', $lang->testreport->legendBasic, '', "data-toggle='tab' data-target='#basic'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendStoryAndBug, '', "data-toggle='tab' data-target='#storyAndBug'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendBuild, '', "data-toggle='tab' data-target='#tabBuild'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendCase, '', "data-toggle='tab' data-target='#tabCase'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendLegacyBugs, '', "data-toggle='tab' data-target='#tabLegacyBugs'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendReport, '', "data-toggle='tab' data-target='#tabReport'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendComment, '', "data-toggle='tab' data-target='#tabComment'")?></li>
<?php if(!$this->session->notHead):?>
<li><?php echo html::a('###', $lang->history, '', "data-toggle='tab' data-target='#tabHistory'")?></li>
<?php if($this->app->user->admin):?>
<li><?php echo html::a('###', $lang->testreport->legendMore, '', "data-toggle='tab' data-target='#tabMore'")?></li>
<?php endif;?>
<?php endif;?>
</ul>
<div class='tab-content'>
<div class='tab-pane' id='basic'>
<table class='table table-form'>
<tr>
<th class='w-100px'><?php echo $lang->testreport->startEnd?></th>
<td class='w-p50'> <?php echo $report->begin . ' ~ ' . $report->end;?></td>
<td></td>
</tr>
<tr>
<th><?php echo $lang->testreport->owner?></th>
<td><?php echo zget($users, $report->owner);?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->members?></th>
<td colspan='2'><?php foreach(explode(',', $report->members) as $member)echo zget($users, $member) . ' &nbsp; ';?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->goal?></th>
<td colspan='2'><?php echo $project->desc?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->profile?></th>
<td colspan='2'>
<?php
echo '<p>' . $storySummary . '</p>';
echo '<p>' . sprintf($lang->testreport->buildSummary, empty($builds) ? 1 : count($builds)) . $caseSummary . '</p>';
echo '<p>' . sprintf($lang->testreport->bugSummary, $bugInfo['foundBugs'], count($legacyBugs), $bugInfo['countBugByTask'], $bugInfo['bugConfirmedRate'] . '%', $bugInfo['bugCreateByCaseRate'] . '%') . '</p>';
unset($bugInfo['countBugByTask']); unset($bugInfo['bugConfirmedRate']); unset($bugInfo['bugCreateByCaseRate']); unset($bugInfo['foundBugs']);
?>
</td>
</tr>
<?php if(!$this->session->notHead):?>
<tr>
<th><?php echo $lang->files?></th>
<td><?php echo $this->fetch('file', 'printFiles', array('files' => $report->files, 'fieldset' => 'false'));?></td>
</tr>
<?php endif;?>
</table>
</div>
<div class='tab-pane' id='storyAndBug'>
<?php include './blockstories.html.php'?>
<?php include './blockbugs.html.php'?>
</div>
<div class='tab-pane' id='tabBuild'><?php include './blockbuilds.html.php'?></div>
<div class='tab-pane' id='tabCase'><?php include './blockcases.html.php'?></div>
<div class='tab-pane' id='tabLegacyBugs'><?php include './blocklegacybugs.html.php'?></div>
<div class='tab-pane active' id='tabReport'><?php include './blockbugreport.html.php'?></div>
<div class='tab-pane' id='tabComment'><div class='article-content'><?php echo empty($report->report) ? $lang->testreport->none : $report->report;?></div></div>
<?php if(!$this->session->notHead):?>
<div class='tab-pane' id='tabHistory'><?php include '../../common/view/action.html.php';?></div>
<?php if($this->app->user->admin):?>
<div class='tab-pane' id='tabMore'><div class='article-content'><?php echo $lang->testreport->moreNotice;?></div></div>
<?php endif;?>
<?php endif;?>
</div>
<?php endif;?>
<div id='mainContent' class='main-content'>
<ul class='nav nav-tabs'>
<li class='active'><?php echo html::a('###', $lang->testreport->legendBasic, '', "data-toggle='tab' data-target='#basic'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendStoryAndBug, '', "data-toggle='tab' data-target='#storyAndBug'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendBuild, '', "data-toggle='tab' data-target='#tabBuild'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendCase, '', "data-toggle='tab' data-target='#tabCase'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendLegacyBugs, '', "data-toggle='tab' data-target='#tabLegacyBugs'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendReport, '', "data-toggle='tab' data-target='#tabReport'")?></li>
<li><?php echo html::a('###', $lang->testreport->legendComment, '', "data-toggle='tab' data-target='#tabComment'")?></li>
<?php if(!$this->session->notHead):?>
<li><?php echo html::a('###', $lang->history, '', "data-toggle='tab' data-target='#tabHistory'")?></li>
<?php if($this->app->user->admin):?>
<li><?php echo html::a('###', $lang->testreport->legendMore, '', "data-toggle='tab' data-target='#tabMore'")?></li>
<?php endif;?>
<?php endif;?>
</ul>
<div class='tab-content'>
<div class='tab-pane' id='basic'>
<table class='table table-form'>
<tr>
<th class='w-100px'><?php echo $lang->testreport->startEnd?></th>
<td class='w-p50'> <?php echo $report->begin . ' ~ ' . $report->end;?></td>
<td></td>
</tr>
<tr>
<th><?php echo $lang->testreport->owner?></th>
<td><?php echo zget($users, $report->owner);?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->members?></th>
<td colspan='2'><?php foreach(explode(',', $report->members) as $member)echo zget($users, $member) . ' &nbsp; ';?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->goal?></th>
<td colspan='2'><?php echo $project->desc?></td>
</tr>
<tr>
<th><?php echo $lang->testreport->profile?></th>
<td colspan='2'>
<?php
echo '<p>' . $storySummary . '</p>';
echo '<p>' . sprintf($lang->testreport->buildSummary, empty($builds) ? 1 : count($builds)) . $caseSummary . '</p>';
echo '<p>' . sprintf($lang->testreport->bugSummary, $bugInfo['foundBugs'], count($legacyBugs), $bugInfo['countBugByTask'], $bugInfo['bugConfirmedRate'] . '%', $bugInfo['bugCreateByCaseRate'] . '%') . '</p>';
unset($bugInfo['countBugByTask']); unset($bugInfo['bugConfirmedRate']); unset($bugInfo['bugCreateByCaseRate']); unset($bugInfo['foundBugs']);
?>
</td>
</tr>
<?php if(!$this->session->notHead):?>
<tr>
<th><?php echo $lang->files?></th>
<td><?php echo $this->fetch('file', 'printFiles', array('files' => $report->files, 'fieldset' => 'false'));?></td>
</tr>
<?php endif;?>
</table>
</div>
<div class='tab-pane' id='storyAndBug'>
<?php include './blockstories.html.php'?>
<?php include './blockbugs.html.php'?>
</div>
<div class='tab-pane' id='tabBuild'><?php include './blockbuilds.html.php'?></div>
<div class='tab-pane' id='tabCase'><?php include './blockcases.html.php'?></div>
<div class='tab-pane' id='tabLegacyBugs'><?php include './blocklegacybugs.html.php'?></div>
<div class='tab-pane active' id='tabReport'><?php include './blockbugreport.html.php'?></div>
<div class='tab-pane' id='tabComment'><div class='article-content'><?php echo empty($report->report) ? $lang->testreport->none : $report->report;?></div></div>
<?php if(!$this->session->notHead):?>
<div class='tab-pane' id='tabHistory'><?php include '../../common/view/action.html.php';?></div>
<?php if($this->app->user->admin):?>
<div class='tab-pane' id='tabMore'><div class='article-content'><?php echo $lang->testreport->moreNotice;?></div></div>
<?php endif;?>
<?php endif;?>
</div>
</div>
<?php if(!$this->session->notHead):?>
<div id='mainActions'>
<nav class='container'></nav>
<div class='btn-toolbar'>
<?php common::printBack($browseLink);?>
<div class='divider'></div>
<?php
if(common::hasPriv('testreport', 'create')) echo html::a(inLink('create', "objectID=$report->objectID&objectType=$report->objectType"), "<i class='icon-refresh'></i>", '', "class='btn' title='{$lang->testreport->recreate}'");
common::printIcon('testreport', 'edit', "reportID=$report->id", '', 'button');
common::printIcon('testreport', 'delete', "reportID=$report->id", '', 'button', '', 'hiddenwin');
?>
</div>
</div>
<?php include '../../common/view/footer.html.php';?>
<?php endif;?>
+1 -1
View File
@@ -1945,7 +1945,7 @@ $(document).ready(function()
setSearchBox();
setOuterBox();
setRequiredFields();
//setRequiredFields();
setPlaceholder();
setModalTriggerLink();