Merge branch 'master' of github.com:easysoft/zentaopms

This commit is contained in:
wangyidong
2016-03-14 08:10:15 +08:00
94 changed files with 500 additions and 931 deletions
+12 -1
View File
@@ -17,7 +17,6 @@ $lang->action->objectID = 'ID';
$lang->action->objectName = 'Name';
$lang->action->actor = 'Actor';
$lang->action->action = 'Action';
$lang->action->actionID = 'ActionID';
$lang->action->date = 'Date';
$lang->action->trash = 'Trash';
@@ -99,6 +98,10 @@ $lang->action->desc->diff1 = 'changed <strong><i>%s</i></strong>, old i
$lang->action->desc->diff2 = 'changed <strong><i>%s</i></strong>, the diff is:' . "\n" . "<blockquote>%s</blockquote>" . "\n<div class='hidden'>%s</div>";
$lang->action->desc->diff3 = "changed file's name %s to %s.";
/* The desc of actions for link and unlink related case. */
$lang->action->desc->linkrelatedcase = '$date, linked related case <strong>$extra</strong> by <strong>$actor</strong>.' . "\n";
$lang->action->desc->unlinkrelatedcase = '$date, unlinked related case <strong>$extra</strong> by <strong>$actor</strong>.' . "\n";
/* The action labels. */
$lang->action->label = new stdclass();
$lang->action->label->created = 'created';
@@ -131,6 +134,14 @@ $lang->action->label->changestatus = 'change status';
$lang->action->label->marked = 'edited';
$lang->action->label->linked2project = "link to {$lang->projectCommon}";
$lang->action->label->unlinkedfromproject = "unlik from {$lang->projectCommon}";
$lang->action->label->linkrelatedbug = "linked related Bug";
$lang->action->label->unlinkrelatedbug = "unlinked related Bug";
$lang->action->label->linkrelatedcase = "linked related case";
$lang->action->label->unlinkrelatedcase = "unlinked related case";
$lang->action->label->linkrelatedstory = "linked related story";
$lang->action->label->unlinkrelatedstory = "unlinked related story";
$lang->action->label->subdividestory = "subdivided story";
$lang->action->label->unlinkchildstory = "unlinked child story";
$lang->action->label->started = 'started';
$lang->action->label->restarted = 'continued';
$lang->action->label->recordestimate = 'Hours';
+12 -1
View File
@@ -17,7 +17,6 @@ $lang->action->objectID = '对象ID';
$lang->action->objectName = '对象名称';
$lang->action->actor = '操作者';
$lang->action->action = '动作';
$lang->action->actionID = '记录ID';
$lang->action->date = '日期';
$lang->action->trash = '回收站';
@@ -99,6 +98,10 @@ $lang->action->desc->diff1 = '修改了 <strong><i>%s</i></strong>,
$lang->action->desc->diff2 = '修改了 <strong><i>%s</i></strong>,区别为:' . "\n" . "<blockquote>%s</blockquote>" . "\n<div class='hidden'>%s</div>";
$lang->action->desc->diff3 = '将文件名 %s 改为 %s 。' . "\n";
/* 关联用例和移除用例时的历史操作记录。*/
$lang->action->desc->linkrelatedcase = '$date, 由 <strong>$actor</strong> 关联相关用例 <strong>$extra</strong>。' . "\n";
$lang->action->desc->unlinkrelatedcase = '$date, 由 <strong>$actor</strong> 移除相关用例 <strong>$extra</strong>。' . "\n";
/* 用来显示动态信息。*/
$lang->action->label = new stdclass();
$lang->action->label->created = '创建';
@@ -131,6 +134,14 @@ $lang->action->label->changestatus = '修改状态';
$lang->action->label->marked = '编辑了';
$lang->action->label->linked2project = "关联{$lang->projectCommon}";
$lang->action->label->unlinkedfromproject = "移除{$lang->projectCommon}";
$lang->action->label->linkrelatedbug = "关联了相关Bug";
$lang->action->label->unlinkrelatedbug = "移除了相关Bug";
$lang->action->label->linkrelatedcase = "关联了相关用例";
$lang->action->label->unlinkrelatedcase = "移除了相关用例";
$lang->action->label->linkrelatedstory = "关联了相关需求";
$lang->action->label->unlinkrelatedstory = "移除了相关需求";
$lang->action->label->subdividestory = "细分了需求";
$lang->action->label->unlinkchildstory = "移除了细分需求";
$lang->action->label->started = '开始了';
$lang->action->label->restarted = '继续了';
$lang->action->label->recordestimate = '记录了工时';
-8
View File
@@ -12,18 +12,11 @@
$lang->admin->common = 'Admin';
$lang->admin->index = 'Index';
$lang->admin->checkDB = 'Repair data';
$lang->admin->company = 'Company';
$lang->admin->user = 'User';
$lang->admin->group = 'Group';
$lang->admin->sso = 'Integrate RanZhi';
$lang->admin->safeIndex = 'Safe';
$lang->admin->checkWeak = 'Check weak';
$lang->admin->welcome = 'Welcome to ZenTaoPMS.';
$lang->admin->browseCompany = 'Browse Company';
$lang->admin->info = new stdclass();
$lang->admin->info->caption = 'zentao information';
$lang->admin->info->version = 'The current version of the system is %s,';
$lang->admin->info->links = 'You can visit the following link:';
$lang->admin->info->account = 'Your account in zentao community is %s. ';
@@ -43,7 +36,6 @@ $lang->admin->register->success = "Register success";
$lang->admin->bind = new stdclass();
$lang->admin->bind->caption = 'Bind with community account';
$lang->admin->bind->action = 'bind';
$lang->admin->bind->success = "Bind success";
$lang->admin->safe = new stdclass();
-8
View File
@@ -12,18 +12,11 @@
$lang->admin->common = '后台管理';
$lang->admin->index = '后台管理首页';
$lang->admin->checkDB = '检查数据库';
$lang->admin->company = '公司管理';
$lang->admin->user = '用户管理';
$lang->admin->group = '分组管理';
$lang->admin->sso = '然之集成';
$lang->admin->safeIndex = '安全';
$lang->admin->checkWeak = '弱口令检查';
$lang->admin->welcome = '欢迎使用禅道管理软件后台管理系统';
$lang->admin->browseCompany = '浏览公司';
$lang->admin->info = new stdclass();
$lang->admin->info->caption = '禅道系统信息';
$lang->admin->info->version = '当前系统的版本是%s,';
$lang->admin->info->links = '您可以访问以下链接:';
$lang->admin->info->account = "您的禅道社区账户为%s。";
@@ -42,7 +35,6 @@ $lang->admin->register->bind = "如果您已经拥有社区账号,%s关
$lang->admin->register->success = "登记账户成功";
$lang->admin->bind = new stdclass();
$lang->admin->bind->caption = '关联社区账号';
$lang->admin->bind->action = '关联';
$lang->admin->bind->success = "关联账户成功";
-1
View File
@@ -8,7 +8,6 @@ $lang->backup->restore = 'Restore';
$lang->backup->change = 'Change hold days';
$lang->backup->changeAB = 'change';
$lang->backup->name = 'Name';
$lang->backup->time = 'Time';
$lang->backup->files = 'Files';
$lang->backup->size = 'Size';
-1
View File
@@ -8,7 +8,6 @@ $lang->backup->restore = '还原';
$lang->backup->change = '修改保留时间';
$lang->backup->changeAB = '修改';
$lang->backup->name = '文件名称';
$lang->backup->time = '备份时间';
$lang->backup->files = '备份文件';
$lang->backup->size = '大小';
-2
View File
@@ -13,8 +13,6 @@ $lang->block = new stdclass();
$lang->block->num = 'Number';
$lang->block->type = 'Type';
$lang->block->orderBy = 'Order';
$lang->block->status = 'Status';
$lang->block->actions = 'Action';
$lang->block->availableBlocks = new stdclass();
-2
View File
@@ -13,8 +13,6 @@ $lang->block = new stdclass();
$lang->block->num = '数量';
$lang->block->type = '类型';
$lang->block->orderBy = '排序';
$lang->block->status = '状态';
$lang->block->actions = '操作';
$lang->block->availableBlocks = new stdclass();
+35 -37
View File
@@ -88,7 +88,7 @@ class bug extends control
$pager = pager::init($recTotal, $recPerPage, $pageID);
/* Get projects. */
$projects = $this->loadModel('project')->getPairs() + array('0' => '');
$projects = $this->loadModel('project')->getPairs('empty');
/* Get bugs. */
$bugs = $this->bug->getBugs($productID, $projects, $branch, $browseType, $moduleID, $queryID, $sort, $pager);
@@ -105,7 +105,6 @@ class bug extends control
/* Build the search form. */
$actionURL = $this->createLink('bug', 'browse', "productID=$productID&branch=$branch&browseType=bySearch&queryID=myQueryID");
$this->bug->buildSearchForm($productID, $this->products, $queryID, $actionURL);
$this->loadModel('search')->setSearchParams($this->config->bug->search);
/* Set view. */
$this->view->title = $this->products[$productID] . $this->lang->colon . $this->lang->bug->common;
@@ -882,72 +881,66 @@ class bug extends control
* Link related bugs.
*
* @param int $bugID
* @param string $bugs
* @param string $browseType
* @param int $param
* @access public
* @return void
*/
public function linkBugs($bugID, $bugs = '', $browseType = '', $param = 0)
public function linkBugs($bugID, $browseType = '', $param = 0)
{
/* Link bugs. */
if(!empty($_POST))
{
$bugs = $this->bug->linkBugs($bugID, $bugs);
if(isonlybody()) die(js::closeModal('parent.parent', '', "function(){parent.parent.loadLinkedBugs('$bugID', '$bugs')}"));
$this->bug->linkBugs($bugID);
if(isonlybody()) die(js::closeModal('parent.parent', '', "function(){parent.parent.loadLinkBugs('$bugID')}"));
die(js::locate($this->createLink('bug', 'edit', "bugID=$bugID"), 'parent'));
}
/* Get bug, productID and queryID. */
$bug = $this->bug->getById($bugID);
$productID = $this->product->saveState($bug->product, $this->products);
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Get bug and queryID. */
$bug = $this->bug->getById($bugID);
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Set the menu. */
$this->bug->setMenu($this->products, $productID, $bug->branch);
$this->bug->setMenu($this->products, $bug->product, $bug->branch);
/* Build the search form. */
$actionURL = $this->createLink('bug', 'linkBugs', "bugID=$bugID&bugs=$bugs&browseType=bySearch&queryID=myQueryID", '', true);
$this->bug->buildSearchForm($productID, $this->products, $queryID, $actionURL);
$this->loadModel('search')->setSearchParams($this->config->bug->search);
$actionURL = $this->createLink('bug', 'linkBugs', "bugID=$bugID&browseType=bySearch&queryID=myQueryID", '', true);
$this->bug->buildSearchForm($bug->product, $this->products, $queryID, $actionURL);
/* Get bugs to link. */
$allBugs = array();
if($browseType == 'bySearch') $allBugs = $this->bug->getBySearch($bug->product, $quueryID, 'id', null);
$bugs2Link = $this->bug->getBugs2Link($bugID, $browseType, $queryID);
/* Assign. */
$this->view->title = $this->lang->bug->linkBugs . "BUG #$bug->id $bug->title - " . $this->products[$productID];
$this->view->position[] = html::a($this->createLink('product', 'view', "productID=$productID"), $this->products[$productID]);
$this->view->title = $this->lang->bug->linkBugs . "BUG #$bug->id $bug->title - " . $this->products[$bug->product];
$this->view->position[] = html::a($this->createLink('product', 'view', "productID=$bug->product"), $this->products[$bug->product]);
$this->view->position[] = html::a($this->createLink('bug', 'view', "bugID=$bugID"), $bug->title);
$this->view->position[] = $this->lang->bug->linkBugs;
$this->view->bug = $bug;
$this->view->allBugs = $allBugs;
$this->view->bugs2Link = $bugs2Link;
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->display();
}
/**
* AJAX: get linked bugs.
* AJAX: get linkBugs.
*
* @param int $bugID
* @param string $linkedBugs
* @access public
* @return string
*/
public function ajaxGetLinkedBugs($bugID, $linkedBugs = '')
public function ajaxGetLinkBugs($bugID)
{
/* Get bug and linked bugs. */
$bug = $this->bug->getById($bugID);
$bugs = $this->bug->getLinkedBugs($linkedBugs);
/* Get linkbugs. */
$bugs = $this->bug->getLinkBugs($bugID);
/* Build linkBug list.*/
$output = '';
foreach($bugs as $bugId => $title)
foreach($bugs as $bugId => $bugTitle)
{
$output .= '<li>';
$output .= html::a(inlink('view', "bugID=$bugId"), "#$bugId " . $title);
$output .= html::a("javascript:deleteLinkedBug($bugID, $bugId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= html::a(inlink('view', "bugID=$bugId"), "#$bugId " . $bugTitle, '_blank');
$output .= html::a("javascript:unlinkBug($bugID, $bugId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
@@ -955,24 +948,29 @@ class bug extends control
}
/**
* AJAX: delete a linked bug.
* AJAX: unlink related bug.
*
* @param int $bugID
* @param int $deleteBug
* @param int $bug2Unlink
* @access public
* @return string
*/
public function ajaxDeleteLinkedBug($bugID, $deleteBug)
public function ajaxUnlinkBug($bugID, $bug2Unlink = 0)
{
/* Get bug and bugs. */
$bug = $this->bug->getById($bugID);
$bugs = $this->bug->deleteLinkedBug($bugID, $deleteBug);
/* Unlink related bug. */
$this->bug->unlinkBug($bugID, $bug2Unlink);
/* Get current linkbugs. */
$bugs = $this->bug->getLinkBugs($bugID);
/* Build linkBug list. */
$output = '';
foreach($bugs as $bugId => $title)
$output = '';
foreach($bugs as $bugId => $bugTitle)
{
$output .= '<li>' . html::a(inlink('view', "bugID=$bugId"), "#$bugId " . $title) . html::a("javascript:deleteLinkedBug($bugID, $bugId)", '<i class="icon-remove"></i>', '', "style='float:right'");
$output .= '<li>';
$output .= html::a(inlink('view', "bugID=$bugId"), "#$bugId " . $bugTitle, '_blank');
$output .= html::a("javascript:unlinkBug($bugID, $bugId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
die($output);
+1 -1
View File
@@ -1 +1 @@
#linkBugsForm {min-height: 200px}
#linkBugsForm {min-height: 300px}
+8 -9
View File
@@ -56,29 +56,28 @@ function loadModuleRelated()
}
/**
* Delete a linked bug.
* Unlink related bug.
*
* @param int $bugID
* @param int $deleteBug
* @param int $bug2Unlink
* @access public
* @return void
*/
function deleteLinkedBug(bugID, deleteBug)
function unlinkBug(bugID, bug2Unlink)
{
deleteLink = createLink('bug', 'ajaxDeleteLinkedBug', 'bugID=' + bugID + '&deleteBug=' + deleteBug);
$('#linkBugBox').load(deleteLink);
link = createLink('bug', 'ajaxUnlinkBug', 'bugID=' + bugID + '&bug2Unlink=' + bug2Unlink);
$('#linkBugBox').load(link);
}
/**
* Load linked bugs.
* Load linkBugs.
*
* @param int $bugID
* @param string $linkedBugs
* @access public
* @return void
*/
function loadLinkedBugs(bugID, linkedBugs)
function loadLinkBugs(bugID)
{
bugLink = createLink('bug', 'ajaxGetLinkedBugs', 'bugID=' + bugID + '&linkedBugs=' + linkedBugs);
bugLink = createLink('bug', 'ajaxGetLinkBugs', 'bugID=' + bugID);
$('#linkBugBox').load(bugLink);
}
+2 -38
View File
@@ -15,10 +15,8 @@ $lang->bug->id = 'ID';
$lang->bug->product = $lang->productCommon;
$lang->bug->productplan = 'Plan';
$lang->bug->module = 'Module';
$lang->bug->path = 'Path';
$lang->bug->project = $lang->projectCommon;
$lang->bug->story = 'Story';
$lang->bug->storyVersion = 'Story Version';
$lang->bug->task = 'Task';
$lang->bug->title = 'Title';
$lang->bug->severity = 'Severity';
@@ -26,22 +24,16 @@ $lang->bug->severityAB = 'S';
$lang->bug->pri = 'Priority';
$lang->bug->type = 'Type';
$lang->bug->os = 'OS';
$lang->bug->plan = 'Plan';
$lang->bug->hardware = 'Hardware';
$lang->bug->browser = 'Browser';
$lang->bug->machine = 'Machine';
$lang->bug->found = 'How found';
$lang->bug->steps = 'Steps';
$lang->bug->status = 'Status';
$lang->bug->statusAB = 'Status';
$lang->bug->activatedCount = 'Activated count';
$lang->bug->activatedCountAB = 'Activated count';
$lang->bug->confirmed = 'Confirmed';
$lang->bug->toTask = 'To task';
$lang->bug->toStory = 'To story';
$lang->bug->mailto = 'Mailto';
$lang->bug->openedBy = 'Opened By';
$lang->bug->openedByAB = 'Opened';
$lang->bug->openedDate = 'Opened date';
$lang->bug->openedDateAB = 'Date';
$lang->bug->openedBuild = 'Opened Build';
@@ -58,7 +50,6 @@ $lang->bug->closedBy = 'Closed By';
$lang->bug->closedDate = 'Closed Date';
$lang->bug->duplicateBug = 'Duplicate';
$lang->bug->lastEditedBy = 'Last Edited By';
$lang->bug->lastEditedDate = 'Last Edited Date';
$lang->bug->linkBug = 'Related';
$lang->bug->linkBugs = 'Link bugs';
$lang->bug->case = 'Case';
@@ -92,15 +83,9 @@ $lang->bug->delete = 'Delete Bug';
$lang->bug->deleted = 'Deleted';
$lang->bug->saveTemplate = 'Save template';
$lang->bug->deleteTemplate = 'Delete template';
$lang->bug->customFields = 'Custom';
$lang->bug->restoreDefault = 'Default';
$lang->bug->ajaxGetUserBugs = 'API: My Bugs';
$lang->bug->ajaxGetModuleOwner = 'API: Get module default owner';
$lang->bug->confirmStoryChange = 'Confirm Story Change';
/* Browse tabs. */
$lang->bug->selectProduct = "Select {$lang->productCommon}";
$lang->bug->byModule = 'ByModule';
$lang->bug->assignToMe = 'MyBugs';
$lang->bug->openedByMe = 'MyOpen';
$lang->bug->resolvedByMe = 'MyResolve';
@@ -112,51 +97,30 @@ $lang->bug->unclosed = 'Unclosed';
$lang->bug->longLifeBugs = 'Longlife';
$lang->bug->postponedBugs = 'Postponed';
$lang->bug->allBugs = 'Allbug';
$lang->bug->moduleBugs = 'ByModule';
$lang->bug->byQuery = 'Search';
$lang->bug->needConfirm = 'StoryChanged';
$lang->bug->allProduct = "All {$lang->productCommon}s";
$lang->bug->ditto = 'Ditto';
/* Labels. */
$lang->bug->lblProductAndModule = "{$lang->productCommon}&Module";
$lang->bug->lblProjectAndTask = "{$lang->projectCommon}&Task";
$lang->bug->lblStory = 'Story';
$lang->bug->lblTypeAndSeverity = 'Type&Severity';
$lang->bug->lblSystemBrowserAndHardware = 'OS&Browser';
$lang->bug->lblAssignedTo = 'Assigned to';
$lang->bug->lblMailto = 'Mailto';
$lang->bug->lblLastEdited = 'Last edited';
$lang->bug->lblResolved = 'Resolved';
$lang->bug->lblAllFields = 'All Fields';
$lang->bug->lblCustomFields = 'Custom Fields';
$lang->bug->allUsers = 'All users';
$lang->bug->allBuilds = 'All';
/* Legends. */
$lang->bug->legendBasicInfo = 'Basic info';
$lang->bug->legendMailto = 'Mailto';
$lang->bug->legendAttatch = 'Files';
$lang->bug->legendLinkBugs = 'Related bug';
$lang->bug->legendPrjStoryTask = "{$lang->projectCommon}, story & task";
$lang->bug->legendCases = 'Related case';
$lang->bug->legendSteps = 'Steps';
$lang->bug->legendAction = 'Action';
$lang->bug->legendHistory = 'History';
$lang->bug->legendComment = 'Comment';
$lang->bug->legendLife = 'Lifetime';
$lang->bug->legendMisc = 'Misc';
/* Action buttons. */
$lang->bug->buttonConfirm = 'Confirm';
$lang->bug->buttonCopy = 'Copy';
$lang->bug->buttonAssign = 'Assgin';
$lang->bug->buttonEdit = 'Edit';
$lang->bug->buttonActivate = 'Activate';
$lang->bug->buttonResolve = 'Resolve';
$lang->bug->buttonClose = 'Close';
$lang->bug->buttonToList = 'Back';
$lang->bug->buttonCreateTestcase = 'Create Case';
/* Confirm messags. */
$lang->bug->confirmChangeProduct = "Change {$lang->productCommon} will change {$lang->projectCommon}, task and story also, are you sure?";
@@ -360,8 +324,8 @@ $lang->bug->action->tostory = array('main' => '$date, To story by <stro
$lang->bug->action->totask = array('main' => '$date, To task by <strong>$actor</strong>, ID is <strong>$extra</strong>.');
$lang->bug->action->linked2plan = array('main' => '$date, Link to plan by <strong>$actor</strong>,ID is <strong>$extra</strong>。');
$lang->bug->action->unlinkedfromplan = array('main' => '$date, Unlink from plan <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->bug->action->linked2bug = array('main' => '$date, linked related bugs <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->bug->action->unlinkedbug = array('main' => '$date, removed related bugs <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->bug->action->linkrelatedbug = array('main' => '$date, link related bug <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->bug->action->unlinkrelatedbug = array('main' => '$date, unlink related bug <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->bug->placeholder = new stdclass();
$lang->bug->placeholder->chooseBuilds = 'Choose builds...';
+2 -38
View File
@@ -15,10 +15,8 @@ $lang->bug->id = 'Bug编号';
$lang->bug->product = '所属' . $lang->productCommon;
$lang->bug->productplan = '所属计划';
$lang->bug->module = '所属模块';
$lang->bug->path = '模块路径';
$lang->bug->project = '所属' . $lang->projectCommon;
$lang->bug->story = '相关需求';
$lang->bug->storyVersion = '需求版本';
$lang->bug->task = '相关任务';
$lang->bug->title = 'Bug标题';
$lang->bug->severity = '严重程度';
@@ -26,22 +24,16 @@ $lang->bug->severityAB = '级别';
$lang->bug->pri = '优先级';
$lang->bug->type = 'Bug类型';
$lang->bug->os = '操作系统';
$lang->bug->plan = '所属计划';
$lang->bug->hardware = '硬件平台';
$lang->bug->browser = '浏览器';
$lang->bug->machine = '机器硬件';
$lang->bug->found = '如何发现';
$lang->bug->steps = '重现步骤';
$lang->bug->status = 'Bug状态';
$lang->bug->statusAB = '状态';
$lang->bug->activatedCount = '激活次数';
$lang->bug->activatedCountAB = '激活次数';
$lang->bug->confirmed = '是否确认';
$lang->bug->toTask = '转任务';
$lang->bug->toStory = '转需求';
$lang->bug->mailto = '抄送给';
$lang->bug->openedBy = '由谁创建';
$lang->bug->openedByAB = '创建';
$lang->bug->openedDate = '创建日期';
$lang->bug->openedDateAB = '创建日期';
$lang->bug->openedBuild = '影响版本';
@@ -58,7 +50,6 @@ $lang->bug->closedBy = '由谁关闭';
$lang->bug->closedDate = '关闭日期';
$lang->bug->duplicateBug = '重复ID';
$lang->bug->lastEditedBy = '最后修改者';
$lang->bug->lastEditedDate = '最后修改日期';
$lang->bug->linkBug = '相关Bug';
$lang->bug->linkBugs = '关联Bug';
$lang->bug->case = '相关用例';
@@ -92,15 +83,9 @@ $lang->bug->delete = '删除';
$lang->bug->deleted = '已删除';
$lang->bug->saveTemplate = '保存模板';
$lang->bug->deleteTemplate = '删除模板';
$lang->bug->customFields = '自定义字段';
$lang->bug->restoreDefault = '恢复默认';
$lang->bug->ajaxGetUserBugs = '接口:我的Bug';
$lang->bug->ajaxGetModuleOwner = '接口:获得模块的默认指派人';
$lang->bug->confirmStoryChange = '确认需求变动';
/* 查询条件列表。*/
$lang->bug->selectProduct = '请选择' . $lang->productCommon;
$lang->bug->byModule = '按模块';
$lang->bug->assignToMe = '指派给我';
$lang->bug->openedByMe = '由我创建';
$lang->bug->resolvedByMe = '由我解决';
@@ -112,51 +97,30 @@ $lang->bug->unclosed = '未关闭';
$lang->bug->longLifeBugs = '久未处理';
$lang->bug->postponedBugs = '被延期';
$lang->bug->allBugs = '所有';
$lang->bug->moduleBugs = '按模块';
$lang->bug->byQuery = '搜索';
$lang->bug->needConfirm = '需求变动';
$lang->bug->allProduct = '所有' . $lang->productCommon;
$lang->bug->ditto = '同上';
/* 页面标签。*/
$lang->bug->lblProductAndModule = $lang->productCommon . '模块';
$lang->bug->lblProjectAndTask = $lang->projectCommon . '任务';
$lang->bug->lblStory = '相关需求';
$lang->bug->lblTypeAndSeverity = '类型/严重程度';
$lang->bug->lblSystemBrowserAndHardware = '系统/浏览器';
$lang->bug->lblAssignedTo = '当前指派';
$lang->bug->lblMailto = '抄送给';
$lang->bug->lblLastEdited = '最后修改';
$lang->bug->lblResolved = '由谁解决';
$lang->bug->lblAllFields = '所有字段';
$lang->bug->lblCustomFields = '自定义字段';
$lang->bug->allUsers = '所有用户';
$lang->bug->allBuilds = '所有';
/* legend列表。*/
$lang->bug->legendBasicInfo = '基本信息';
$lang->bug->legendMailto = '抄送给';
$lang->bug->legendAttatch = '附件';
$lang->bug->legendLinkBugs = '相关Bug';
$lang->bug->legendPrjStoryTask = $lang->projectCommon . '/需求/任务';
$lang->bug->legendCases = '相关用例';
$lang->bug->legendSteps = '重现步骤';
$lang->bug->legendAction = '操作';
$lang->bug->legendHistory = '历史记录';
$lang->bug->legendComment = '备注';
$lang->bug->legendLife = 'BUG的一生';
$lang->bug->legendMisc = '其他相关';
/* 功能按钮。*/
$lang->bug->buttonConfirm = '确认';
$lang->bug->buttonCopy = '复制';
$lang->bug->buttonAssign = '指派';
$lang->bug->buttonEdit = '编辑';
$lang->bug->buttonActivate = '激活';
$lang->bug->buttonResolve = '解决';
$lang->bug->buttonClose = '关闭';
$lang->bug->buttonToList = '返回';
$lang->bug->buttonCreateTestcase = '转用例';
/* 交互提示。*/
$lang->bug->confirmChangeProduct = "修改{$lang->productCommon}会导致相应的{$lang->projectCommon}、需求和任务发生变化,确定吗?";
@@ -360,8 +324,8 @@ $lang->bug->action->tostory = array('main' => '$date, 由 <strong>$acto
$lang->bug->action->totask = array('main' => '$date, 由 <strong>$actor</strong> 导入为<strong>任务</strong>,编号为 <strong>$extra</strong>。');
$lang->bug->action->linked2plan = array('main' => '$date, 由 <strong>$actor</strong> 关联到计划 <strong>$extra</strong>。');
$lang->bug->action->unlinkedfromplan = array('main' => '$date, 由 <strong>$actor</strong> 从计划 <strong>$extra</strong> 移除。');
$lang->bug->action->linked2bug = array('main' => '$date, 由 <strong>$actor</strong> 关联相关Bug <strong>$extra</strong>。');
$lang->bug->action->unlinkedbug = array('main' => '$date, 由 <strong>$actor</strong> 移除相关Bug <strong>$extra</strong>。');
$lang->bug->action->linkrelatedbug = array('main' => '$date, 由 <strong>$actor</strong> 关联相关Bug <strong>$extra</strong>。');
$lang->bug->action->unlinkrelatedbug = array('main' => '$date, 由 <strong>$actor</strong> 移除相关Bug <strong>$extra</strong>。');
$lang->bug->placeholder = new stdclass();
$lang->bug->placeholder->chooseBuilds = '选择相关版本...';
+50 -21
View File
@@ -795,61 +795,88 @@ class bugModel extends model
}
/**
* Link bugs.
* Link related bugs.
*
* @param int $bugID
* @param string $bugs
* @access public
* @return string
* @return void
*/
public function linkBugs($bugID, $bugs = '')
public function linkBugs($bugID)
{
if($this->post->bugs == false) return $bugs;
if($this->post->bugs == false) return;
$bugs = implode(',', $this->post->bugs) . ',' . trim($bugs, ',');
$bug = $this->getById($bugID);
$bugs2Link = $this->post->bugs;
$bugs = implode(',', $bugs2Link) . ',' . trim($bug->linkBug, ',');
$this->dao->update(TABLE_BUG)->set('linkBug')->eq(trim($bugs, ','))->where('id')->eq($bugID)->exec();
if(dao::isError()) die(js::error(dao::getError()));
$this->loadModel('action')->create('bug', $bugID, 'linked2Bug', '', implode(',', $this->post->bugs));
return $bugs;
$this->loadModel('action')->create('bug', $bugID, 'linkRelatedBug', '', implode(',', $bugs2Link));
}
/**
* Delete a linked bug.
* Get bugs to link.
*
* @param int $bugID
* @param int $deleteBug
* @param string $browseType
* @param int $queryID
* @access public
* @return array
*/
public function deleteLinkedBug($bugID, $deleteBug = 0)
public function getBugs2Link($bugID, $browseType = 'bySearch', $queryID)
{
$bug = $this->getById($bugID);
if($browseType == 'bySearch')
{
$bug = $this->getById($bugID);
$bugs2Link = $this->getBySearch($bug->product, $queryID, 'id', null);
foreach($bugs2Link as $key => $bug2Link)
{
if($bug2Link->id == $bugID) unset($bugs2Link[$key]);
if(in_array($bug2Link->id, explode(',', $bug->linkBug))) unset($bugs2Link[$key]);
}
return $bugs2Link;
}
else
{
return array();
}
}
/**
* Unlink related bug.
*
* @param int $bugID
* @param int $bug2Unlink
* @access public
* @return void
*/
public function unlinkBug($bugID, $bug2Unlink = 0)
{
$bug = $this->getById($bugID);
$bugs = explode(',', trim($bug->linkBug, ','));
foreach($bugs as $key => $bugId)
{
if($bugId == $deleteBug) unset($bugs[$key]);
if($bugId == $bug2Unlink) unset($bugs[$key]);
}
$bugs = implode(',', $bugs);
$this->dao->update(TABLE_BUG)->set('linkBug')->eq($bugs)->where('id')->eq($bugID)->exec();
if(dao::isError()) die(js::error(dao::getError()));
$this->loadModel('action')->create('bug', $bugID, 'unLinkedBug', '', $deleteBug);
return $this->getLinkedBugs($bugs);
$this->loadModel('action')->create('bug', $bugID, 'unlinkRelatedBug', '', $bug2Unlink);
}
/**
* Get linked bugs.
* Get linkBugs.
*
* @param string $bugs
* @param int $bugID
* @access public
* @return array
*/
public function getLinkedBugs($bugs)
public function getLinkBugs($bugID)
{
return $this->dao->select('id, title')->from(TABLE_BUG)->where('id')->in($bugs)->fetchPairs();
$bug = $this->getById($bugID);
return $this->dao->select('id, title')->from(TABLE_BUG)->where('id')->in($bug->linkBug)->fetchPairs();
}
/**
@@ -882,6 +909,8 @@ class bugModel extends model
$this->config->bug->search['fields']['branch'] = $this->lang->product->branch;
$this->config->bug->search['params']['branch']['values'] = array('' => '') + $this->loadModel('branch')->getPairs($productID, 'noempty');
}
$this->loadModel('search')->setSearchParams($this->config->bug->search);
}
/**
+3 -3
View File
@@ -233,7 +233,7 @@ js::set('oldResolvedBuild' , $bug->resolvedBuild);
<tr class='text-top'>
<th class='w-80px'><?php echo $lang->bug->linkBug;?></th>
<td>
<?php echo html::a($this->createLink('bug', 'linkBugs', "bugID=$bug->id&bugs=$bug->linkBug", '', true), $lang->bug->linkBugs, '', "data-toggle='modal' data-type='iframe' data-width='85%'");?>
<?php echo html::a($this->createLink('bug', 'linkBugs', "bugID=$bug->id", '', true), $lang->bug->linkBugs, '', "data-toggle='modal' data-type='iframe' data-width='95%'");?>
<ul class='list-unstyled' id='linkBugBox'>
<?php
if(isset($bug->linkBugTitles))
@@ -241,8 +241,8 @@ js::set('oldResolvedBuild' , $bug->resolvedBuild);
foreach($bug->linkBugTitles as $linkBugID => $linkBugTitle)
{
echo '<li>';
echo html::a(inlink('view', "bugID=$linkBugID"), "#$linkBugID " . $linkBugTitle);
echo html::a("javascript:deleteLinkedBug($bug->id, $linkBugID)", '<i class="icon-remove"></i>', '', "title='{$lang->unlink}' style='float:right'");
echo html::a(inlink('view', "bugID=$linkBugID"), "#$linkBugID " . $linkBugTitle, '_blank');
echo html::a("javascript:unlinkBug($bug->id, $linkBugID)", '<i class="icon-remove"></i>', '', "title='{$lang->unlink}' style='float:right'");
echo '</li>';
}
}
+13 -12
View File
@@ -22,7 +22,7 @@
</div>
<form method='post' class='form-condensed' target='hiddenwin' id='linkBugsForm'>
<table class='table table-condensed table-hover table-striped tablesorter' id='bugList'>
<?php if($allBugs):?>
<?php if($bugs2Link):?>
<thead>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
@@ -36,21 +36,19 @@
</thead>
<tbody>
<?php $bugCount = 0;?>
<?php foreach($allBugs as $bugDetail):?>
<?php if(in_array($bugDetail->id, explode(',', $bug->linkBug))) continue;?>
<?php if($bugDetail->id == $bug->id) continue;?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bugDetail->id");?>
<?php foreach($bugs2Link as $bug2Link):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug2Link->id");?>
<tr class='text-center'>
<td class='text-left'>
<input type='checkbox' name='bugs[]' value='<?php echo $bugDetail->id;?>'/>
<?php echo html::a($bugLink, sprintf('%03d', $bugDetail->id));?>
<input type='checkbox' name='bugs[]' value='<?php echo $bug2Link->id;?>'/>
<?php echo html::a($bugLink, sprintf('%03d', $bug2Link->id));?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bugDetail->pri, $bugDetail->pri)?>'><?php echo zget($lang->bug->priList, $bugDetail->pri, $bugDetail->pri);?></span></td>
<td><?php echo html::a($this->createLink('product', 'browse', "productID=$bugDetail->product&branch=$bugDetail->branch"), $products[$bugDetail->product], '_blank');?></td>
<td class='text-left nobr' title="<?php echo $bugDetail->title?>"><?php echo html::a($bugLink, $bugDetail->title);?></td>
<td><span class='<?php echo 'pri' . zget($lang->bug->priList, $bug2Link->pri, $bug2Link->pri)?>'><?php echo zget($lang->bug->priList, $bug2Link->pri, $bug2Link->pri);?></span></td>
<td><?php echo html::a($this->createLink('product', 'browse', "productID=$bug2Link->product&branch=$bug2Link->branch"), $products[$bug2Link->product], '_blank');?></td>
<td class='text-left nobr' title="<?php echo $bug2Link->title?>"><?php echo html::a($bugLink, $bug2Link->title);?></td>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
<td><?php echo $users[$bugDetail->openedBy];?></td>
<td><?php echo $users[$bugDetail->assignedTo];?></td>
<td><?php echo $users[$bug2Link->openedBy];?></td>
<td><?php echo $users[$bug2Link->assignedTo];?></td>
</tr>
<?php $bugCount ++;?>
<?php endforeach;?>
@@ -63,6 +61,9 @@
</div>
</td>
</tr>
<tr>
<td class='hidden'><?php echo html::input('bug', $bug->id);?></td>
</tr>
</tfoot>
<?php endif;?>
</table>
+14 -14
View File
@@ -279,6 +279,20 @@
</div>
<div class='tab-pane' id='legendMisc'>
<table class='table table-data table-condensed table-borderless table-fixed'>
<tr class='text-top'>
<th class='w-60px'><?php echo $lang->bug->linkBug;?></th>
<td>
<?php
if(isset($bug->linkBugTitles))
{
foreach($bug->linkBugTitles as $linkBugID => $linkBugTitle)
{
echo html::a($this->createLink('bug', 'view', "bugID=$linkBugID"), "#$linkBugID $linkBugTitle", '_blank') . '<br />';
}
}
?>
</td>
</tr>
<?php if($bug->case):?>
<tr>
<th class='w-60px'><?php echo $lang->bug->fromCase;?></th>
@@ -298,20 +312,6 @@
</td>
</tr>
<?php endif;?>
<tr class='text-top'>
<th class='w-60px'><?php echo $lang->bug->linkBug;?></th>
<td>
<?php
if(isset($bug->linkBugTitles))
{
foreach($bug->linkBugTitles as $linkBugID => $linkBugTitle)
{
echo html::a($this->createLink('bug', 'view', "bugID=$linkBugID"), "#$linkBugID $linkBugTitle", '_blank') . '<br />';
}
}
?>
</td>
</tr>
<?php if($bug->toStory != 0):?>
<tr>
<th><?php echo $lang->bug->toStory;?></th>
-6
View File
@@ -17,8 +17,6 @@ $lang->build->linkBug = "Link Bug";
$lang->build->delete = "Delete";
$lang->build->deleted = "Deleted";
$lang->build->view = "Info";
$lang->build->ajaxGetProductBuilds = "API:{$lang->productCommon} builds";
$lang->build->ajaxGetProjectBuilds = "API:{$lang->projectCommon} builds";
$lang->build->batchUnlink = 'Batch unlink';
$lang->build->batchUnlinkStory = 'Batch unlink story';
$lang->build->batchUnlinkBug = 'Batch unlink bug';
@@ -31,7 +29,6 @@ $lang->build->basicInfo = 'Basic Info';
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->project = $lang->projectCommon;
$lang->build->name = 'Name';
$lang->build->date = 'Build date';
$lang->build->builder = 'Builder';
@@ -40,10 +37,7 @@ $lang->build->filePath = 'Package file path';
$lang->build->desc = 'Desc';
$lang->build->files = 'Upload package';
$lang->build->last = 'Last build';
$lang->build->linkStoriesAndBugs = 'stories and bugs';
$lang->build->linkStories = 'Stories';
$lang->build->unlinkStory = 'Remove story';
$lang->build->linkBugs = 'Bugs';
$lang->build->unlinkBug = 'Remove bug';
$lang->build->stories = 'Finished stories';
$lang->build->bugs = 'Resolved bugs';
-6
View File
@@ -17,8 +17,6 @@ $lang->build->linkBug = "关联Bug";
$lang->build->delete = "删除版本";
$lang->build->deleted = "已删除";
$lang->build->view = "版本详情";
$lang->build->ajaxGetProductBuilds = "接口:{$lang->productCommon}版本列表";
$lang->build->ajaxGetProjectBuilds = "接口:{$lang->projectCommon}版本列表";
$lang->build->batchUnlink = '批量移除';
$lang->build->batchUnlinkStory = '批量移除需求';
$lang->build->batchUnlinkBug = '批量移除Bug';
@@ -31,7 +29,6 @@ $lang->build->basicInfo = '基本信息';
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->project = $lang->projectCommon;
$lang->build->name = '名称编号';
$lang->build->date = '打包日期';
$lang->build->builder = '构建者';
@@ -40,10 +37,7 @@ $lang->build->filePath = '下载地址';
$lang->build->desc = '描述';
$lang->build->files = '上传发行包';
$lang->build->last = '上个版本';
$lang->build->linkStoriesAndBugs = '关联需求和Bug';
$lang->build->linkStories = '相关需求';
$lang->build->unlinkStory = '移除需求';
$lang->build->linkBugs = '相关Bug';
$lang->build->unlinkBug = '移除Bug';
$lang->build->stories = '完成的需求';
$lang->build->bugs = '解决的Bug';
+1 -15
View File
@@ -20,8 +20,6 @@ $lang->ellipsis = '...';
$lang->zentaoPMS = 'zentao';
$lang->welcome = "%s PMS";
$lang->myControl = "Dashboard";
$lang->currentPos = 'Current';
$lang->logout = 'Logout';
$lang->login = 'Login';
$lang->aboutZenTao = 'About';
@@ -31,25 +29,20 @@ $lang->runInfo = "<div class='row'><div class='u-1 a-center' id='debugbar
$lang->agreement = "I Agree to the <a href='http://zpl.pub/page/zplv12.html' target='_blank'>Z PUBLIC LICENSE 1.2</a>, <span class='text-danger'>and promise to keep the logo, link of ZenTao.</span>";
$lang->reset = 'Reset';
$lang->cancel = 'Cancel';
$lang->refresh = 'Refresh';
$lang->edit = 'Edit';
$lang->copy = 'Copy';
$lang->delete = 'Delete';
$lang->close = 'Close';
$lang->link = 'Link';
$lang->unlink = 'Unlink';
$lang->import = 'Import';
$lang->export = 'Export';
$lang->setFileName = 'Filename:';
$lang->activate = 'Activate';
$lang->submitting = 'Saving...';
$lang->save = 'Save';
$lang->confirm = 'Confirm';
$lang->preview = 'View';
$lang->goback = 'Back';
$lang->goPC = 'PC';
$lang->go = 'GO';
$lang->more = 'More';
$lang->day = 'Day';
@@ -59,7 +52,6 @@ $lang->history = 'History';
$lang->attatch = 'Attatch';
$lang->reverse = 'Reverse';
$lang->switchDisplay= 'Toggle Show';
$lang->switchHelp = 'Toggle Help';
$lang->addFiles = 'Add Files';
$lang->files = 'Files ';
$lang->pasteText = 'Paste text';
@@ -76,9 +68,9 @@ $lang->nextShortcutKey = '[Shortcut key:→]';
$lang->select = 'Select';
$lang->selectAll = 'All';
$lang->selectReverse = 'Inverse';
$lang->loading = 'Wait...';
$lang->notFound = 'Sorry, the object not found.';
$lang->showAll = "[[Show all {$lang->projectCommon}s]]";
$lang->hideClosed = "[[Show {$lang->projectCommon}s going]]";
$lang->future = 'Future';
$lang->year = 'Year';
@@ -381,10 +373,6 @@ $lang->pager->next = "<i class='icon-play' title='Next'></i>";
$lang->pager->last = "<i class='icon-step-forward' title='Last'></i>";
$lang->pager->locate = "GO!";
$lang->zentaoSite = "Official Site";
$lang->chinaScrum = "<a href='http://api.zentao.net/goto.php?item=chinascrum' target='_blank'>Scrum community</a> ";
$lang->agileTraining = "<a href='http://api.zentao.net/goto.php?item=agiletrain' target='_blank'>Training</a> ";
$lang->donate = "<a href='http://api.zentao.net/goto.php?item=donate' target='_blank'>Donate</a> ";
$lang->proVersion = "<a href='http://api.zentao.net/goto.php?item=proversion&from=footer' target='_blank' class='text-important'><i class='text-danger icon-pro-version'></i> PRO</a> &nbsp; ";
$lang->downNotify = "Down notify";
@@ -394,8 +382,6 @@ $lang->noticeImport = "<p style='font-size:14px'>Import data, containing the ex
$lang->noResultsMatch = "No results match";
$lang->searchMore = "Search more results with the key:";
$lang->selectAnOption = "Select an option";
$lang->selectSomeOptions = "Select some options";
$lang->chooseUsersToMail = "Choose users to mail...";
/* Date times. */
-15
View File
@@ -20,8 +20,6 @@ $lang->ellipsis = '…';
$lang->zentaoPMS = '禅道';
$lang->welcome = "%s项目管理系统";
$lang->myControl = "我的地盘";
$lang->currentPos = '当前位置:';
$lang->logout = '退出';
$lang->login = '登录';
$lang->aboutZenTao = '关于';
@@ -31,25 +29,20 @@ $lang->runInfo = "<div class='row'><div class='u-1 a-center' id='debugbar
$lang->agreement = "已阅读并同意<a href='http://zpl.pub/page/zplv12.html' target='_blank'>《Z PUBLIC LICENSE授权协议1.2》</a>。<span class='text-danger'>未经许可,不得去除、隐藏或遮掩禅道软件的任何标志及链接。</span>";
$lang->reset = '重填';
$lang->cancel = '取消';
$lang->refresh = '刷新';
$lang->edit = '编辑';
$lang->copy = '复制';
$lang->delete = '删除';
$lang->close = '关闭';
$lang->link = '关联';
$lang->unlink = '移除';
$lang->import = '导入';
$lang->export = '导出';
$lang->setFileName = '文件名:';
$lang->activate = '激活';
$lang->submitting = '稍候...';
$lang->save = '保存';
$lang->confirm = '确认';
$lang->preview = '查看';
$lang->goback = '返回';
$lang->goPC = 'PC版';
$lang->go = 'GO';
$lang->more = '更多';
$lang->day = '天';
@@ -59,7 +52,6 @@ $lang->history = '历史记录';
$lang->attatch = '附件';
$lang->reverse = '切换顺序';
$lang->switchDisplay= '切换显示';
$lang->switchHelp = '切换帮助';
$lang->addFiles = '上传了附件 ';
$lang->files = '附件 ';
$lang->pasteText = '粘贴文本 ';
@@ -79,7 +71,6 @@ $lang->selectReverse = '反选';
$lang->loading = '稍候...';
$lang->notFound = '抱歉,您访问的对象并不存在!';
$lang->showAll = '[[全部显示]]';
$lang->hideClosed = '[[显示进行中]]';
$lang->future = '未来';
$lang->year = '年';
@@ -382,10 +373,6 @@ $lang->pager->next = "<i class='icon-play' title='下一页'></i>";
$lang->pager->last = "<i class='icon-step-forward' title='末页'></i>";
$lang->pager->locate = "GO!";
$lang->zentaoSite = "官方网站";
$lang->chinaScrum = "<a href='http://api.zentao.net/goto.php?item=chinascrum' target='_blank'>Scrum社区</a>&nbsp; ";
$lang->agileTraining = "<a href='http://api.zentao.net/goto.php?item=agiletrain' target='_blank'>培训</a> ";
$lang->donate = "<a href='http://api.zentao.net/goto.php?item=donate' target='_blank'>捐赠 </a>";
$lang->proVersion = "<a href='http://api.zentao.net/goto.php?item=proversion&from=footer' target='_blank' id='proLink' class='text-important'><i class='text-danger icon-pro-version'></i> 专业版!</a> &nbsp; ";
$lang->downNotify = "下载桌面提醒";
@@ -395,8 +382,6 @@ $lang->noticeImport = "<p style='font-size:14px'>导入数据中,含有已经
$lang->noResultsMatch = "没有匹配结果";
$lang->searchMore = "搜索此关键字的更多结果:";
$lang->selectAnOption = "选择一个选项";
$lang->selectSomeOptions = "选择一些选项";
$lang->chooseUsersToMail = "选择要发信通知的用户...";
/* 时间格式设置。*/
+2 -2
View File
@@ -822,7 +822,7 @@ class commonModel extends model
{
$id = (isset($_SESSION['testcaseOnlyCondition']) and !$_SESSION['testcaseOnlyCondition'] and $app->getModuleName() == 'testcase' and isset($preAndNext->pre->case)) ? 'case' : 'id';
$title = isset($preAndNext->pre->title) ? $preAndNext->pre->title : $preAndNext->pre->name;
$title = $lang->preShortcutKey . '#' . $preAndNext->pre->$id . ' ' . $title;
$title = '#' . $preAndNext->pre->$id . ' ' . $title . ' ' . $lang->preShortcutKey;
$link = $linkTemplate ? sprintf($linkTemplate, $preAndNext->pre->$id) : inLink('view', "ID={$preAndNext->pre->$id}");
echo html::a($link, '<i class="icon-pre icon-chevron-left"></i>', '', "id='pre' class='btn' title='{$title}'");
}
@@ -830,7 +830,7 @@ class commonModel extends model
{
$id = (isset($_SESSION['testcaseOnlyCondition']) and !$_SESSION['testcaseOnlyCondition'] and $app->getModuleName() == 'testcase' and isset($preAndNext->next->case)) ? 'case' : 'id';
$title = isset($preAndNext->next->title) ? $preAndNext->next->title : $preAndNext->next->name;
$title = $lang->nextShortcutKey . '#' . $preAndNext->next->$id . ' ' . $title;
$title = '#' . $preAndNext->next->$id . ' ' . $title . ' ' . $lang->nextShortcutKey;
$link = $linkTemplate ? sprintf($linkTemplate, $preAndNext->next->$id) : inLink('view', "ID={$preAndNext->next->$id}");
echo html::a($link, '<i class="icon-pre icon-chevron-right"></i>', '', "id='next' class='btn' title='$title'");
}
-1
View File
@@ -68,7 +68,6 @@ class company extends control
$queryID = $type == 'bydept' ? 0 : (int)$param;
$actionURL = $this->createLink('company', 'browse', "param=myQueryID&type=bysearch");
$this->company->buildSearchForm($queryID, $actionURL);
$this->loadModel('search')->setSearchParams($this->config->company->browse->search);
/* Get users. */
$users = $this->company->getUsers($type, $queryID, $deptID, $sort, $pager);
-9
View File
@@ -11,20 +11,12 @@
*/
$lang->company->common = 'Company';
$lang->company->index = "Index";
$lang->company->create = "Create";
$lang->company->edit = "Edit";
$lang->company->view = "Info";
$lang->company->read = "Info";
$lang->company->update = "Update";
$lang->company->delete = "Delete";
$lang->company->browse = "User";
$lang->company->dynamic = "Dynamic";
$lang->company->depts = "Dept";
$lang->company->orgView = 'Company';
$lang->company->confirmDelete = "Are you sure to delete this company?";
$lang->company->id = 'ID';
$lang->company->name = 'Name';
$lang->company->phone = 'Phone';
$lang->company->fax = 'Fax';
@@ -32,7 +24,6 @@ $lang->company->address = 'Address';
$lang->company->zipcode = 'Zipcode';
$lang->company->website = 'Website';
$lang->company->backyard = 'Intranet';
$lang->company->pms = 'Zentao';
$lang->company->guest = 'Guest';
$lang->company->product = $lang->productCommon;
-9
View File
@@ -11,20 +11,12 @@
*/
$lang->company->common = '组织视图';
$lang->company->index = "组织视图首页";
$lang->company->create = "新增公司";
$lang->company->edit = "编辑公司";
$lang->company->view = "公司信息";
$lang->company->read = "公司信息";
$lang->company->update = "更新公司";
$lang->company->delete = "删除公司";
$lang->company->browse = "用户列表";
$lang->company->dynamic = "组织动态";
$lang->company->depts = "部门列表";
$lang->company->orgView = '组织视图';
$lang->company->confirmDelete = "您确定删除该公司吗?";
$lang->company->id = '编号';
$lang->company->name = '公司名称';
$lang->company->phone = '联系电话';
$lang->company->fax = '传真';
@@ -32,7 +24,6 @@ $lang->company->address = '通讯地址';
$lang->company->zipcode = '邮政编码';
$lang->company->website = '官网';
$lang->company->backyard = '内网';
$lang->company->pms = 'PMS网站';
$lang->company->guest = '匿名登录';
$lang->company->product = $lang->productCommon;
+4 -6
View File
@@ -78,7 +78,7 @@ class companyModel extends model
if($type == 'bydept')
{
$childDeptIds = $this->loadModel('dept')->getAllChildID($deptID);
$users = $this->dept->getUsers($childDeptIds, $pager, $sort);
return $this->dept->getUsers($childDeptIds, $pager, $sort);
}
else
{
@@ -95,12 +95,8 @@ class companyModel extends model
$this->session->set('userQuery', ' 1 = 1');
}
}
$users = $this->loadModel('user')->getByQuery($this->session->userQuery, $pager, $sort);
return $this->loadModel('user')->getByQuery($this->session->userQuery, $pager, $sort);
}
if($users) return $users;
return array();
}
/**
@@ -137,5 +133,7 @@ class companyModel extends model
$this->config->company->browse->search['actionURL'] = $actionURL;
$this->config->company->browse->search['queryID'] = $queryID;
$this->config->company->browse->search['params']['dept']['values'] = array('' => '') + $this->loadModel('dept')->getOptionMenu();
$this->loadModel('search')->setSearchParams($this->config->company->browse->search);
}
}
-8
View File
@@ -11,10 +11,6 @@
*/
$lang->convert->common = 'Import';
$lang->convert->index = 'Index';
$lang->convert->next = 'Next';
$lang->convert->pre = 'Back';
$lang->convert->reload = 'Reload';
$lang->convert->error = 'Error ';
$lang->convert->start = 'Begin import';
$lang->convert->desc = <<<EOT
@@ -31,8 +27,6 @@ $lang->convert->convertRedmine = 'Convert Redmine';
$lang->convert->convertBugFree = 'Convert BugFree';
$lang->convert->selectSource = 'Select source system and version';
$lang->convert->source = 'Source system';
$lang->convert->version = 'Version';
$lang->convert->mustSelectSource = "Must select a source system";
$lang->convert->direction = 'Please select the direction of issue in Redmine';
@@ -52,7 +46,6 @@ $lang->convert->checkConfig = 'Check setting';
$lang->convert->ok = 'Check passed(√)';
$lang->convert->fail = 'Check failed(×)';
$lang->convert->settingDB = 'Set database';
$lang->convert->dbHost = 'Database server';
$lang->convert->dbPort = 'Server port';
$lang->convert->dbUser = 'Database user';
@@ -97,7 +90,6 @@ $lang->convert->redmine->docLibs = 'DocLibs';
$lang->convert->redmine->docs = 'Docs';
$lang->convert->redmine->files = 'files';
$lang->convert->errorConnectDB = 'Connect to database server failed.';
$lang->convert->errorFileNotExits = 'File %s not exits.';
$lang->convert->errorUserExists = 'User %s exits already.';
$lang->convert->errorGroupExists = 'Group %s exits already.';
-8
View File
@@ -11,10 +11,6 @@
*/
$lang->convert->common = '从其他系统导入';
$lang->convert->index = '首页';
$lang->convert->next = '下一步';
$lang->convert->pre = '返回';
$lang->convert->reload = '刷新';
$lang->convert->error = '错误 ';
$lang->convert->start = '开始转换';
$lang->convert->desc = <<<EOT
@@ -31,8 +27,6 @@ $lang->convert->convertRedmine = '转换Redmine';
$lang->convert->convertBugFree = '转换BugFree';
$lang->convert->selectSource = '选择来源系统及版本';
$lang->convert->source = '来源系统';
$lang->convert->version = '版本';
$lang->convert->mustSelectSource = "必须选择一个来源。";
$lang->convert->direction = "请选择{$lang->projectCommon}问题转换方向";
@@ -52,7 +46,6 @@ $lang->convert->checkConfig = '检查配置';
$lang->convert->ok = '<span class="text-success"><i class="icon-ok-sign"></i> 检查通过</span>';
$lang->convert->fail = '<span class="text-danger"><i class="icon-remove-sign"></i> 检查失败</span>';
$lang->convert->settingDB = '设置数据库';
$lang->convert->dbHost = '数据库服务器';
$lang->convert->dbPort = '服务器端口';
$lang->convert->dbUser = '数据库用户名';
@@ -97,7 +90,6 @@ $lang->convert->redmine->docLibs = '文档库';
$lang->convert->redmine->docs = '文档';
$lang->convert->redmine->files = '附件';
$lang->convert->errorConnectDB = '数据库连接失败 ';
$lang->convert->errorFileNotExits = '文件 %s 不存在';
$lang->convert->errorUserExists = '用户 %s 已存在';
$lang->convert->errorGroupExists = '分组 %s 已存在';
-4
View File
@@ -10,8 +10,6 @@
* @link http://www.zentao.net
*/
$lang->dept->common = 'Department';
$lang->dept->add = "Add";
$lang->dept->addChild = "Add child department";
$lang->dept->manageChild = "Child deprtment";
$lang->dept->edit = "Edit";
$lang->dept->delete = "Delete";
@@ -21,9 +19,7 @@ $lang->dept->name = "Name";
$lang->dept->browse = "Manage";
$lang->dept->manage = "Manage";
$lang->dept->updateOrder = "Update order";
$lang->dept->users = "Users";
$lang->dept->saveButton = " Save (S) ";
$lang->dept->confirmDelete = "Are you sure to delete this department?";
$lang->dept->successSave = "Success save.";
-4
View File
@@ -10,8 +10,6 @@
* @link http://www.zentao.net
*/
$lang->dept->common = '部门结构';
$lang->dept->add = "添加";
$lang->dept->addChild = "添加下级部门";
$lang->dept->manageChild = "下级部门";
$lang->dept->edit = "编辑部门";
$lang->dept->delete = "删除部门";
@@ -21,9 +19,7 @@ $lang->dept->name = "部门名称";
$lang->dept->browse = "部门维护";
$lang->dept->manage = "维护部门结构";
$lang->dept->updateOrder = "更新排序";
$lang->dept->users = "成员列表";
$lang->dept->saveButton = " 保存 (S) ";
$lang->dept->confirmDelete = " 您确定删除该部门吗?";
$lang->dept->successSave = " 修改成功。";
+16
View File
@@ -333,6 +333,22 @@ class deptModel extends model
->page($pager)
->fetchAll();
}
/**
* Get user pairs of a department.
*
* @param int $deptID
* @access public
* @return array
*/
public function getDeptUserPairs($deptID = 0)
{
return $this->dao->select('account, realname')->from(TABLE_USER)
->where('deleted')->eq(0)
->beginIF($deptID)->andWhere('dept')->eq((int)$deptID)->fi()
->orderBy('account')
->fetchPairs();
}
/**
* Delete a department.
-1
View File
@@ -85,7 +85,6 @@ class doc extends control
/* Build the search form. */
$actionURL = $this->createLink('doc', 'browse', "libID=$libID&moduleID=$moduleID&procuctID=$productID&projectID=$projectID&browseType=bySearch&queryID=myQueryID");
$this->doc->buildSearchForm($libID, $this->libs, $queryID, $actionURL);
$this->search->setSearchParams($this->config->doc->search);
$this->view->libID = $libID;
$this->view->libName = $this->libs[$libID];
-4
View File
@@ -24,7 +24,6 @@ $lang->doc->content = 'Content';
$lang->doc->keywords = 'Keywords';
$lang->doc->url = 'URL';
$lang->doc->files = 'File';
$lang->doc->views = 'Views';
$lang->doc->addedBy = 'Added by';
$lang->doc->addedDate = 'Added date';
$lang->doc->editedBy = 'Edited by';
@@ -36,9 +35,6 @@ $lang->doc->moduleDoc = 'By module';
$lang->doc->searchDoc = 'By search';
//$lang->doc->allDoc = 'All document';
$lang->doc->moduleName = 'Module name';
$lang->doc->moduleOrder = 'Module order';
/* Actions. */
$lang->doc->index = 'Index';
$lang->doc->create = 'Create doc';
-4
View File
@@ -24,7 +24,6 @@ $lang->doc->content = '文档正文';
$lang->doc->keywords = '关键字';
$lang->doc->url = '文档URL';
$lang->doc->files = '附件';
$lang->doc->views = '查阅次数';
$lang->doc->addedBy = '由谁添加';
$lang->doc->addedDate = '添加时间';
$lang->doc->editedBy = '由谁编辑';
@@ -36,9 +35,6 @@ $lang->doc->moduleDoc = '按模块浏览';
$lang->doc->searchDoc = '搜索';
//$lang->doc->allDoc = '所有文档';
$lang->doc->moduleName = '模块名称';
$lang->doc->moduleOrder = '模块排序';
/* 方法列表。*/
$lang->doc->index = '首页';
$lang->doc->create = '创建文档';
+2
View File
@@ -324,6 +324,8 @@ class docModel extends model
$moduleOptionMenu = $this->loadModel('tree')->getOptionMenu($libID, 'customdoc', $startModuleID = 0);
}
$this->config->doc->search['params']['module']['values'] = $moduleOptionMenu;
$this->loadModel('search')->setSearchParams($this->config->doc->search);
}
/**
-10
View File
@@ -19,7 +19,6 @@ $lang->extension->activate = 'Activate';
$lang->extension->deactivate = 'Deactivate';
$lang->extension->obtain = 'Obtain';
$lang->extension->view = 'Info';
$lang->extension->download = 'Download';
$lang->extension->downloadAB = 'Down';
$lang->extension->upload = 'Upload and install';
$lang->extension->erase = 'Erase';
@@ -31,21 +30,13 @@ $lang->extension->installed = 'Installed';
$lang->extension->deactivated = 'Deactivated';
$lang->extension->available = 'Downloaded';
$lang->extension->id = 'ID';
$lang->extension->name = 'Name';
$lang->extension->code = 'Code';
$lang->extension->version = 'Version';
$lang->extension->compatible = 'Compatible';
$lang->extension->latest = '<small>Latest:<strong><a href="%s" target="_blank" class="extension">%s</a></strong>,need zentao <a href="http://api.zentao.net/goto.php?item=latest" target="_blank"><strong>%s</strong></small>';
$lang->extension->author = 'Author';
$lang->extension->license = 'License';
$lang->extension->intro = 'Description';
$lang->extension->abstract = 'Abstract';
$lang->extension->site = 'Site';
$lang->extension->addedTime = 'Added Time';
$lang->extension->updatedTime = 'Updated Time';
$lang->extension->downloads = 'Downloads';
$lang->extension->public = 'Public';
$lang->extension->compatible = 'Compatible';
$lang->extension->grade = 'Grade';
$lang->extension->depends = 'Depends';
@@ -65,7 +56,6 @@ $lang->extension->byCategory = 'By Category';
$lang->extension->installFailed = '%s failed, the reason is:';
$lang->extension->uninstallFailed = 'Uninstall failed, the reason is:';
$lang->extension->confirmUninstall = 'Uninstall will delete or modify database, whether to uninstall?';
$lang->extension->noticeBackupDB = 'Before uninstalling, we recommend backing up the database.';
$lang->extension->installFinished = 'Good, the extension has been %s successfully.';
$lang->extension->refreshPage = 'Refresh';
$lang->extension->uninstallFinished = 'Extension has been successfully uninstalled.';
-10
View File
@@ -19,7 +19,6 @@ $lang->extension->activate = '激活';
$lang->extension->deactivate = '禁用';
$lang->extension->obtain = '获得插件';
$lang->extension->view = '详情';
$lang->extension->download = '下载插件';
$lang->extension->downloadAB = '下载';
$lang->extension->upload = '本地安装';
$lang->extension->erase = '清除';
@@ -31,21 +30,13 @@ $lang->extension->installed = '已安装';
$lang->extension->deactivated = '被禁用';
$lang->extension->available = '已下载';
$lang->extension->id = '编号';
$lang->extension->name = '名称';
$lang->extension->code = '插件代号';
$lang->extension->version = '版本';
$lang->extension->compatible = '适用版本';
$lang->extension->latest = '<small>最新版本<strong><a href="%s" target="_blank" class="extension">%s</a></strong>,兼容禅道<a href="http://api.zentao.net/goto.php?item=latest" target="_blank" class="alert-link"><strong>%s</strong></a></small>';
$lang->extension->author = '作者';
$lang->extension->license = '授权';
$lang->extension->intro = '详情';
$lang->extension->abstract = '简介';
$lang->extension->site = '官网';
$lang->extension->addedTime = '添加时间';
$lang->extension->updatedTime = '更新时间';
$lang->extension->downloads = '下载量';
$lang->extension->public = '下载方式';
$lang->extension->compatible = '兼容性';
$lang->extension->grade = '评分';
$lang->extension->depends = '依赖';
@@ -65,7 +56,6 @@ $lang->extension->byCategory = '分类浏览';
$lang->extension->installFailed = '%s失败,错误原因如下:';
$lang->extension->uninstallFailed = '卸载失败,错误原因如下:';
$lang->extension->confirmUninstall = '卸载插件会删除或修改相关的数据库,是否继续卸载?';
$lang->extension->noticeBackupDB = '卸载前,建议备份数据库。';
$lang->extension->installFinished = '恭喜您,插件顺利的%s成功!';
$lang->extension->refreshPage = '刷新页面';
$lang->extension->uninstallFinished = '插件已经成功卸载';
-2
View File
@@ -16,8 +16,6 @@ $lang->file->download = 'Download';
$lang->file->edit = 'Edit file name';
$lang->file->inputFileName = 'Input file name';
$lang->file->delete = 'Delete';
$lang->file->export2CSV = 'Export CSV';
$lang->file->ajaxUpload = 'AJAX: upload file from editor';
$lang->file->label = 'Title: ';
$lang->file->maxUploadSize = "<span class='red'>%s</span>";
-2
View File
@@ -16,8 +16,6 @@ $lang->file->download = '下载附件';
$lang->file->edit = '重命名';
$lang->file->inputFileName = '请输入附件名称';
$lang->file->delete = '删除附件';
$lang->file->export2CSV = '导出CSV';
$lang->file->ajaxUpload = '接口:编辑器上传附件';
$lang->file->label = '标题:';
$lang->file->maxUploadSize = "<span class='red'>%s</span>";
+1 -1
View File
@@ -235,7 +235,7 @@ class group extends control
}
$group = $this->group->getById($groupID);
$groupUsers = $this->group->getUserPairs($groupID);
$allUsers = $this->group->getDeptUserPairs($deptID);
$allUsers = $this->loadModel('dept')->getDeptUserPairs($deptID);
$otherUsers = array_diff_assoc($allUsers, $groupUsers);
$title = $this->lang->company->common . $this->lang->colon . $group->name . $this->lang->colon . $this->lang->group->manageMember;
-2
View File
@@ -21,8 +21,6 @@ $lang->group->managePrivByGroup = 'Privilege';
$lang->group->managePrivByModule = 'Manage privilege by module';
$lang->group->byModuleTips = '<span class="tips"> (Press shift or control to multiple select)</span>';
$lang->group->manageMember = 'Members';
$lang->group->linkMember = 'Add members';
$lang->group->unlinkMember = 'Remove member';
$lang->group->confirmDelete = 'Are you sure to delete this group?';
$lang->group->successSaved = 'Success saved.';
$lang->group->errorNotSaved = 'Not saved, please make sure you have selected some actions and groups.';
-2
View File
@@ -21,8 +21,6 @@ $lang->group->managePrivByGroup = '权限维护';
$lang->group->managePrivByModule = '按模块分配权限';
$lang->group->byModuleTips = '<span class="tips">(可以按住shift或者control键进行多选)</span>';
$lang->group->manageMember = '成员维护';
$lang->group->linkMember = '关联用户';
$lang->group->unlinkMember = '移除用户';
$lang->group->confirmDelete = '您确定删除该用户分组吗?';
$lang->group->successSaved = '成功保存';
$lang->group->errorNotSaved = '没有保存,请确认选择了权限数据。';
-16
View File
@@ -178,22 +178,6 @@ class groupModel extends model
->fetchPairs();
}
/**
* Get user pairs of a dept.
*
* @param int $deptID
* @access public
* @return array
*/
public function getDeptUserPairs($deptID = 0)
{
return $this->dao->select('account, realname')->from(TABLE_USER)
->where('deleted')->eq(0)
->beginIF($deptID)->andWhere('dept')->eq((int)$deptID)
->orderBy('account')
->fetchPairs();
}
/**
* Delete a group.
*
-5
View File
@@ -37,7 +37,6 @@ The version of current release is <strong class='red'>%s</strong>。
EOT;
$lang->install->newReleased= "<strong class='red'>Notice</strong>:There is a new version <strong class='red'>%s</strong>, released on %s。";
$lang->install->choice = 'You can ';
$lang->install->or = 'or';
$lang->install->checking = 'System checking';
$lang->install->ok = 'OK(√)';
@@ -70,9 +69,6 @@ $lang->install->sessionFail = 'Edit the php.ini file to set session.save_path';
$lang->install->mkdir = '<p>Should creat the directory %s。<br /> Under linux, can try<br /> mkdir -p %s</p>';
$lang->install->chmod = 'Should change the permission of "%s".<br />Under linux, can try<br />chmod o=rwx -R %s';
$lang->install->settingDB = 'Set database';
$lang->install->webRoot = 'ZenTaoPMS path';
$lang->install->requestType = 'URL type';
$lang->install->defaultLang = 'Default Language';
$lang->install->dbHost = 'Database host';
$lang->install->dbHostNote = 'If 127.0.0.1 can not connect, try localhost';
@@ -81,7 +77,6 @@ $lang->install->dbUser = 'Database user';
$lang->install->dbPassword = 'Database password';
$lang->install->dbName = 'Database name';
$lang->install->dbPrefix = 'Table prefix';
$lang->install->createDB = 'Auto create database';
$lang->install->clearDB = 'Clear data if database exists.';
$lang->install->importDemoData = 'Import demo data if database exists.';
-5
View File
@@ -37,7 +37,6 @@ $lang->install->links = <<<EOT
EOT;
$lang->install->newReleased= "<strong class='text-danger'>提示</strong>:官网网站已有最新版本<strong class='text-danger'>%s</strong>, 发布日期于 %s。";
$lang->install->choice = '您可以选择:';
$lang->install->or = '或者';
$lang->install->checking = '系统检查';
$lang->install->ok = '检查通过(√)';
@@ -70,9 +69,6 @@ $lang->install->sessionFail = '修改PHP配置文件,设置session.save_path'
$lang->install->mkdir = '<p>需要创建目录%s。<br /> linux下面命令为:<br /> mkdir -p %s</p>';
$lang->install->chmod = '需要修改目录 "%s" 的权限。<br />linux下面命令为:<br />chmod o=rwx -R %s';
$lang->install->settingDB = '设置数据库';
$lang->install->webRoot = 'PMS所在网站目录';
$lang->install->requestType = 'URL方式';
$lang->install->defaultLang = '默认语言';
$lang->install->dbHost = '数据库服务器';
$lang->install->dbHostNote = '如果127.0.0.1无法访问,尝试使用localhost';
@@ -81,7 +77,6 @@ $lang->install->dbUser = '数据库用户名';
$lang->install->dbPassword = '数据库密码';
$lang->install->dbName = 'PMS使用的库';
$lang->install->dbPrefix = '建表使用的前缀';
$lang->install->createDB = '自动创建数据库';
$lang->install->clearDB = '清空现有数据';
$lang->install->importDemoData = '导入demo数据';
-2
View File
@@ -16,7 +16,6 @@ $lang->mail->turnon = 'Turnon';
$lang->mail->async = 'Asynchronous';
$lang->mail->fromAddress = 'From email';
$lang->mail->fromName = 'From title';
$lang->mail->mta = 'MTA';
$lang->mail->host = 'SMTP host';
$lang->mail->port = 'SMTP port';
$lang->mail->auth = 'Authentication';
@@ -42,7 +41,6 @@ $lang->mail->addedBy = 'Sender';
$lang->mail->addedDate = 'Added date';
$lang->mail->sendTime = 'Send time';
$lang->mail->status = 'Status';
$lang->mail->ccList = 'Copy to';
$lang->mail->failReason = 'Fail Reason';
$lang->mail->statusList['send'] = 'Success';
-2
View File
@@ -16,7 +16,6 @@ $lang->mail->turnon = '是否打开';
$lang->mail->async = '异步发送';
$lang->mail->fromAddress = '发信邮箱';
$lang->mail->fromName = '发信人';
$lang->mail->mta = '发信方式';
$lang->mail->host = 'smtp服务器';
$lang->mail->port = 'smtp端口号';
$lang->mail->auth = '是否需要验证';
@@ -42,7 +41,6 @@ $lang->mail->addedBy = '发送者';
$lang->mail->addedDate = '创建时间';
$lang->mail->sendTime = '发送时间';
$lang->mail->status = '状态';
$lang->mail->ccList = '抄送给';
$lang->mail->failReason = '失败原因';
$lang->mail->statusList['send'] = '成功';
-3
View File
@@ -10,7 +10,6 @@ $lang->my->testTask = 'Build';
$lang->my->testCase = 'Test case';
$lang->my->story = 'Story';
$lang->my->myProject = $lang->projectCommon;
$lang->my->team = 'Team';
$lang->my->profile = 'Profile';
$lang->my->dynamic = 'Dynamic';
$lang->my->editProfile = 'Edit profile';
@@ -35,8 +34,6 @@ $lang->my->home->latest = 'Dynamic';
$lang->my->home->action = "%s, %s <em>%s</em> %s <a href='%s'>%s</a>.";
$lang->my->home->projects = $lang->projectCommon;
$lang->my->home->products = $lang->productCommon;
$lang->my->home->projectHome = "{$lang->projectCommon} home";
$lang->my->home->productHome = "{$lang->productCommon} home";
$lang->my->home->createProject = "create a {$lang->projectCommon}?";
$lang->my->home->createProduct = "create a {$lang->productCommon}?";
$lang->my->home->help = "<a href='http://www.zentao.net/help-read-79236.html' target='_blank'>Help Book</a>";
-3
View File
@@ -10,7 +10,6 @@ $lang->my->testTask = '我的版本';
$lang->my->testCase = '我的用例';
$lang->my->story = '我的需求';
$lang->my->myProject = "我的{$lang->projectCommon}";
$lang->my->team = '我的团队';
$lang->my->profile = '我的档案';
$lang->my->dynamic = '我的动态';
$lang->my->editProfile = '修改档案';
@@ -35,8 +34,6 @@ $lang->my->home->latest = '最新动态';
$lang->my->home->action = "%s, %s <em>%s</em> %s <a href='%s'>%s</a>。";
$lang->my->home->projects = $lang->projectCommon;
$lang->my->home->products = $lang->productCommon;
$lang->my->home->projectHome = "访问{$lang->projectCommon}主页";
$lang->my->home->productHome = "访问{$lang->productCommon}主页";
$lang->my->home->createProject = "创建一个{$lang->projectCommon}";
$lang->my->home->createProduct = "创建一个{$lang->productCommon}";
$lang->my->home->help = "<a href='http://www.zentao.net/help-read-79236.html' target='_blank'>帮助文档</a>";
+1 -2
View File
@@ -145,7 +145,6 @@ class product extends control
/* Build search form. */
$actionURL = $this->createLink('product', 'browse', "productID=$productID&branch=$branch&browseType=bySearch&queryID=myQueryID");
$this->product->buildSearchForm($productID, $this->products, $queryID, $actionURL);
$this->loadModel('search')->setSearchParams($this->config->product->search);
/* Assign. */
$this->view->title = $this->products[$productID]. $this->lang->colon . $this->lang->product->browse;
@@ -166,7 +165,7 @@ class product extends control
$this->view->moduleID = $moduleID;
$this->view->branch = $branch;
$this->view->branches = $this->loadModel('branch')->getPairs($productID);
$this->view->storyStages = $this->product->getStoryStages($stories);
$this->view->storyStages = $this->product->batchGetStoryStage($stories);
$this->display();
}
-11
View File
@@ -17,7 +17,6 @@ $lang->product->view = "Info";
$lang->product->edit = "Edit";
$lang->product->batchEdit = "Batch Edit";
$lang->product->create = "Create";
$lang->product->read = "Info";
$lang->product->delete = "Delete";
$lang->product->deleted = "Deleted";
$lang->product->close = "Close";
@@ -41,20 +40,11 @@ $lang->product->roadmap = 'Roadmap';
$lang->product->doc = 'Doc';
$lang->product->project = "{$lang->projectCommon}s";
$lang->product->selectProduct = "Select {$lang->productCommon}";
$lang->product->saveButton = " Save (S) ";
$lang->product->confirmDelete = " Are you sure to delete this {$lang->productCommon}?";
$lang->product->ajaxGetProjects = "API: {$lang->projectCommon}s of {$lang->productCommon}";
$lang->product->ajaxGetPlans = "API: plans of {$lang->productCommon}";
$lang->product->errorFormat = 'Error format.';
$lang->product->errorEmptyName = 'Name can not be empty.';
$lang->product->errorEmptyCode = 'Code can not be empty';
$lang->product->errorNoProduct = "No {$lang->productCommon} in system yet.";
$lang->product->accessDenied = "Access to this {$lang->productCommon} denined.";
$lang->product->id = 'ID';
$lang->product->company = 'Company';
$lang->product->name = 'Name';
$lang->product->code = 'Code';
$lang->product->order = 'Order';
@@ -68,7 +58,6 @@ $lang->product->acl = 'Access limitation';
$lang->product->whitelist = 'Whitelist';
$lang->product->branch = '%s';
$lang->product->moduleStory = 'Module';
$lang->product->searchStory = 'Search';
$lang->product->assignedToMe = 'To me';
$lang->product->openedByMe = 'My opened';
-11
View File
@@ -17,7 +17,6 @@ $lang->product->view = "{$lang->productCommon}概况";
$lang->product->edit = "编辑{$lang->productCommon}";
$lang->product->batchEdit = "批量编辑";
$lang->product->create = "新增{$lang->productCommon}";
$lang->product->read = "{$lang->productCommon}详情";
$lang->product->delete = "删除{$lang->productCommon}";
$lang->product->deleted = "已删除";
$lang->product->close = "关闭";
@@ -41,20 +40,11 @@ $lang->product->roadmap = '路线图';
$lang->product->doc = '文档列表';
$lang->product->project = $lang->projectCommon . '列表';
$lang->product->selectProduct = "请选择{$lang->productCommon}";
$lang->product->saveButton = " 保存 (S) ";
$lang->product->confirmDelete = " 您确定删除该{$lang->productCommon}吗?";
$lang->product->ajaxGetProjects = "接口:{$lang->projectCommon}列表";
$lang->product->ajaxGetPlans = "接口:计划列表";
$lang->product->errorFormat = "{$lang->productCommon}数据格式不正确";
$lang->product->errorEmptyName = "{$lang->productCommon}名称不能为空";
$lang->product->errorEmptyCode = "{$lang->productCommon}代号不能为空";
$lang->product->errorNoProduct = "还没有创建{$lang->productCommon}!";
$lang->product->accessDenied = "您无权访问该{$lang->productCommon}";
$lang->product->id = '编号';
$lang->product->company = '所属公司';
$lang->product->name = "{$lang->productCommon}名称";
$lang->product->code = "{$lang->productCommon}代号";
$lang->product->order = '排序';
@@ -68,7 +58,6 @@ $lang->product->acl = '访问控制';
$lang->product->whitelist = '分组白名单';
$lang->product->branch = '所属%s';
$lang->product->moduleStory = '按模块';
$lang->product->searchStory = '搜索';
$lang->product->assignedToMe = '指派给我';
$lang->product->openedByMe = '由我创建';
+5 -3
View File
@@ -385,19 +385,19 @@ class productModel extends model
}
/**
* Get story stages.
* Batch get story stage.
*
* @param array $stories.
* @access public
* @return array
*/
public function getStoryStages($stories)
public function batchGetStoryStage($stories)
{
/* Set story id list. */
$storyIdList = array();
foreach($stories as $story) $storyIdList[$story->id] = $story->id;
return $this->loadModel('story')->getStoryStages($storyIdList);
return $this->loadModel('story')->batchGetStoryStage($storyIdList);
}
/**
@@ -427,6 +427,8 @@ class productModel extends model
$this->config->product->search['fields']['branch'] = $this->lang->product->branch;
$this->config->product->search['params']['branch']['values'] = array('' => '') + $this->loadModel('branch')->getPairs($productID, 'noempty');
}
$this->loadModel('search')->setSearchParams($this->config->product->search);
}
/**
-1
View File
@@ -166,7 +166,6 @@ class project extends control
/* Build the search form. */
$actionURL = $this->createLink('project', 'task', "projectID=$projectID&status=bySearch&param=myQueryID");
$this->project->buildSearchForm($projectID, $this->projects, $queryID, $actionURL);
$this->search->setSearchParams($this->config->project->search);
/* team member pairs. */
$memberPairs = array();
+5 -2
View File
@@ -1,2 +1,5 @@
$(function(){fixedTfootAction('#projectStoryForm');});
$(function(){fixedTheadOfList('#storyList');});
$(function()
{
fixedTfootAction('#projectStoryForm');
fixedTheadOfList('#storyList');
});
+1 -27
View File
@@ -11,13 +11,8 @@
*/
/* Fields. */
$lang->project->common = $lang->projectCommon;
$lang->project->id = 'ID';
$lang->project->company = 'Company';
$lang->project->fromproject = 'From' . $lang->projectCommon;
$lang->project->allProjects = 'All';
$lang->project->iscat = 'Is category';
$lang->project->type = 'Type';
$lang->project->parent = 'Parent';
$lang->project->name = 'Name';
$lang->project->code = 'Code';
$lang->project->begin = 'Begin';
@@ -27,15 +22,7 @@ $lang->project->to = 'To';
$lang->project->days = 'Workdays';
$lang->project->day = 'day';
$lang->project->status = 'Status';
$lang->project->statge = 'Stage';
$lang->project->pri = 'Priority';
$lang->project->desc = 'Desc';
$lang->project->openedBy = 'Opened by';
$lang->project->openedDate = 'Opened date';
$lang->project->closedBy = 'Closed by';
$lang->project->closedDate = 'Closed date';
$lang->project->canceledBy = 'Canceled by';
$lang->project->canceledDate = 'Canceled date';
$lang->project->owner = 'Owner';
$lang->project->PO = $lang->productCommon . ' owner';
$lang->project->PM = $lang->projectCommon . ' manager';
@@ -45,7 +32,6 @@ $lang->project->acl = 'Access limitation';
$lang->project->teamname = 'Team name';
$lang->project->order = "{$lang->projectCommon} order";
$lang->project->products = "{$lang->productCommon}s";
$lang->project->childProjects = "Child {$lang->projectCommon}s";
$lang->project->whitelist = 'Whitelist';
$lang->project->totalEstimate = 'Est';
$lang->project->totalConsumed = 'Done';
@@ -54,7 +40,6 @@ $lang->project->Left = 'Left';
$lang->project->progess = 'Progess';
$lang->project->viewBug = 'View bug';
$lang->project->noProduct = "No {$lang->productCommon}";
$lang->project->select = "Select {$lang->projectCommon}";
$lang->project->createStory = "Create story";
$lang->project->all = 'All';
$lang->project->undone = 'Undone';
@@ -134,7 +119,6 @@ $lang->project->unlinkStory = 'Remove story';
$lang->project->batchUnlinkStory = 'Batch remove story';
$lang->project->importTask = 'Transfer task';
$lang->project->importBug = 'Import bug';
$lang->project->ajaxGetProducts = "API: get {$lang->projectCommon}'s {$lang->productCommon}s";
$lang->project->updateOrder = 'Order';
/* Browse. */
@@ -165,7 +149,6 @@ $lang->project->groups['left'] = 'Group by left';
$lang->project->groups['type'] = 'Group by type';
$lang->project->groups['deadline'] = 'Group by deadline';
$lang->project->moduleTask = 'Module';
$lang->project->byQuery = 'Search';
/* Browse tabs. */
@@ -178,17 +161,14 @@ $lang->project->selectProject = "Select {$lang->projectCommon}";
$lang->project->beginAndEnd = 'Begin and end';
$lang->project->lblStats = 'Stats';
$lang->project->stats = 'Total work hours is 『%s』hours, <br />Total estimate is『%s』hours,<br />Total confused is『%s』hours<br />Total left is『%s』hours';
$lang->project->oneLineStats = "{$lang->projectCommon}『%s』, code is『%s』, {$lang->productCommon}s is『%s』,begin from『%s』to 『%s』,total estimate『%s』hours,consumed『%s』hours,left『%s』hours.";
$lang->project->taskSummary = "<strong>%s</strong> tasks in this page. Pending: <strong>%s</strong>. doing: <strong>%s</strong>. Est: <strong>%s</strong> h. Consumed: <strong>%s</strong> h. Left: <strong>%s</strong>.";
$lang->project->memberHours = "%s has <strong>%s</strong> workhours, ";
$lang->project->groupSummary = "<strong>%s</strong> tasks in this group, wait:<strong>%s</strong>, doing:<strong>%s</strong>, estimate <strong>%s</strong>, consumed <strong>%s</strong>, left <strong>%s</strong> hours.";
$lang->project->wbs = "WBS";
$lang->project->batchWBS = "Batch WBS";
$lang->project->largeBurnChart = 'View large';
$lang->project->howToUpdateBurn = "<a href='http://api.zentao.net/goto.php?item=burndown&lang=zh-cn' title='How to update burndown?' target='_blank' class='btn btn-sm'>Help</a>";
$lang->project->whyNoStories = "There no active stories to added to this {$lang->projectCommon}. Please check the linked {$lang->productCommon}.";
$lang->project->doneProjects = 'Done';
$lang->project->unDoneProjects = 'Undone';
$lang->project->copyTeam = 'Copy a team';
$lang->project->copyFromTeam = 'Copy form team: <strong>%s</strong>';
$lang->project->noMatched = "No matched {$lang->projectCommon} including '%s'";
@@ -196,7 +176,6 @@ $lang->project->copyTitle = "Choose A {$lang->projectCommon} To Copy";
$lang->project->copyTeamTitle = 'Choose A Team To Copy';
$lang->project->copyNoProject = "No {$lang->projectCommon} To Copy";
$lang->project->copyFromProject = 'Copy from: <strong>%s</strong>';
$lang->project->reCopy = 'recopy';
$lang->project->cancelCopy = 'cancel copy';
$lang->project->byPeriod = 'By period';
$lang->project->byUser = 'By user';
@@ -213,7 +192,6 @@ $lang->project->setTeam = 'Set team';
$lang->project->linkStory = 'Link story';
$lang->project->createTask = 'Create task';
$lang->project->goback = 'Go back';
$lang->project->linkProduct = "Select {$lang->productCommon} to link...";
$lang->project->noweekend = 'No weekend';
$lang->project->withweekend = 'With weekend';
$lang->project->interval = 'Interval';
@@ -236,8 +214,4 @@ $lang->project->placeholder->code = "{$lang->projectCommon} code";
$lang->project->placeholder->totalLeft = 'Total left when start project';
$lang->project->selectGroup = new stdclass();
$lang->project->selectGroup->doing = '(doing)';
$lang->project->selectGroup->suspended = '(suspended)';
$lang->project->selectGroup->done = '(done)';
$lang->project->projectTasks = "{$lang->projectCommon}s";
$lang->project->selectGroup->done = '(done)';
+1 -27
View File
@@ -11,13 +11,8 @@
*/
/* 字段列表。*/
$lang->project->common = $lang->projectCommon . '视图';
$lang->project->id = $lang->projectCommon . '编号';
$lang->project->company = '所属公司';
$lang->project->fromproject = '所属' . $lang->projectCommon;
$lang->project->allProjects = '全部';
$lang->project->iscat = '作为目录';
$lang->project->type = $lang->projectCommon . '类型';
$lang->project->parent = '上级' . $lang->projectCommon;
$lang->project->name = $lang->projectCommon . '名称';
$lang->project->code = $lang->projectCommon . '代号';
$lang->project->begin = '开始日期';
@@ -27,15 +22,7 @@ $lang->project->to = '至';
$lang->project->days = '可用工作日';
$lang->project->day = '天';
$lang->project->status = $lang->projectCommon . '状态';
$lang->project->statge = '所处阶段';
$lang->project->pri = '优先级';
$lang->project->desc = $lang->projectCommon . '描述';
$lang->project->openedBy = '由谁创建';
$lang->project->openedDate = '创建日期';
$lang->project->closedBy = '由谁关闭';
$lang->project->closedDate = '关闭日期';
$lang->project->canceledBy = '由谁取消';
$lang->project->canceledDate = '取消日期';
$lang->project->owner = '负责人';
$lang->project->PO = $lang->productCommon . '负责人';
$lang->project->PM = $lang->projectCommon . '负责人';
@@ -45,7 +32,6 @@ $lang->project->acl = '访问控制';
$lang->project->teamname = '团队名称';
$lang->project->order = $lang->projectCommon . '排序';
$lang->project->products = '相关' . $lang->productCommon;
$lang->project->childProjects = "子{$lang->projectCommon}";
$lang->project->whitelist = '分组白名单';
$lang->project->totalEstimate = '总预计';
$lang->project->totalConsumed = '总消耗';
@@ -54,7 +40,6 @@ $lang->project->Left = '剩余';
$lang->project->progess = '进度';
$lang->project->viewBug = '查看bug';
$lang->project->noProduct = "无{$lang->productCommon}{$lang->projectCommon}";
$lang->project->select = "请选择{$lang->projectCommon}";
$lang->project->createStory = "新增需求";
$lang->project->all = '所有';
$lang->project->undone = '未完成';
@@ -134,7 +119,6 @@ $lang->project->unlinkStory = '移除需求';
$lang->project->batchUnlinkStory = '批量移除需求';
$lang->project->importTask = '转入任务';
$lang->project->importBug = '导入Bug';
$lang->project->ajaxGetProducts = "接口:获得{$lang->projectCommon}{$lang->productCommon}列表";
$lang->project->updateOrder = '排序';
/* 分组浏览。*/
@@ -165,7 +149,6 @@ $lang->project->groups['left'] = '剩余分组';
$lang->project->groups['type'] = '类型分组';
$lang->project->groups['deadline'] = '截止分组';
$lang->project->moduleTask = '按模块';
$lang->project->byQuery = '搜索';
/* 查询条件列表。*/
@@ -178,17 +161,14 @@ $lang->project->selectProject = "请选择{$lang->projectCommon}";
$lang->project->beginAndEnd = '起止时间';
$lang->project->lblStats = '工时统计';
$lang->project->stats = '可用工时<strong>%s</strong>工时<br />总共预计<strong>%s</strong>工时<br />已经消耗<strong>%s</strong>工时<br />预计剩余<strong>%s</strong>工时';
$lang->project->oneLineStats = "{$lang->projectCommon}<strong>%s</strong>, 代号为<strong>%s</strong>, 相关{$lang->productCommon}为<strong>%s</strong>,<strong>%s</strong>开始,<strong>%s</strong>结束,总预计<strong>%s</strong>工时,已消耗<strong>%s</strong>工时,预计剩余<strong>%s</strong>工时。";
$lang->project->taskSummary = "本页共 <strong>%s</strong> 个任务,未开始<strong>%s</strong>,进行中<strong>%s</strong>,总预计<strong>%s</strong>工时,已消耗<strong>%s</strong>工时,剩余<strong>%s</strong>工时。";
$lang->project->memberHours = "%s共有 <strong>%s</strong> 个可用工时,";
$lang->project->groupSummary = "本组共 <strong>%s</strong> 个任务,未开始<strong>%s</strong>,进行中<strong>%s</strong>,总预计<strong>%s</strong>工时,已消耗<strong>%s</strong>工时,剩余<strong>%s</strong>工时。";
$lang->project->wbs = "分解任务";
$lang->project->batchWBS = "批量分解";
$lang->project->largeBurnChart = '点击查看大图';
$lang->project->howToUpdateBurn = "<a href='http://api.zentao.net/goto.php?item=burndown&lang=zh-cn' target='_blank' title='如何更新燃尽图?' class='btn btn-sm'>帮助</a>";
$lang->project->whyNoStories = "看起来没有需求可以关联。请检查下{$lang->projectCommon}关联的{$lang->productCommon}中有没有需求,而且要确保它们已经审核通过。";
$lang->project->doneProjects = '已结束';
$lang->project->unDoneProjects = '未结束';
$lang->project->copyTeam = '复制团队';
$lang->project->copyFromTeam = "复制自{$lang->projectCommon}团队: <strong>%s</strong>";
$lang->project->noMatched = "找不到包含'%s'的$lang->projectCommon";
@@ -196,7 +176,6 @@ $lang->project->copyTitle = "请选择一个{$lang->projectCommon}来复
$lang->project->copyTeamTitle = "请选择一个{$lang->projectCommon}团队来复制";
$lang->project->copyNoProject = "没有可用的{$lang->projectCommon}来复制";
$lang->project->copyFromProject = "复制自{$lang->projectCommon} <strong>%s</strong>";
$lang->project->reCopy = '重新复制';
$lang->project->cancelCopy = '取消复制';
$lang->project->byPeriod = '按时间段';
$lang->project->byUser = '按用户';
@@ -213,7 +192,6 @@ $lang->project->setTeam = '设置团队';
$lang->project->linkStory = '关联需求';
$lang->project->createTask = '添加任务';
$lang->project->goback = "返回{$lang->projectCommon}首页";
$lang->project->linkProduct = "选择{$lang->productCommon}关联...";
$lang->project->noweekend = '去除周末';
$lang->project->withweekend = '显示周末';
$lang->project->interval = '间隔';
@@ -236,8 +214,4 @@ $lang->project->placeholder->code = '团队内部的简称';
$lang->project->placeholder->totalLeft = '项目开始时的总预计工时';
$lang->project->selectGroup = new stdclass();
$lang->project->selectGroup->doing = '(进行中)';
$lang->project->selectGroup->suspended = '(已挂起)';
$lang->project->selectGroup->done = '(已结束)';
$lang->project->projectTasks = $lang->projectCommon;
$lang->project->selectGroup->done = '(已结束)';
+3
View File
@@ -522,6 +522,7 @@ class projectModel extends model
if(strpos($mode, 'noclosed') !== false and $project->status == 'done') continue;
if($this->checkPriv($project)) $pairs[$project->id] = $project->name;
}
if(strpos($mode, 'empty') !== false) $pairs[0] = '';
/* If the pairs is empty, to make sure there's an project in the pairs. */
if(empty($pairs) and isset($projects[0]) and $this->checkPriv($projects[0]))
@@ -1774,5 +1775,7 @@ class projectModel extends model
$this->config->project->search['queryID'] = $queryID;
$this->config->project->search['params']['project']['values'] = array(''=>'', $projectID => $projects[$projectID], 'all' => $this->lang->project->allProject);
$this->config->project->search['params']['module']['values'] = $this->loadModel('tree')->getTaskOptionMenu($projectID, $startModuleID = 0);
$this->loadModel('search')->setSearchParams($this->config->project->search);
}
}
+2 -2
View File
@@ -39,9 +39,9 @@ class release extends control
public function browse($productID, $branch = 0)
{
$this->commonAction($productID, $branch);
$products = $this->product->getPairs();
$this->session->set('releaseList', $this->app->getURI(true));
$this->view->title = $products[$productID] . $this->lang->colon . $this->lang->release->browse;
$this->view->title = $this->view->product->name . $this->lang->colon . $this->lang->release->browse;
$this->view->position[] = $this->lang->release->browse;
$this->view->releases = $this->release->getList($productID, $branch);
$this->display();
-3
View File
@@ -37,10 +37,7 @@ $lang->release->date = 'Date';
$lang->release->desc = 'Desc';
$lang->release->status = 'Status';
$lang->release->last = 'Last release';
$lang->release->linkStoriesAndBugs = 'Stories and bugs';
$lang->release->linkStories = 'Stories';
$lang->release->unlinkStory = 'Remove story';
$lang->release->linkBugs = 'Bugs';
$lang->release->unlinkBug = 'Remove bug';
$lang->release->stories = 'Finished stories';
$lang->release->bugs = 'Resolved bugs';
-3
View File
@@ -37,10 +37,7 @@ $lang->release->date = '发布日期';
$lang->release->desc = '描述';
$lang->release->status = '状态';
$lang->release->last = '上次发布';
$lang->release->linkStoriesAndBugs = '需求和Bug';
$lang->release->linkStories = '相关需求';
$lang->release->unlinkStory = '移除需求';
$lang->release->linkBugs = '相关Bug';
$lang->release->unlinkBug = '移除Bug';
$lang->release->stories = '完成的需求';
$lang->release->bugs = '解决的Bug';
-9
View File
@@ -16,7 +16,6 @@ $lang->report->item = 'Item';
$lang->report->value = 'Value';
$lang->report->percent = 'Percent';
$lang->report->undefined = 'Undefined';
$lang->report->time = 'Time';
$lang->report->colors[] = 'AFD8F8';
$lang->report->colors[] = 'F6BD0F';
@@ -58,20 +57,12 @@ $lang->report->task = 'Tasks';
$lang->report->estimate = 'Estimate';
$lang->report->consumed = 'Consumed';
$lang->report->remain = 'Remain';
$lang->report->manhour = 'Manhour';
$lang->report->deviation = 'Deviation';
$lang->report->deviationRate = 'Deviation rate';
$lang->report->stories = 'Stories';
$lang->report->bugs = 'Bugs';
$lang->report->devConsumed = 'Develop';
$lang->report->testConsumed = 'Test';
$lang->report->devTestRate = 'Dev/Test';
$lang->report->details = 'Details';
$lang->report->total = 'Total';
$lang->report->to = 'to';
$lang->report->taskTotal = "Task Total";
$lang->report->manhourTotal = "Manhour Total";
$lang->report->bugTotal = "%s Bugs";
$lang->report->validRate = "Valid Rate";
$lang->report->validRateTips = "Resolution is fixed or postponed/status is resolved or closed";
$lang->report->unplanned = 'unplanned';
-9
View File
@@ -16,7 +16,6 @@ $lang->report->item = '条目';
$lang->report->value = '值';
$lang->report->percent = '百分比';
$lang->report->undefined = '未设定';
$lang->report->time = '时间';
$lang->report->colors[] = 'AFD8F8';
$lang->report->colors[] = 'F6BD0F';
@@ -58,20 +57,12 @@ $lang->report->task = '任务数';
$lang->report->estimate = '总预计';
$lang->report->consumed = '总消耗';
$lang->report->remain = '剩余工时';
$lang->report->manhour = '工时';
$lang->report->deviation = '偏差';
$lang->report->deviationRate = '偏差率';
$lang->report->stories = '需求数';
$lang->report->bugs = 'Bug数';
$lang->report->devConsumed = '开发时间';
$lang->report->testConsumed = '测试时间';
$lang->report->devTestRate = '开发/测试';
$lang->report->details = '详情';
$lang->report->total = '总计';
$lang->report->to = '至';
$lang->report->taskTotal = "总任务数";
$lang->report->manhourTotal = "总工时";
$lang->report->bugTotal = "共%s个Bug";
$lang->report->validRate = "有效率";
$lang->report->validRateTips = "方案为已解决或延期/状态为已解决或已关闭";
$lang->report->unplanned = '未计划';
+9 -5
View File
@@ -63,9 +63,11 @@ class search extends control
*/
public function saveQuery()
{
$this->search->saveQuery();
if(dao::isError()) die(js::error(dao::getError()));
die('success');
$queryID = $this->search->saveQuery();
if(!$queryID) die(js::error(dao::getError()));
die($queryID);
}
/**
@@ -86,13 +88,15 @@ class search extends control
* AJAX: get search query.
*
* @param string $module
* @param int $queryID
* @access public
* @return void
*/
public function ajaxGetQuery($module = '')
public function ajaxGetQuery($module = '', $queryID = 0)
{
$query = $queryID ? $queryID : '';
$module = empty($module) ? $this->session->searchParams['module'] : $module;
$queries = $this->search->getQueryPairs($module);
die(html::select('queryID', $queries, '', 'onchange=executeQuery(this.value) class=form-control'));
die(html::select('queryID', $queries, $query, 'onchange=executeQuery(this.value) class=form-control'));
}
}
-10
View File
@@ -11,8 +11,6 @@
*/
$lang->search->common = 'Search';
$lang->search->reset = 'Reset';
$lang->search->more = 'More';
$lang->search->lite = 'Lite';
$lang->search->saveQuery = 'Save';
$lang->search->myQuery = 'My queries';
$lang->search->group1 = '1';
@@ -22,8 +20,6 @@ $lang->search->buildQuery = 'Execute query';
$lang->search->saveQuery = 'Save query';
$lang->search->deleteQuery = 'Delete query';
$lang->search->setQueryTitle = 'Please input the title(execute searching before save):';
$lang->search->storyTitle = 'Story title';
$lang->search->taskTitle = 'Task title';
$lang->search->select = 'Stories/Tasks filter';
$lang->search->me = 'Me';
@@ -42,9 +38,3 @@ $lang->search->andor['and'] = 'And';
$lang->search->andor['or'] = 'Or';
$lang->search->null = 'Null';
$lang->userquery = new stdclass();
$lang->userquery->title = 'Title';
$lang->userquery->myQueries = 'My queries';
$lang->userquery->execut = 'Execute';
$lang->userquery->delete = 'Delete';
-10
View File
@@ -11,8 +11,6 @@
*/
$lang->search->common = '搜索';
$lang->search->reset = '重置';
$lang->search->more = '更多';
$lang->search->lite = '简洁';
$lang->search->saveQuery = '保存';
$lang->search->myQuery = '我的查询';
$lang->search->group1 = '第一组';
@@ -22,8 +20,6 @@ $lang->search->buildQuery = '执行搜索';
$lang->search->saveQuery = '保存查询';
$lang->search->deleteQuery = '删除查询';
$lang->search->setQueryTitle = '请输入查询标题(保存之前请先查询):';
$lang->search->storyTitle = '需求名称';
$lang->search->taskTitle = '任务名称';
$lang->search->select = '需求/任务筛选';
$lang->search->me = '自己';
@@ -42,9 +38,3 @@ $lang->search->andor['and'] = '并且';
$lang->search->andor['or'] = '或者';
$lang->search->null = '空';
$lang->userquery = new stdclass();
$lang->userquery->title = '查询标题';
$lang->userquery->myQueries = '我的查询';
$lang->userquery->execut = '执行';
$lang->userquery->delete = '删除';
+9
View File
@@ -249,6 +249,15 @@ class searchModel extends model
->skipSpecial('sql,form')
->get();
$this->dao->insert(TABLE_USERQUERY)->data($query)->autoCheck()->check('title', 'notempty')->exec();
if(!dao::isError())
{
return $this->dao->lastInsertID();
}
else
{
return false;
}
}
/**
+1 -1
View File
@@ -245,7 +245,7 @@ function saveQuery()
saveQueryLink = createLink('search', 'saveQuery');
$.post(saveQueryLink, {title: r, module: module}, function(data)
{
if(data == 'success') $('#queryBox').load(createLink('search', 'ajaxGetQuery', 'module=' + module));
if(data) $('#queryBox').load(createLink('search', 'ajaxGetQuery', 'module=' + module + '&queryID=' + data));
});
});
}
+35 -35
View File
@@ -908,69 +908,65 @@ class story extends control
*
* @param int $storyID
* @param string $type
* @param string $stories
* @param string $browseType
* @param int $param
* @access public
* @return void
*/
public function linkStory($storyID, $type = '', $stories = '', $browseType = '', $param = 0)
public function linkStory($storyID, $type = 'linkStories', $browseType = '', $param = 0)
{
$this->commonAction($storyID);
/* Link stories. */
if(!empty($_POST))
{
$stories = $this->story->linkStories($storyID, $type, $stories);
if(isonlybody()) die(js::closeModal('parent.parent', '', "function(){parent.parent.loadLinkedStories('$storyID', '$type', '$stories')}"));
die(js::locate($this->createLink('story', 'edit', "storyID=$storyID"), 'parent'));
}
/* Get story, product, products, and queryID. */
$story = $this->story->getById($storyID);
$products = $this->product->getPairs();
$queryID = ($browseType == 'bySearch') ? (int)$param : 0;
/* Link stories. */
if(!empty($_POST))
{
$this->story->linkStories($storyID, $type);
if(isonlybody()) die(js::closeModal('parent.parent', '', "function(){parent.parent.loadLinkedStories('$storyID', '$type')}"));
die(js::locate($this->createLink('story', 'edit', "storyID=$storyID"), 'parent'));
}
/* Build search form. */
$actionURL = $this->createLink('story', 'linkStory', "storyID=$storyID&type=$type&stories=$stories&browseType=bySearch&queryID=myQueryID", '', true);
$actionURL = $this->createLink('story', 'linkStory', "storyID=$storyID&type=$type&browseType=bySearch&queryID=myQueryID", '', true);
$this->loadModel('product')->buildSearchForm($story->product, $products, $queryID, $actionURL);
$this->loadModel('search')->setSearchParams($this->config->product->search);
/* Get stories to link. */
$allStories = array();
if($browseType == 'bySearch') $allStories = $this->story->getBySearch($story->product, $queryID, 'id', null);
$stories2Link = $this->story->getStories2Link($storyID, $type, $browseType, $queryID);
/* Assign. */
$this->view->title = $this->lang->story->linkStory . "STORY" . $this->lang->colon .$this->lang->story->linkStory;
$this->view->position[] = $this->lang->story->linkStory;
$this->view->type = $type;
$this->view->allStories = $allStories;
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->actionURL = $this->config->product->search;
$this->view->title = $this->lang->story->linkStory . "STORY" . $this->lang->colon .$this->lang->story->linkStory;
$this->view->position[] = $this->lang->story->linkStory;
$this->view->type = $type;
$this->view->stories2Link = $stories2Link;
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->display();
}
/**
* AJAX: If type is linkStories, get related stories else get child stories.
* AJAX: if type is linkStories, get related stories else get child stories.
*
* @param int $storyID
* @param string $type
* @param string $linkedStories
* @access public
* @return string
*/
public function ajaxGetLinkedStories($storyID, $type = '', $linkedStories = '')
public function ajaxGetLinkedStories($storyID, $type = '')
{
$stories = $this->story->getLinkedStories($linkedStories);
$story = $this->story->getById($storyID);
/* Get linked stories. */
$stories = $this->story->getLinkedStories($storyID, $type);
/* Build linked stories list. */
$output = '';
foreach($stories as $storyId => $storyTitle)
{
$output .= '<li>';
$output .= html::a(inlink('view', "storyID=$storyId"), "#$storyId " . $storyTitle);
$output .= html::a("javascript:deleteLinkedStory($storyID, \"$type\", $storyId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= html::a(inlink('view', "storyID=$storyId"), "#$storyId " . $storyTitle, '_blank');
$output .= html::a("javascript:unlinkStory($storyID, \"$type\", $storyId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
@@ -978,25 +974,29 @@ class story extends control
}
/**
* AJAX: Delete linked story.
* AJAX: unlink story.
*
* @param int $storyID
* @param string $type
* @param int $deleteStory
* @param int $story2Unlink
* @access public
* @return string
*/
public function ajaxDeleteLinkedStory($storyID, $type = '', $deleteStory = 0)
public function ajaxUnlinkStory($storyID, $type = '', $story2Unlink = 0)
{
$stories = $this->story->deleteLinkedStory($storyID, $type, $deleteStory);
$story = $this->story->getById($storyID);
/* Unlink related story if type is linkStories else unlink child story. */
$this->story->unlinkStory($storyID, $type, $story2Unlink);
$output = "";
/* Get linkStories if type is linkStories else get childStories. */
$stories = $this->story->getLinkedStories($storyID, $type);
/* Build linked stories list from. */
$output = '';
foreach($stories as $storyId => $storyTitle)
{
$output .= '<li>';
$output .= html::a(inlink('view', "storyID=$storyId"), "#$storyId " . $storyTitle);
$output .= html::a("javascript:deleteLinkedStory($storyID, \"$type\", $storyId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= html::a(inlink('view', "storyID=$storyId"), "#$storyId " . $storyTitle, '_blank');
$output .= html::a("javascript:unlinkStory($storyID, \"$type\", $storyId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
+1 -1
View File
@@ -1 +1 @@
#linkStoryForm {min-height: 200px}
#linkStoryForm {min-height: 300px}
+9 -10
View File
@@ -1,17 +1,17 @@
/**
* Delete linked story.
* Unlink story.
*
* @param int $storyID
* @param string $linkType
* @param int deleteStory
* @param int story2Unlink
* @access public
* @return void
*/
function deleteLinkedStory(storyID, linkType, deleteStory)
function unlinkStory(storyID, linkType, story2Unlink)
{
deleteLink = createLink('story', 'ajaxDeleteLinkedStory', 'storyID=' + storyID + '&type=' + linkType + '&deleteStory=' + deleteStory);
if(linkType == 'linkStories') $('#linkStoriesBox').load(deleteLink);
if(linkType == 'childStories') $('#childStoriesBox').load(deleteLink);
link = createLink('story', 'ajaxUnlinkStory', 'storyID=' + storyID + '&type=' + linkType + '&story2Unlink=' + story2Unlink);
if(linkType == 'linkStories') $('#linkStoriesBox').load(link);
if(linkType == 'childStories') $('#childStoriesBox').load(link);
}
/**
@@ -19,13 +19,12 @@ function deleteLinkedStory(storyID, linkType, deleteStory)
*
* @param int $storyID
* @param string $linkType
* @param string $linkedStories
* @access public
* @return void
*/
function loadLinkedStories(storyID, linkType, linkedStories)
function loadLinkedStories(storyID, linkType)
{
storyLink = createLink('story', 'ajaxGetLinkedStories', 'storyID=' + storyID + '&type=' + linkType + '&linkedStories=' + linkedStories);
if(linkType == 'linkStories') $('#linkStoriesBox').load(storyLink);
storyLink = createLink('story', 'ajaxGetLinkedStories', 'storyID=' + storyID + '&type=' + linkType);
if(linkType == 'linkStories') $('#linkStoriesBox').load(storyLink);
if(linkType == 'childStories') $('#childStoriesBox').load(storyLink);
}
+5 -21
View File
@@ -9,9 +9,7 @@
* @version $Id: en.php 5141 2013-07-15 05:57:15Z chencongzhi520@gmail.com $
* @link http://www.zentao.net
*/
$lang->story->browse = "Browse";
$lang->story->create = "Create";
$lang->story->createCase = "Create case";
$lang->story->batchCreate = "Batch";
$lang->story->change = "Change";
$lang->story->changed = 'Changed';
@@ -24,10 +22,8 @@ $lang->story->batchClose = 'Batch close';
$lang->story->activate = 'Activate';
$lang->story->delete = "Delete";
$lang->story->view = "Info";
$lang->story->legend = "Related";
$lang->story->tasks = "Tasks";
$lang->story->taskCount = 'Tasks count';
$lang->story->bugs = "Bug";
$lang->story->linkStory = 'Related story';
$lang->story->export = "Export data";
$lang->story->zeroCase = "Story of zero case";
@@ -43,12 +39,9 @@ $lang->story->product = $lang->productCommon;
$lang->story->module = 'Module';
$lang->story->source = 'Source';
$lang->story->fromBug = 'From bug';
$lang->story->release = 'Release';
$lang->story->bug = 'Related Bug';
$lang->story->title = 'Title';
$lang->story->spec = 'Spec';
$lang->story->verify = 'Verify';
$lang->story->type = 'Type ';
$lang->story->pri = 'Priority';
$lang->story->estimate = 'Estimate';
$lang->story->estimateAB = 'Estimate';
@@ -63,7 +56,6 @@ $lang->story->assignedTo = 'Assigned to';
$lang->story->assignedDate = 'Assigned date';
$lang->story->lastEditedBy = 'Last edited by';
$lang->story->lastEditedDate = 'Last edited date';
$lang->story->lastEdited = 'Last edited';
$lang->story->closedBy = 'Closed by';
$lang->story->closedDate = 'Closed date';
$lang->story->closedReason = 'Closed reason';
@@ -71,7 +63,6 @@ $lang->story->rejectedReason = 'Reject reason';
$lang->story->reviewedBy = 'Reviewed by';
$lang->story->reviewedDate = 'Reviewed date';
$lang->story->version = 'Version';
$lang->story->project = $lang->projectCommon;
$lang->story->plan = 'Plan';
$lang->story->planAB = 'Plan';
$lang->story->comment = 'Comment';
@@ -156,7 +147,6 @@ $lang->story->legendLinkStories = 'Related story';
$lang->story->legendChildStories = 'Child story';
$lang->story->legendSpec = 'Spec';
$lang->story->legendVerify = 'Verify standard';
$lang->story->legendHistory = 'History';
$lang->story->legendMisc = 'Misc';
$lang->story->lblChange = 'Change';
@@ -171,19 +161,13 @@ $lang->story->affectedCases = 'Affected cases';
$lang->story->specTemplate = "Recommend template::As <<i class='red'>a type of user</i>>,I want <<i class='red'>some goals</i>>,so that <<i class='red'>some reason</i>>.";
$lang->story->needNotReview = "needn't review";
$lang->story->afterSubmit = "After created";
$lang->story->successSaved = "Successfully saved";
$lang->story->confirmDelete = "Are you sure to delete this story?";
$lang->story->confirmBatchClose = "Are you sure to close those stories?";
$lang->story->errorFormat = 'Error format';
$lang->story->errorEmptyTitle = "Title can't be empty";
$lang->story->errorEmptyChildStory = '『Child story』can not be empty.';
$lang->story->mustChooseResult = 'Must choose s result';
$lang->story->mustChoosePreVersion = 'Must select an version to revert';
$lang->story->ajaxGetProjectStories = "API:{$lang->projectCommon} stories";
$lang->story->ajaxGetProductStories = "API:{$lang->productCommon} stories";
$lang->story->form = new stdclass();
$lang->story->form->titleNote = 'A word to briefly express story content';
$lang->story->form->area = 'The story of their respective range';
$lang->story->form->desc = 'Description and standards, what stories? How to acceptance?';
$lang->story->form->resource = 'Allocation of resources, who completed? How long does it take?';
@@ -196,10 +180,10 @@ $lang->story->action->linked2plan = array('main' => '$date, linked to pl
$lang->story->action->unlinkedfromplan = array('main' => '$date, removed from <stong>$extra></strong> by <strong>$actor</strong>');
$lang->story->action->linked2project = array('main' => '$date, linked to ' . $lang->projectCommon . ' <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->unlinkedfromproject = array('main' => '$date, removed from ' . $lang->projectCommon . ' <strontg>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->linkstories = array('main' => '$date, linked stories <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->childstories = array('main' => '$date, subdivied to <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->mvchildstories = array('main' => '$date, removed child stories <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->mvlinkstories = array('main' => '$date, removed link stories <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->linkrelatedstory = array('main' => '$date, link related story <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->subdividestory = array('main' => '$date, subdivide to <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->unlinkrelatedstory = array('main' => '$date, unlink related story <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->story->action->unlinkchildstory = array('main' => '$date, unlink child story <strong>$extra</strong> by <strong>$actor</strong>.');
/* Report*/
$lang->story->report = new stdclass();
+5 -21
View File
@@ -9,9 +9,7 @@
* @version $Id: zh-cn.php 5141 2013-07-15 05:57:15Z chencongzhi520@gmail.com $
* @link http://www.zentao.net
*/
$lang->story->browse = "需求列表";
$lang->story->create = "提需求";
$lang->story->createCase = "建用例";
$lang->story->batchCreate = "批量添加";
$lang->story->change = "变更";
$lang->story->changed = '需求变更';
@@ -24,10 +22,8 @@ $lang->story->batchClose = '批量关闭';
$lang->story->activate = '激活';
$lang->story->delete = "删除";
$lang->story->view = "需求详情";
$lang->story->legend = "相关";
$lang->story->tasks = "相关任务";
$lang->story->taskCount = '任务数';
$lang->story->bugs = "Bug";
$lang->story->linkStory = '关联需求';
$lang->story->export = "导出数据";
$lang->story->zeroCase = "零用例需求";
@@ -43,12 +39,9 @@ $lang->story->product = "所属{$lang->productCommon}";
$lang->story->module = '所属模块';
$lang->story->source = '需求来源';
$lang->story->fromBug = '来源Bug';
$lang->story->release = '发布计划';
$lang->story->bug = '相关bug';
$lang->story->title = '需求名称';
$lang->story->spec = '需求描述';
$lang->story->verify = '验收标准';
$lang->story->type = '需求类型 ';
$lang->story->pri = '优先级';
$lang->story->estimate = '预计工时';
$lang->story->estimateAB = '预计';
@@ -63,7 +56,6 @@ $lang->story->assignedTo = '指派给';
$lang->story->assignedDate = '指派日期';
$lang->story->lastEditedBy = '最后修改';
$lang->story->lastEditedDate = '最后修改日期';
$lang->story->lastEdited = '最后修改';
$lang->story->closedBy = '由谁关闭';
$lang->story->closedDate = '关闭日期';
$lang->story->closedReason = '关闭原因';
@@ -71,7 +63,6 @@ $lang->story->rejectedReason = '拒绝原因';
$lang->story->reviewedBy = '由谁评审';
$lang->story->reviewedDate = '评审时间';
$lang->story->version = '版本号';
$lang->story->project = '所属' . $lang->projectCommon;
$lang->story->plan = '所属计划';
$lang->story->planAB = '计划';
$lang->story->comment = '备注';
@@ -156,7 +147,6 @@ $lang->story->legendLinkStories = '相关需求';
$lang->story->legendChildStories = '细分需求';
$lang->story->legendSpec = '需求描述';
$lang->story->legendVerify = '验收标准';
$lang->story->legendHistory = '历史记录';
$lang->story->legendMisc = '其他相关';
$lang->story->lblChange = '变更需求';
@@ -171,19 +161,13 @@ $lang->story->affectedCases = '影响的用例';
$lang->story->specTemplate = "建议参考的模板:作为一名<<i class='text-important'>某种类型的用户</i>>,我希望<<i class='text-important'>达成某些目的</i>>,这样可以<<i class='text-important'>开发的价值</i>>。";
$lang->story->needNotReview = '不需要评审';
$lang->story->afterSubmit = "添加之后";
$lang->story->successSaved = "需求成功添加,";
$lang->story->confirmDelete = "您确认删除该需求吗?";
$lang->story->confirmBatchClose = "您确认关闭这些需求吗?";
$lang->story->errorFormat = '需求数据有误';
$lang->story->errorEmptyTitle = '标题不能为空';
$lang->story->errorEmptyChildStory = '『细分需求』不能为空。';
$lang->story->mustChooseResult = '必须选择评审结果';
$lang->story->mustChoosePreVersion = '必须选择回溯的版本';
$lang->story->ajaxGetProjectStories = "接口:获取{$lang->projectCommon}需求列表";
$lang->story->ajaxGetProductStories = "接口:获取{$lang->productCommon}需求列表";
$lang->story->form = new stdclass();
$lang->story->form->titleNote = '一句话简要表达需求内容';
$lang->story->form->area = '该需求所属范围';
$lang->story->form->desc = '描述及标准,什么需求?如何验收?';
$lang->story->form->resource = '资源分配,有谁完成?需要多少时间?';
@@ -196,10 +180,10 @@ $lang->story->action->linked2plan = array('main' => '$date, 由 <strong>
$lang->story->action->unlinkedfromplan = array('main' => '$date, 由 <strong>$actor</strong> 从计划 <strong>$extra</strong> 移除。');
$lang->story->action->linked2project = array('main' => '$date, 由 <strong>$actor</strong> 关联到' . $lang->projectCommon . ' <strong>$extra</strong>。');
$lang->story->action->unlinkedfromproject = array('main' => '$date, 由 <strong>$actor</strong> 从' . $lang->projectCommon . ' <strong>$extra</strong> 移除。');
$lang->story->action->linkstories = array('main' => '$date, 由 <strong>$actor</strong> 关联相关需求 <strong>$extra</strong>。');
$lang->story->action->childstories = array('main' => '$date, 由 <strong>$actor</strong> 细分为需求 <strong>$extra</strong>。');
$lang->story->action->mvchildstories = array('main' => '$date, 由 <strong>$actor</strong> 移除细分需求 <strong>$extra</strong>。');
$lang->story->action->mvlinkstories = array('main' => '$date, 由 <strong>$actor</strong> 移除相关需求 <strong>$extra</strong>。');
$lang->story->action->linkrelatedstory = array('main' => '$date, 由 <strong>$actor</strong> 关联相关需求 <strong>$extra</strong>。');
$lang->story->action->subdividestory = array('main' => '$date, 由 <strong>$actor</strong> 细分为需求 <strong>$extra</strong>。');
$lang->story->action->unlinkrelatedstory = array('main' => '$date, 由 <strong>$actor</strong> 移除相关需求 <strong>$extra</strong>。');
$lang->story->action->unlinkchildstory = array('main' => '$date, 由 <strong>$actor</strong> 移除细分需求 <strong>$extra</strong>。');
/* 统计报表。*/
$lang->story->report = new stdclass();
+63 -28
View File
@@ -426,9 +426,14 @@ class storyModel extends model
->setIF($this->post->closedReason != false and $this->post->closedBy == false, 'closedBy', $this->app->user->account)
->join('reviewedBy', ',')
->join('mailto', ',')
->remove('files,labels,comment')
->remove('linkStories,childStories,files,labels,comment')
->get();
if(is_array($story->plan)) $story->plan = trim(join(',', $story->plan), ',');
if($story->closedReason == 'subdivided' and $oldStory->childStories == '')
{
dao::$errors[] = $this->lang->story->errorEmptyChildStory;
return false;
}
$this->dao->update(TABLE_STORY)
->data($story)
@@ -1040,60 +1045,90 @@ class storyModel extends model
*
* @param int $storyID
* @param string $type
* @param string $stories
* @access public
* @return string
* @return void
*/
public function linkStories($storyID, $type = 'linkStories', $stories = '')
public function linkStories($storyID, $type = 'linkStories')
{
if($this->post->stories == false) return $stories;
if($this->post->stories == false) return;
$stories = implode(',', $this->post->stories) . ',' . trim($stories, ',');
$this->dao->update(TABLE_STORY)->set($type)->eq(trim($stories,','))->where('id')->eq($storyID)->exec();
$story = $this->getById($storyID);
$stories2Link = $this->post->stories;
$stories = implode(',', $stories2Link) . ',' . trim($story->$type, ',');
$this->dao->update(TABLE_STORY)->set($type)->eq(trim($stories, ','))->where('id')->eq($storyID)->exec();
if(dao::isError()) die(js::error(dao::getError()));
$this->loadModel('action')->create('story', $storyID, $type, '', implode(',', $this->post->stories));
return $stories;
$action = ($type == 'linkStories') ? 'linkRelatedStory' : 'subdivideStory';
$this->loadModel('action')->create('story', $storyID, $action, '', implode(',', $stories2Link));
}
/**
* Delete linked story.
* Get stories to link.
*
* @param int $storyID
* @param string $type
* @param int $deleteStory
* @param string $browseType
* @param int $queryID
* @access public
* @return array
*/
public function deleteLinkedStory($storyID, $type, $deleteStory)
public function getStories2Link($storyID, $type = 'linkStories', $browseType = 'bySearch', $queryID = 0)
{
$story = $this->getById($storyID);
$stories = explode(',', trim($story->$type, ','));
foreach($stories as $key => $storyId)
if($browseType == 'bySearch')
{
if($storyId == $deleteStory) unset($stories[$key]);
$story = $this->getById($storyID);
$stories2Link = $this->getBySearch($story->product, $queryID, 'id', null);
foreach($stories2Link as $key => $story2Link)
{
if($story2Link->id == $storyID) unset($stories2Link[$key]);
if(in_array($story2Link->id, explode(',', $story->$type))) unset($stories2Link[$key]);
}
return $stories2Link;
}
$stories = implode(',', $stories);
else
{
return array();
}
}
/**
* Unlink story.
*
* @param int $storyID
* @param string $type
* @param int $story2Unlink
* @access public
* @return void
*/
public function unlinkStory($storyID, $type = 'linkStories', $story2Unlink = 0)
{
$story = $this->getById($storyID);
$oldLinkedStories = explode(',', trim($story->$type, ','));
foreach($oldLinkedStories as $key => $storyId)
{
if($storyId == $story2Unlink) unset($oldLinkedStories[$key]);
}
$stories = implode(',', $oldLinkedStories);
$this->dao->update(TABLE_STORY)->set($type)->eq($stories)->where('id')->eq($storyID)->exec();
if(dao::isError()) die(js::error(dao::getError()));
$action = ($type == 'linkStories') ? 'mvLinkStories' : 'mvChildStories';
$this->loadModel('action')->create('story', $storyID, $action, '', $deleteStory);
return $this->getLinkedStories($stories);
$action = ($type == 'linkStories') ? 'unlinkRelatedStory' : 'unlinkChildStory';
$this->loadModel('action')->create('story', $storyID, $action, '', $story2Unlink);
}
/**
* Get linked stories.
*
* @param string $stories
* @param string $storyID
* @param string $type
* @access public
* @return array
*/
public function getLinkedStories($stories)
public function getLinkedStories($storyID, $type = 'linkStories')
{
return $this->dao->select('id, title')->from(TABLE_STORY)->where('id')->in($stories)->fetchPairs();
$story = $this->getById($storyID);
return $this->dao->select('id, title')->from(TABLE_STORY)->where('id')->in($story->$type)->fetchPairs();
}
/**
@@ -1598,13 +1633,13 @@ class storyModel extends model
}
/**
* Get story stages.
* Batch get story stage.
*
* @param array $stories
* @access public
* @return array
*/
public function getStoryStages($stories)
public function batchGetStoryStage($stories)
{
return $this->dao->select('*')->from(TABLE_STORYSTAGE)
->where('story')->in($stories)
+13 -9
View File
@@ -156,7 +156,7 @@
</tr>
<tr>
<th><?php echo $lang->story->closedReason;?></th>
<td><?php echo html::select('closedReason', $lang->story->reasonList, $story->closedReason, 'class="form-control"');?></td>
<td><?php echo html::select('closedReason', $lang->story->reasonList, $story->closedReason, "class='form-control' onchange='setStory(this.value)'");?></td>
</tr>
<?php endif;?>
</table>
@@ -165,14 +165,16 @@
<fieldset>
<legend><?php echo $lang->story->legendMisc;?></legend>
<table class='table table-form'>
<tr>
<?php if($story->status == 'closed'):?>
<tr id='duplicateStoryBox'>
<th class='w-70px'><?php echo $lang->story->duplicateStory;?></th>
<td><?php echo html::input('duplicateStory', $story->duplicateStory, "class='form-control'");?></td>
</tr>
<?php endif;?>
<tr class='text-top'>
<th><?php echo $lang->story->linkStories;?></th>
<th class='w-70px'><?php echo $lang->story->linkStories;?></th>
<td>
<?php echo html::a($this->createLink('story', 'linkStory', "storyID=$story->id&type=linkStories&stories=$story->linkStories", '', true), $lang->story->linkStory, '', "data-toggle='modal' data-type='iframe' data-width='85%'");?>
<?php echo html::a($this->createLink('story', 'linkStory', "storyID=$story->id&type=linkStories", '', true), $lang->story->linkStory, '', "data-toggle='modal' data-type='iframe' data-width='95%'");?>
<ul class='list-unstyled' id='linkStoriesBox'>
<?php
$linkStories = explode(',', $story->linkStories);
@@ -181,8 +183,8 @@
if(isset($story->extraStories[$linkStoryID]))
{
echo '<li>';
echo html::a(inlink('view', "storyID=$linkStoryID"), "#$linkStoryID " . $story->extraStories[$linkStoryID]);
echo html::a("javascript:deleteLinkedStory($story->id, \"linkStories\", $linkStoryID)", '<i class="icon-remove"></i>', '', "title='{$lang->unlink}' style='float:right'");
echo html::a(inlink('view', "storyID=$linkStoryID"), "#$linkStoryID " . $story->extraStories[$linkStoryID], '_blank');
echo html::a("javascript:unlinkStory($story->id, \"linkStories\", $linkStoryID)", '<i class="icon-remove"></i>', '', "title='{$lang->unlink}' style='float:right'");
echo '</li>';
}
}
@@ -190,10 +192,11 @@
</ul>
</td>
</tr>
<?php if($story->status == 'closed'):?>
<tr class='text-top'>
<th><?php echo $lang->story->childStories;?></th>
<td>
<?php echo html::a($this->createLink('story', 'linkStory', "storyID=$story->id&type=childStories&stories=$story->childStories", '', true), $lang->story->linkStory, '', "data-toggle='modal' data-type='iframe' data-width='85%'");?>
<?php echo html::a($this->createLink('story', 'linkStory', "storyID=$story->id&type=childStories", '', true), $lang->story->linkStory, '', "data-toggle='modal' data-type='iframe' data-width='95%'");?>
<ul class='list-unstyled' id='childStoriesBox'>
<?php
$childStories = explode(',', $story->childStories);
@@ -202,8 +205,8 @@
if(isset($story->extraStories[$childStoryID]))
{
echo '<li>';
echo html::a(inlink('view', "storyID=$childStoryID"), "#$childStoryID" . $story->extraStories[$childStoryID]);
echo html::a("javascript:deleteLinkedStory($story->id, \"childStories\", $childStoryID)", '<i class="icon-remove"></i>', '', "title='{$lang->unlink}' style='float:right'");
echo html::a(inlink('view', "storyID=$childStoryID"), "#$childStoryID" . $story->extraStories[$childStoryID], '_blank');
echo html::a("javascript:unlinkStory($story->id, \"childStories\", $childStoryID)", '<i class="icon-remove"></i>', '', "title='{$lang->unlink}' style='float:right'");
echo '</li>';
}
}
@@ -211,6 +214,7 @@
</ul>
</td>
</tr>
<?php endif;?>
</table>
</fieldset>
</div>
+14 -13
View File
@@ -22,7 +22,7 @@
</div>
<form method='post' class='form-condensed' target='hiddenwin' id='linkStoryForm'>
<table class='table table-condensed table-hover table-striped tablesorter table-fixed' id='storyList'>
<?php if($allStories):?>
<?php if($stories2Link):?>
<thead>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
@@ -36,21 +36,19 @@
</thead>
<tbody>
<?php $storyCount = 0;?>
<?php foreach($allStories as $storyDetail):?>
<?php if(in_array($storyDetail->id, explode(',', $story->$type))) continue;?>
<?php if($storyDetail->id == $story->id) continue;?>
<?php $storyLink = $this->createLink('story', 'view', "storyID=$storyDetail->id");?>
<?php foreach($stories2Link as $story2Link):?>
<?php $storyLink = $this->createLink('story', 'view', "storyID=$story2Link->id");?>
<tr class='text-center'>
<td class='text-left'>
<input type='checkbox' name='stories[]' value='<?php echo $storyDetail->id;?>'/>
<?php echo html::a($storyLink, sprintf('%03d', $storyDetail->id));?>
<input type='checkbox' name='stories[]' value='<?php echo $story2Link->id;?>'/>
<?php echo html::a($storyLink, sprintf('%03d', $story2Link->id));?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->story->priList, $storyDetail->pri, $storyDetail->pri)?>'><?php echo zget($lang->story->priList, $storyDetail->pri, $storyDetail->pri);?></span></td>
<td><?php echo html::a($this->createLink('product', 'browse', "productID=$storyDetail->product&branch=$storyDetail->branch"), $products[$storyDetail->product], '_blank');?></td>
<td class='text-left nobr' title="<?php echo $storyDetail->title?>"><?php echo html::a($storyLink, $storyDetail->title, '_blank');?></td>
<td><?php echo $storyDetail->planTitle;?></td>
<td><?php echo $users[$storyDetail->openedBy];?></td>
<td><?php echo $storyDetail->estimate;?></td>
<td><span class='<?php echo 'pri' . zget($lang->story->priList, $story2Link->pri, $story2Link->pri)?>'><?php echo zget($lang->story->priList, $story2Link->pri, $story2Link->pri);?></span></td>
<td><?php echo html::a($this->createLink('product', 'browse', "productID=$story2Link->product&branch=$story2Link->branch"), $products[$story2Link->product], '_blank');?></td>
<td class='text-left nobr' title="<?php echo $story2Link->title?>"><?php echo html::a($storyLink, $story2Link->title, '_blank');?></td>
<td><?php echo $story2Link->planTitle;?></td>
<td><?php echo $users[$story2Link->openedBy];?></td>
<td><?php echo $story2Link->estimate;?></td>
</tr>
<?php $storyCount ++;?>
<?php endforeach;?>
@@ -63,6 +61,9 @@
</div>
</td>
</tr>
<tr>
<td class='hidden'><?php echo html::input('story', $story->id);?></td>
</tr>
</tfoot>
<?php endif;?>
</table>
-18
View File
@@ -13,7 +13,6 @@ $lang->task->index = "Index";
$lang->task->create = "Create";
$lang->task->batchCreate = "Batch create";
$lang->task->batchEdit = "Batch edit";
$lang->task->import = "Import undone";
$lang->task->edit = "Update";
$lang->task->delete = "Delete";
$lang->task->deleted = "Deleted";
@@ -39,7 +38,6 @@ $lang->task->project = $lang->projectCommon;
$lang->task->module = 'Module';
$lang->task->story = 'Story';
$lang->task->storySpec = 'Story desc';
$lang->task->storyVersion = 'Version';
$lang->task->storyFiles = 'Story Files';
$lang->task->storyComment = 'Story comment';
$lang->task->name = 'Name';
@@ -71,7 +69,6 @@ $lang->task->assignedTo = 'Assigned To';
$lang->task->assignedToAB = 'Assign';
$lang->task->assignedDate = 'Assigned Date';
$lang->task->openedBy = 'Opened By';
$lang->task->openedByAB = 'Open';
$lang->task->openedDate = 'Opened Date';
$lang->task->openedDateAB = 'Open';
$lang->task->finishedBy = 'Finished By';
@@ -125,24 +122,11 @@ $lang->task->afterChoices['continueAdding'] = 'Continue to add task for this sto
$lang->task->afterChoices['toTaskList'] = 'To task list. ';
$lang->task->afterChoices['toStoryList'] = 'To story list. ';
$lang->task->buttonEdit = 'Edit';
$lang->task->buttonClose = 'Close';
$lang->task->buttonCancel = 'Cancel';
$lang->task->buttonActivate = 'Activate';
$lang->task->buttonLogEfforts = 'Efforts';
$lang->task->buttonDelete = 'Delete';
$lang->task->buttonBackToList = 'Back';
$lang->task->buttonStart = 'Start';
$lang->task->buttonDone = 'Done';
$lang->task->legendBasic = 'Basic info';
$lang->task->legendEffort = 'Effort';
$lang->task->legendLife = 'Lifetime';
$lang->task->legendDesc = 'Desc';
$lang->task->legendAction = 'Action';
$lang->task->ajaxGetUserTasks = "API:My tasks";
$lang->task->ajaxGetProjectTasks = "API:{$lang->projectCommon} tasks";
$lang->task->confirmDelete = "Are you sure you want to delete this task?";
$lang->task->confirmDeleteEstimate = "Are you sure you want to delete this hour?";
$lang->task->copyStoryTitle = "Same as story";
@@ -249,5 +233,3 @@ $lang->task->report->tasksPerClosedReason->graph->xAxisName = 'Closed Reason';
$lang->task->report->finishedTasksPerDay->type = 'bar';
$lang->task->report->finishedTasksPerDay->graph->xAxisName = 'Date';
$lang->task->estimateTip = 'The estimated time for this task';
-18
View File
@@ -13,7 +13,6 @@ $lang->task->index = "任务一览";
$lang->task->create = "建任务";
$lang->task->batchCreate = "批量添加";
$lang->task->batchEdit = "批量编辑";
$lang->task->import = "导入之前未完任务";
$lang->task->edit = "编辑";
$lang->task->delete = "删除";
$lang->task->deleted = "已删除";
@@ -39,7 +38,6 @@ $lang->task->project = '所属' . $lang->projectCommon;
$lang->task->module = '所属模块';
$lang->task->story = '相关需求';
$lang->task->storySpec = '需求描述';
$lang->task->storyVersion = '需求版本';
$lang->task->storyFiles = '需求附件';
$lang->task->storyComment = '需求备注';
$lang->task->name = '任务名称';
@@ -71,7 +69,6 @@ $lang->task->assignedTo = '指派给';
$lang->task->assignedToAB = '指派给';
$lang->task->assignedDate = '指派日期';
$lang->task->openedBy = '由谁创建';
$lang->task->openedByAB = '创建者';
$lang->task->openedDate = '创建日期';
$lang->task->openedDateAB = '创建';
$lang->task->finishedBy = '由谁完成';
@@ -125,24 +122,11 @@ $lang->task->afterChoices['continueAdding'] = '继续为该需求添加任务';
$lang->task->afterChoices['toTaskList'] = '返回任务列表';
$lang->task->afterChoices['toStoryList'] = '返回需求列表';
$lang->task->buttonEdit = '编辑';
$lang->task->buttonClose = '关闭';
$lang->task->buttonCancel = '取消';
$lang->task->buttonActivate = '激活';
$lang->task->buttonLogEfforts = '记录工时';
$lang->task->buttonDelete = '删除';
$lang->task->buttonBackToList = '返回';
$lang->task->buttonStart = '开始';
$lang->task->buttonDone = '完成';
$lang->task->legendBasic = '基本信息';
$lang->task->legendEffort = '工时信息';
$lang->task->legendLife = '任务的一生';
$lang->task->legendDesc = '任务描述';
$lang->task->legendAction = '操作';
$lang->task->ajaxGetUserTasks = "接口:我的任务";
$lang->task->ajaxGetProjectTasks = "接口:{$lang->projectCommon}任务";
$lang->task->confirmDelete = "您确定要删除这个任务吗?";
$lang->task->confirmDeleteEstimate = "您确定要删除这个记录吗?";
$lang->task->copyStoryTitle = "同需求";
@@ -249,5 +233,3 @@ $lang->task->report->tasksPerClosedReason->graph->xAxisName = '关闭原因';
$lang->task->report->finishedTasksPerDay->type = 'bar';
$lang->task->report->finishedTasksPerDay->graph->xAxisName = '日期';
$lang->task->estimateTip = '对该任务最初的预计';
+26 -30
View File
@@ -89,7 +89,6 @@ class testcase extends control
/* Build the search form. */
$actionURL = $this->createLink('testcase', 'browse', "productID=$productID&branch=$branch&browseType=bySearch&queryID=myQueryID");
$this->testcase->buildSearchForm($productID, $this->products, $queryID, $actionURL);
$this->loadModel('search')->setSearchParams($this->config->testcase->search);
/* Assign. */
$this->view->title = $this->products[$productID] . $this->lang->colon . $this->lang->testcase->common;
@@ -624,37 +623,34 @@ class testcase extends control
* Link related cases.
*
* @param int $caseID
* @param string $cases
* @param string $browseType
* @param int $param
* @access public
* @return void
*/
public function linkCases($caseID, $cases, $browseType = '', $param = 0)
public function linkCases($caseID, $browseType = '', $param = 0)
{
/* Link cases. */
if(!empty($_POST))
{
$cases = $this->testcase->linkCases($caseID, $cases);
if(isonlybody()) die(js::closeModal('parent.parent', '', "function(){parent.parent.loadLinkedCases('$caseID', '$cases')}"));
die($this->locate(inlink('edit', "caseID=$caseID"), 'parent'));
$this->testcase->linkCases($caseID);
if(isonlybody()) die(js::closeModal('parent.parent', '', "function(){parent.parent.loadLinkCases('$caseID')}"));
die(js::locate($this->createLink('testcase', 'edit', "caseID=$caseID"), 'parent'));
}
/* Get test cases, and queryID. */
/* Get case and queryID. */
$case = $this->testcase->getById($caseID);
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Set menu. */
$this->testcase->setMenu($this->products, $case->product, $case->branch);
/* Get cases to link. */
$allCases = array();
$allCases = $this->testcase->getBySearch($case->product, $queryID, 'id', null);
/* Build the search form. */
$actionURL = $this->createLink('testcase', 'linkCases', "caseID=$caseID&cases=$cases&browseType=bySearch&queryID=myQueryID" );
$actionURL = $this->createLink('testcase', 'linkCases', "caseID=$caseID&browseType=bySearch&queryID=myQueryID", '', true);
$this->testcase->buildSearchForm($case->product, $this->products, $queryID, $actionURL);
$this->loadModel('search')->setSearchParams($this->config->testcase->search);
/* Get cases to link. */
$cases2Link = $this->testcase->getCases2Link($caseID, $browseType, $queryID);
/* Assign. */
$this->view->title = $case->title . $this->lang->colon . $this->lang->testcase->linkCases;
@@ -662,33 +658,31 @@ class testcase extends control
$this->view->position[] = html::a($this->createLink('testcase', 'view', "caseID=$caseID"), $case->title);
$this->view->position[] = $this->lang->testcase->linkCases;
$this->view->case = $case;
$this->view->allCases = $allCases;
$this->view->cases2Link = $cases2Link;
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->display();
}
/**
* AJAX: Get linked cases.
* AJAX: get linkCases.
*
* @param int $caseID
* @param string $cases
* @access public
* @return string
*/
public function ajaxGetLinkedCases($caseID, $linkedCases = '')
public function ajaxGetLinkCases($caseID)
{
/* Get case and linked cases. */
$case = $this->testcase->getById($caseID);
$cases = $this->testcase->getLinkedCases($linkedCases);
/* Get linkCases. */
$cases = $this->testcase->getLinkCases($caseID);
/* Build linkCase list. */
$output = '';
foreach($cases as $caseId => $caseTitle)
{
$output .= '<li>';
$output .= html::a(inlink('view', "caseID=$caseId"), "#$caseId " . $caseTitle);
$output .= html::a("javascript:deleteLinkedCase($caseID, $caseId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= html::a(inlink('view', "caseID=$caseId"), "#$caseId " . $caseTitle, '_blank');
$output .= html::a("javascript:unlinkCase($caseID, $caseId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
@@ -696,26 +690,28 @@ class testcase extends control
}
/**
* AJAX: Delete linked case.
* AJAX: unlink related case.
*
* @param int $caseID
* @param int $deleteCase
* @param int $case2Unlink
* @access public
* @return string
*/
public function ajaxDeleteLinkedCase($caseID, $deleteCase = 0)
public function ajaxUnlinkCase($caseID, $case2Unlink = 0)
{
/* Get case and linked cases. */
$case = $this->testcase->getById($caseID);
$cases = $this->testcase->deleteLinkedCase($caseID, $deleteCase);
/* Unlink related case. */
$this->testcase->unlinkCase($caseID, $case2Unlink);
/* Get current linkCases. */
$cases = $this->testcase->getLinkCases($caseID);
/* Build linkCase list. */
$output = '';
foreach($cases as $caseId => $caseTitle)
{
$output .= '<li>';
$output .= html::a(inlink('view', "caseID=$caseId"), "#$caseId " . $caseTitle);
$output .= html::a("javascript:deleteLinkedCase($caseID, $caseId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= html::a(inlink('view', "caseID=$caseId"), "#$caseId " . $caseTitle, '_blank');
$output .= html::a("javascript:unlinkCase($caseID, $caseId)", '<i class="icon-remove"></i>', '', "title='{$this->lang->unlink}' style='float:right'");
$output .= '</li>';
}
+1 -1
View File
@@ -1 +1 @@
#linkCasesForm {min-height: 200px}
#linkCasesForm {min-height: 300px}
+8 -9
View File
@@ -20,29 +20,28 @@ $(document).ready(function()
/**
* Delete linked case.
* Unlink related case.
*
* @param int $caseID
* @param int $deleteCase
* @param int $case2Unlink
* @access public
* @return void
*/
function deleteLinkedCase(caseID, deleteCase)
function unlinkCase(caseID, case2Unlink)
{
deleteLink = createLink('testcase', 'ajaxDeleteLinkedCase', 'caseID=' + caseID + '&deleteCase=' + deleteCase);
$('#linkCaseBox').load(deleteLink);
link = createLink('testcase', 'ajaxUnlinkCase', 'caseID=' + caseID + '&case2Unlink=' + case2Unlink);
$('#linkCaseBox').load(link);
}
/**
* Load linked cases.
* Load linkCases.
*
* @param int $caseID
* @param string $linkedCases
* @access public
* @return void
*/
function loadLinkedCases(caseID, linkedCases)
function loadLinkCases(caseID)
{
caseLink = createLink('testcase', 'ajaxGetLinkedCases', 'caseID=' + caseID + '&linkedCases=' + linkedCases);
caseLink = createLink('testcase', 'ajaxGetLinkCases', 'caseID=' + caseID);
$('#linkCaseBox').load(caseLink);
}
-35
View File
@@ -13,30 +13,19 @@ $lang->testcase->id = 'ID';
$lang->testcase->product = $lang->productCommon;
$lang->testcase->module = 'Module';
$lang->testcase->story = 'Story';
$lang->testcase->storyVersion = 'Story version';
$lang->testcase->title = 'Title';
$lang->testcase->precondition = 'precondition';
$lang->testcase->pri = 'Priority';
$lang->testcase->type = 'Type';
$lang->testcase->status = 'Status';
$lang->testcase->steps = 'Steps';
$lang->testcase->frequency = 'Frequency';
$lang->testcase->order = 'Order';
$lang->testcase->openedBy = 'Opened by ';
$lang->testcase->openedDate = 'Opened date';
$lang->testcase->lastEditedBy = 'Last edited by';
$lang->testcase->lastEditedDate = 'Last edited date';
$lang->testcase->version = 'Version';
$lang->testcase->result = 'Result';
$lang->testcase->lastRunResult = 'Result';
$lang->testcase->real = 'Real';
$lang->testcase->keywords = 'Keywords';
$lang->testcase->files = 'Files';
$lang->testcase->howRun = 'How run';
$lang->testcase->scriptedBy = 'Scripted by';
$lang->testcase->scriptedDate = 'Scripted date';
$lang->testcase->scriptedStatus = 'Scripted status';
$lang->testcase->scriptedLocation = 'Script location';
$lang->testcase->linkCase = 'Related cases';
$lang->testcase->linkCases = 'Link cases';
$lang->testcase->stage = 'Stage';
@@ -63,11 +52,9 @@ $lang->testcase->edit = "Edit";
$lang->testcase->batchEdit = "Batch edit";
$lang->testcase->delete = "Delete";
$lang->testcase->batchDelete = "Batch delete ";
$lang->testcase->deleted = "Deleted";
$lang->testcase->browse = "Browse";
$lang->testcase->groupCase = "View case by group";
$lang->testcase->import = "Import";
$lang->testcase->importID = "Linenum";
$lang->testcase->showImport = "Show import";
$lang->testcase->exportTemplet = "Export templet";
$lang->testcase->export = "Export data";
@@ -77,45 +64,28 @@ $lang->testcase->confirmStoryChange = 'Confirm story change';
$lang->testcase->new = 'New';
$lang->testcase->num = 'The number of cases';
$lang->testcase->insert = 'New insertion';
$lang->testcase->deleteStep = 'Delete';
$lang->testcase->insertBefore = 'Insert before';
$lang->testcase->insertAfter = 'Insert after';
$lang->testcase->selectProduct = "Select {$lang->productCommon}";
$lang->testcase->byModule = 'By module';
$lang->testcase->assignToMe = 'Cases to me';
$lang->testcase->openedByMe = 'My Opened cases';
$lang->testcase->allCases = 'All case';
$lang->testcase->needConfirm = 'Story changed';
$lang->testcase->moduleCases = 'By module';
$lang->testcase->bySearch = 'By search';
$lang->testcase->doneByMe = 'My runed cases';
$lang->testcase->lblProductAndModule = "{$lang->productCommon} & module";
$lang->testcase->lblTypeAndPri = 'Type & priority';
$lang->testcase->lblSystemBrowserAndHardware = 'OS & browser';
$lang->testcase->lblAssignAndMail = 'Assigned & mailto';
$lang->testcase->lblStory = 'Story';
$lang->testcase->lblLastEdited = 'Last edited';
$lang->testcase->lblTypeValue = 'List of type';
$lang->testcase->lblStageValue = 'List of stage';
$lang->testcase->lblStatusValue = 'List of status';
$lang->testcase->legendRelated = 'Related info';
$lang->testcase->legendBasicInfo = 'Basic info';
$lang->testcase->legendMailto = 'Mailto';
$lang->testcase->legendAttatch = 'Files';
$lang->testcase->legendLinkBugs = 'Bug';
$lang->testcase->legendOpenAndEdit = 'Open & edit';
$lang->testcase->legendStoryAndTask = 'Story';
$lang->testcase->legendCases = 'Related cases';
$lang->testcase->legendSteps = 'Steps';
$lang->testcase->legendAction = 'Action';
$lang->testcase->legendHistory = 'History';
$lang->testcase->legendComment = 'Comment';
$lang->testcase->legendProduct = "{$lang->productCommon} & module";
$lang->testcase->confirmDelete = 'Are you sure to delete this case?';
$lang->testcase->confirmBatchDelete = 'Are you sure to batch delete there cases?';
@@ -157,7 +127,6 @@ $lang->testcase->resultList['pass'] = 'Pass';
$lang->testcase->resultList['fail'] = 'Fail';
$lang->testcase->resultList['blocked'] = 'Blocked';
$lang->testcase->buttonEdit = 'Edit';
$lang->testcase->buttonToList = 'Back';
$lang->testcase->errorEncode = 'No data, please select right encode and upload again!';
@@ -165,7 +134,3 @@ $lang->testcase->noFunction = 'Iconv and mb_convert_encoding does not exist, yo
$lang->testcase->noRequire = "In the row of %s, the %s is a required field";
$lang->testcase->searchStories = 'Type to search stories';
$lang->testcase->action = new stdclass();
$lang->testcase->action->linked2case = array('main' => '$date, linked related cases <strong>$extra</strong> by <strong>$actor</strong>.');
$lang->testcase->action->unlinkedcase = array('main' => '$date, removed related cases <strong>$extra</strong> by <strong>$actor</strong>.');
-35
View File
@@ -13,30 +13,19 @@ $lang->testcase->id = '用例编号';
$lang->testcase->product = "所属{$lang->productCommon}";
$lang->testcase->module = '所属模块';
$lang->testcase->story = '相关需求';
$lang->testcase->storyVersion = '需求版本';
$lang->testcase->title = '用例标题';
$lang->testcase->precondition = '前置条件';
$lang->testcase->pri = '优先级';
$lang->testcase->type = '用例类型';
$lang->testcase->status = '用例状态';
$lang->testcase->steps = '用例步骤';
$lang->testcase->frequency = '执行频率';
$lang->testcase->order = '排序';
$lang->testcase->openedBy = '由谁创建 ';
$lang->testcase->openedDate = '创建日期';
$lang->testcase->lastEditedBy = '最后修改者';
$lang->testcase->lastEditedDate = '最后修改日期';
$lang->testcase->version = '用例版本';
$lang->testcase->result = '测试结果';
$lang->testcase->lastRunResult = '结果';
$lang->testcase->real = '实际情况';
$lang->testcase->keywords = '关键词';
$lang->testcase->files = '附件';
$lang->testcase->howRun = '执行方式';
$lang->testcase->scriptedBy = '由谁编写';
$lang->testcase->scriptedDate = '编写日期';
$lang->testcase->scriptedStatus = '脚本状态';
$lang->testcase->scriptedLocation = '脚本位置';
$lang->testcase->linkCase = '相关用例';
$lang->testcase->linkCases = '关联用例';
$lang->testcase->stage = '适用阶段';
@@ -63,11 +52,9 @@ $lang->testcase->edit = "编辑";
$lang->testcase->batchEdit = "批量编辑 ";
$lang->testcase->delete = "删除";
$lang->testcase->batchDelete = "批量删除 ";
$lang->testcase->deleted = "已删除";
$lang->testcase->browse = "用例列表";
$lang->testcase->groupCase = "分组浏览用例";
$lang->testcase->import = "导入";
$lang->testcase->importID = "行号";
$lang->testcase->showImport = "显示导入内容";
$lang->testcase->exportTemplet = "导出模板";
$lang->testcase->export = "导出数据";
@@ -77,45 +64,28 @@ $lang->testcase->confirmStoryChange = '确认需求变动';
$lang->testcase->new = '新增';
$lang->testcase->num = '用例记录数:';
$lang->testcase->insert = '全新插入';
$lang->testcase->deleteStep = '删除';
$lang->testcase->insertBefore = '之前添加';
$lang->testcase->insertAfter = '之后添加';
$lang->testcase->selectProduct = "请选择{$lang->productCommon}";
$lang->testcase->byModule = '按模块';
$lang->testcase->assignToMe = '给我的用例';
$lang->testcase->openedByMe = '我建的用例';
$lang->testcase->allCases = '所有';
$lang->testcase->needConfirm = '需求变动';
$lang->testcase->moduleCases = '按模块';
$lang->testcase->bySearch = '搜索';
$lang->testcase->doneByMe = '我完成的用例';
$lang->testcase->lblProductAndModule = "{$lang->productCommon}模块";
$lang->testcase->lblTypeAndPri = '类型&优先级';
$lang->testcase->lblSystemBrowserAndHardware = '系统::浏览器';
$lang->testcase->lblAssignAndMail = '指派给::抄送给';
$lang->testcase->lblStory = '相关需求';
$lang->testcase->lblLastEdited = '最后编辑';
$lang->testcase->lblTypeValue = '类型可选值列表';
$lang->testcase->lblStageValue = '阶段可选值列表';
$lang->testcase->lblStatusValue = '状态可选值列表';
$lang->testcase->legendRelated = '相关信息';
$lang->testcase->legendBasicInfo = '基本信息';
$lang->testcase->legendMailto = '抄送给';
$lang->testcase->legendAttatch = '附件';
$lang->testcase->legendLinkBugs = '相关Bug';
$lang->testcase->legendOpenAndEdit = '创建编辑';
$lang->testcase->legendStoryAndTask = '需求::任务';
$lang->testcase->legendCases = '相关用例';
$lang->testcase->legendSteps = '用例步骤';
$lang->testcase->legendAction = '操作';
$lang->testcase->legendHistory = '历史记录';
$lang->testcase->legendComment = '备注';
$lang->testcase->legendProduct = $lang->productCommon . '模块';
$lang->testcase->confirmDelete = '您确认要删除该测试用例吗?';
$lang->testcase->confirmBatchDelete = '您确认要批量删除这些测试用例吗?';
@@ -157,7 +127,6 @@ $lang->testcase->resultList['pass'] = '通过';
$lang->testcase->resultList['fail'] = '失败';
$lang->testcase->resultList['blocked'] = '阻塞';
$lang->testcase->buttonEdit = '编辑';
$lang->testcase->buttonToList = '返回';
$lang->testcase->errorEncode = '无数据,请选择正确的编码重新上传!';
@@ -165,7 +134,3 @@ $lang->testcase->noFunction = '不存在iconv和mb_convert_encoding转码方法
$lang->testcase->noRequire = "%s行的“%s”是必填字段,不能为空";
$lang->testcase->searchStories = '键入来搜索需求';
$lang->testcase->action = new stdclass();
$lang->testcase->action->linked2case = array('main' => '$date, 由 <strong>$actor</strong> 关联相关用例 <strong>$extra</strong>。');
$lang->testcase->action->unlinkedcase = array('main' => '$date, 由 <strong>$actor</strong> 移除相关用例 <strong>$extra</strong>。');
+49 -20
View File
@@ -438,61 +438,88 @@ class testcaseModel extends model
}
/**
* Link cases.
* Link related cases.
*
* @param int $caseID
* @param string $cases
* @access public
* @return array
* @return void
*/
public function linkCases($caseID, $cases = '')
public function linkCases($caseID)
{
if($this->post->cases == false) return $cases;
if($this->post->cases == false) return;
$cases = implode(',', $this->post->cases) . ',' . trim($cases, ',');
$case = $this->getById($caseID);
$cases2Link = $this->post->cases;
$cases = implode(',', $cases2Link) . ',' . trim($case->linkCase, ',');
$this->dao->update(TABLE_CASE)->set('linkCase')->eq(trim($cases, ','))->where('id')->eq($caseID)->exec();
if(dao::isError()) die(js::error(dao::getError()));
$this->loadModel('action')->create('case', $caseID, 'linked2Case', '', implode(',', $this->post->cases));
return $cases;
$this->loadModel('action')->create('case', $caseID, 'linkRelatedCase', '', implode(',', $cases2Link));
}
/**
* Delete linked case.
* Get cases to link.
*
* @param int $caseID
* @param int $deleteCase
* @param string $browseType
* @param int $queryID
* @access public
* @return array
*/
public function deleteLinkedCase($caseID, $deleteCase = 0)
public function getCases2Link($caseID, $browseType = 'bySearch', $queryID)
{
if($browseType == 'bySearch')
{
$case = $this->getById($caseID);
$cases2Link = $this->getBySearch($case->product, $queryID, 'id', null);
foreach($cases2Link as $key => $case2Link)
{
if($case2Link->id == $caseID) unset($cases2Link[$key]);
if(in_array($case2Link->id, explode(',', $case->linkCase))) unset($cases2Link[$key]);
}
return $cases2Link;
}
else
{
return array();
}
}
/**
* Unlink related case.
*
* @param int $caseID
* @param int $case2Unlink
* @access public
* @return void
*/
public function unlinkCase($caseID, $case2Unlink = 0)
{
$case = $this->getById($caseID);
$cases = explode(',', trim($case->linkCase, ','));
foreach($cases as $key => $caseId)
{
if($caseId == $deleteCase) unset($cases[$key]);
if($caseId == $case2Unlink) unset($cases[$key]);
}
$cases = implode(',', $cases);
$this->dao->update(TABLE_CASE)->set('linkCase')->eq($cases)->where('id')->eq($caseID)->exec();
if(dao::isError()) die(js::error(dao::getError()));
$this->loadModel('action')->create('case', $caseID, 'unLinkedCase', '', $deleteCase);
return $this->getLinkedCases($cases);
$this->loadModel('action')->create('case', $caseID, 'unlinkRelatedCase', '', $case2Unlink);
}
/**
* Get linked cases.
* Get linkCases.
*
* @param string $cases
* @param int $caseID
* @access public
* @return array
*/
public function getLinkedCases($cases)
public function getLinkCases($caseID)
{
return $this->dao->select('id, title')->from(TABLE_CASE)->where('id')->in($cases)->fetchPairs();
$case = $this->getById($caseID);
return $this->dao->select('id, title')->from(TABLE_CASE)->where('id')->in($case->linkCase)->fetchPairs();
}
/**
@@ -830,5 +857,7 @@ class testcaseModel extends model
}
$this->config->testcase->search['actionURL'] = $actionURL;
$this->config->testcase->search['queryID'] = $queryID;
$this->loadModel('search')->setSearchParams($this->config->testcase->search);
}
}
+3 -3
View File
@@ -143,7 +143,7 @@
<tr class='text-top'>
<th><?php echo $lang->testcase->linkCase;?></th>
<td>
<?php echo html::a($this->createLink('testcase', 'linkCases', "caseID=$case->id&case=$case->linkCase", '', true), $lang->testcase->linkCases, '', "data-type='iframe' data-toggle='modal' data-width='85%'");?>
<?php echo html::a($this->createLink('testcase', 'linkCases', "caseID=$case->id", '', true), $lang->testcase->linkCases, '', "data-type='iframe' data-toggle='modal' data-width='95%'");?>
<ul class='list-unstyled' id='linkCaseBox'>
<?php
if(isset($case->linkCaseTitles))
@@ -151,8 +151,8 @@
foreach($case->linkCaseTitles as $linkCaseID => $linkCaseTitle)
{
echo '<li>';
echo html::a($this->createLink('testcase', 'view', "caseID=$linkCaseID"), "#$linkCaseID $linkCaseTitle", '_blank');
echo html::a("javascript:deleteLinkedCase($case->id, $linkCaseID)", '<i class="icon-remove"></i>', '', "style='float:right'");
echo html::a(inlink('view', "caseID=$linkCaseID"), "#$linkCaseID " . $linkCaseTitle, '_blank');
echo html::a("javascript:unlinkCase($case->id, $linkCaseID)", '<i class="icon-remove"></i>', '', "title='{$lang->unlink}' style='float:right'");
echo '</li>';
}
}
+53 -50
View File
@@ -12,58 +12,61 @@
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<div id='titlebar'>
<div class='heading'>
<span class='prefix'><?php echo html::icon($lang->icons['testcase']);?> <strong><?php echo $case->id;?></strong></span>
<strong><?php echo html::a($this->createLink('case', 'view', 'caseID=' . $case->id), $case->title, '_blank');?></strong>
<small class='text-muted'> <?php echo $lang->testcase->linkCases;?> <?php echo html::icon($lang->icons['link']);?></small>
<div class='container'>
<div id='titlebar'>
<div class='heading'>
<span class='prefix'><?php echo html::icon($lang->icons['testcase']);?> <strong><?php echo $case->id;?></strong></span>
<strong><?php echo html::a($this->createLink('case', 'view', 'caseID=' . $case->id), $case->title, '_blank');?></strong>
<small class='text-muted'> <?php echo $lang->testcase->linkCases;?> <?php echo html::icon($lang->icons['link']);?></small>
</div>
<div id='querybox' class='show'></div>
</div>
<div id='querybox' class='show'></div>
</div>
<form method='post' class='form-condensed' target='hiddenwin' id='linkCasesForm'>
<table class='table table-condensed table-hover table-striped tablesorter' id='caseList'>
<?php if($allCases):?>
<thead>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th><?php echo $lang->testcase->title;?></th>
<th class='w-type'><?php echo $lang->testcase->type;?></th>
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-status'><?php echo $lang->statusAB;?></th>
<form method='post' class='form-condensed' target='hiddenwin' id='linkCasesForm'>
<table class='table table-condensed table-hover table-striped tablesorter' id='caseList'>
<?php if($cases2Link):?>
<thead>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th><?php echo $lang->testcase->title;?></th>
<th class='w-type'><?php echo $lang->testcase->type;?></th>
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-status'><?php echo $lang->statusAB;?></th>
</tr>
</thead>
<tbody>
<?php $caseCount = 0;?>
<?php foreach($cases2Link as $case2Link):?>
<tr class='text-center'>
<td class='text-left'>
<input type='checkbox' name='cases[]' value='<?php echo $case2Link->id;?>' />
<?php echo html::a($this->createLink('testcase', 'view', "testcaseID=$case2Link->id"), sprintf('%03d', $case2Link->id));?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->testcase->priList, $case2Link->pri, $case2Link->pri)?>'><?php echo zget($lang->testcase->priList, $case2Link->pri, $case2Link->pri)?></span></td>
<td class='text-left'><?php echo html::a($this->createLink('testcase', 'view', "caseID=$case2Link->id"), $case2Link->title, '_blank');?></td>
<td><?php echo $lang->testcase->typeList[$case2Link->type];?></td>
<td><?php echo $users[$case2Link->openedBy];?></td>
<td class='case-<?php echo $case2Link->status?>'><?php echo $lang->testcase->statusList[$case2Link->status];?></td>
</tr>
</thead>
<tbody>
<?php $caseCount = 0;?>
<?php foreach($allCases as $caseDetail):?>
<?php if(in_array($caseDetail->id, explode(',', $case->linkCase))) continue;?>
<?php if($caseDetail->id == $case->id) continue;?>
<tr class='text-center'>
<td class='text-left'>
<input type='checkbox' name='cases[]' value='<?php echo $caseDetail->id;?>' />
<?php echo html::a($this->createLink('testcase', 'view', "testcaseID=$caseDetail->id"), sprintf('%03d', $caseDetail->id));?>
</td>
<td><span class='<?php echo 'pri' . zget($lang->testcase->priList, $caseDetail->pri, $caseDetail->pri)?>'><?php echo zget($lang->testcase->priList, $caseDetail->pri, $caseDetail->pri)?></span></td>
<td class='text-left'><?php echo html::a($this->createLink('testcase', 'view', "caseID=$caseDetail->id"), $caseDetail->title, '_blank');?></td>
<td><?php echo $lang->testcase->typeList[$caseDetail->type];?></td>
<td><?php echo $users[$caseDetail->openedBy];?></td>
<td class='case-<?php echo $caseDetail->status?>'><?php echo $lang->testcase->statusList[$caseDetail->status];?></td>
</tr>
<?php $caseCount ++;?>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<td colspan='7'>
<div class='table-actions clearfix'>
<?php if($caseCount) echo html::selectButton() . html::submitButton();?>
</div>
</td>
</tr>
</tfoot>
<?php endif;?>
</table>
</form>
<?php $caseCount ++;?>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<td colspan='7'>
<div class='table-actions clearfix'>
<?php if($caseCount) echo html::selectButton() . html::submitButton();?>
</div>
</td>
</tr>
<tr>
<td class='hidden'><?php echo html::input('case', $case->id);?></td>
</tr>
</tfoot>
<?php endif;?>
</table>
</form>
</div>
<script type='text/javascript'>
$(function(){ajaxGetSearchForm();});
</script>
-9
View File
@@ -12,12 +12,10 @@
$lang->testtask->index = "Index";
$lang->testtask->create = "Create";
$lang->testtask->delete = "Delete";
$lang->testtask->deleted = "Deleted";
$lang->testtask->view = "Info";
$lang->testtask->edit = "Edit";
$lang->testtask->browse = "Browse";
$lang->testtask->linkCase = "Link case";
$lang->testtask->linkCaseAB = "Link";
$lang->testtask->unlinkCase = "Del";
$lang->testtask->batchAssign = "Batch Assign";
$lang->testtask->runCase = "Run";
@@ -35,7 +33,6 @@ $lang->testtask->wait = "Testing build";
$lang->testtask->done = "Tested build";
$lang->testtask->common = 'Test build';
$lang->testtask->id = 'ID';
$lang->testtask->product = $lang->productCommon;
$lang->testtask->project = $lang->projectCommon;
$lang->testtask->build = 'Build';
@@ -53,8 +50,6 @@ $lang->testtask->lastRunAccount = "Run";
$lang->testtask->lastRunTime = 'Time';
$lang->testtask->lastRunResult = 'Result';
$lang->testtask->report = 'Report';
$lang->testtask->stories = 'Stories';
$lang->testtask->bugs = 'Bugs';
$lang->testtask->legendDesc = 'Desc';
$lang->testtask->legendReport = 'Report';
@@ -72,7 +67,6 @@ $lang->testtask->priList[2] = '2';
$lang->testtask->priList[4] = '4';
$lang->testtask->unlinkedCases = 'Unlinked';
$lang->testtask->linkedCases = 'Linked';
$lang->testtask->linkByStory = 'Link by story';
$lang->testtask->linkByBug = 'Link by bug';
$lang->testtask->passAll = 'Pass all';
@@ -84,7 +78,6 @@ $lang->testtask->showFail = 'Failed <span class="text-danger">%s</span time
$lang->testtask->confirmDelete = 'Are you sure to delete this test build?';
$lang->testtask->confirmUnlinkCase = 'Are you sure to unlink this case?';
$lang->testtask->byModule = 'By module';
$lang->testtask->assignedToMe = 'Assgined to me';
$lang->testtask->allCases = 'All Cases';
@@ -105,8 +98,6 @@ $lang->testtask->mail->create->title = "%s created testtask #%s:%s";
$lang->testtask->mail->edit->title = "%s finished testtask #%s:%s";
$lang->testtask->mail->close->title = "%s closed testtask #%s:%s";
$lang->testtask->testScope = 'Test scope';
$lang->testtask->action = new stdclass();
$lang->testtask->action->testtaskopened = '$date, 由 <strong>$actor</strong> opened test task. <strong>$extra</strong>。' . "\n";
$lang->testtask->action->testtaskstarted = '$date, 由 <strong>$actor</strong> started test task. <strong>$extra</strong>。' . "\n";
-9
View File
@@ -12,12 +12,10 @@
$lang->testtask->index = "版本首页";
$lang->testtask->create = "提交测试";
$lang->testtask->delete = "删除版本";
$lang->testtask->deleted = "已删除";
$lang->testtask->view = "概况";
$lang->testtask->edit = "编辑版本";
$lang->testtask->browse = "版本列表";
$lang->testtask->linkCase = "关联用例";
$lang->testtask->linkCaseAB = "关联";
$lang->testtask->unlinkCase = "移除";
$lang->testtask->batchAssign = "批量指派";
$lang->testtask->runCase = "执行";
@@ -35,7 +33,6 @@ $lang->testtask->wait = "待测版本";
$lang->testtask->done = "已测版本";
$lang->testtask->common = '测试视图版本';
$lang->testtask->id = '编号';
$lang->testtask->product = '所属' . $lang->productCommon;
$lang->testtask->project = '所属' . $lang->projectCommon;
$lang->testtask->build = '版本';
@@ -53,8 +50,6 @@ $lang->testtask->lastRunAccount = '执行人';
$lang->testtask->lastRunTime = '执行时间';
$lang->testtask->lastRunResult = '结果';
$lang->testtask->report = '测试总结';
$lang->testtask->stories = '相关需求';
$lang->testtask->bugs = '相关Bug';
$lang->testtask->legendDesc = '版本描述';
$lang->testtask->legendReport = '测试总结';
@@ -72,7 +67,6 @@ $lang->testtask->priList[2] = '2';
$lang->testtask->priList[4] = '4';
$lang->testtask->unlinkedCases = '未关联';
$lang->testtask->linkedCases = '已关联';
$lang->testtask->linkByStory = '按需求关联';
$lang->testtask->linkByBug = '按Bug关联';
$lang->testtask->passAll = '全部通过';
@@ -84,7 +78,6 @@ $lang->testtask->showFail = '失败<span class="text-danger">%s</span>次';
$lang->testtask->confirmDelete = '您确认要删除该版本吗?';
$lang->testtask->confirmUnlinkCase = '您确认要移除该用例吗?';
$lang->testtask->byModule = '按模块';
$lang->testtask->assignedToMe = '指派给我';
$lang->testtask->allCases = '所有用例';
@@ -105,8 +98,6 @@ $lang->testtask->mail->create->title = "%s创建了版本 #%s:%s";
$lang->testtask->mail->edit->title = "%s编辑了版本 #%s:%s";
$lang->testtask->mail->close->title = "%s关闭了版本 #%s:%s";
$lang->testtask->testScope = '测试范畴';
$lang->testtask->action = new stdclass();
$lang->testtask->action->testtaskopened = '$date, 由 <strong>$actor</strong> 创建版本 <strong>$extra</strong>。' . "\n";
$lang->testtask->action->testtaskstarted = '$date, 由 <strong>$actor</strong> 启动版本 <strong>$extra</strong>。' . "\n";
-9
View File
@@ -16,23 +16,17 @@ $lang->todo->batchCreate = "Batch create";
$lang->todo->edit = "Edit";
$lang->todo->batchEdit = "Batch edit";
$lang->todo->view = "Info";
$lang->todo->viewAB = "Info";
$lang->todo->finish = "Finish";
$lang->todo->batchFinish = "Batch finish";
$lang->todo->export = "Export";
$lang->todo->delete = "Delete";
$lang->todo->browse = "Browse";
$lang->todo->import2Today = "Import to today";
$lang->todo->import = "Import to";
$lang->todo->changeStatus = "Change";
$lang->todo->legendBasic = "Basic Info";
$lang->todo->id = 'ID';
$lang->todo->account = 'Owner';
$lang->todo->date = 'Date';
$lang->todo->begin = 'Begin time';
$lang->todo->beginAB = 'Begin';
$lang->todo->end = 'End time';
$lang->todo->endAB = 'End';
$lang->todo->beginAndEnd = 'Begin and End';
$lang->todo->type = 'Type';
@@ -41,7 +35,6 @@ $lang->todo->name = 'Name';
$lang->todo->status = 'Status';
$lang->todo->desc = 'Desc';
$lang->todo->private = 'Private';
$lang->todo->idvalue = 'Task or bug';
$lang->todo->confirmBug = 'This todo linked to bug #%s,chang it also?';
$lang->todo->confirmTask = 'This todo linked to task #%s,chang it also?';
@@ -62,7 +55,6 @@ $lang->todo->typeList['bug'] = 'Bug';
$lang->todo->typeList['task'] = 'Task';
$lang->todo->confirmDelete = "Are you sure to delete this todo?";
$lang->todo->successMarked = "Successfully changed status";;
$lang->todo->thisIsPrivate = 'This is a private todo。:)';
$lang->todo->lblDisableDate = 'Set time lately';
@@ -81,4 +73,3 @@ $lang->todo->periods['all'] = 'All';
$lang->todo->action = new stdclass();
$lang->todo->action->finished = array('main' => '$date, Finished by <strong>$actor</strong>');
$lang->todo->action->marked = array('main' => '$date, Change status to <stong>$extra</strong> by <strong>$actor</strong>。', 'extra' => 'statusList');
-9
View File
@@ -16,23 +16,17 @@ $lang->todo->batchCreate = "批量添加";
$lang->todo->edit = "更新待办";
$lang->todo->batchEdit = "批量编辑";
$lang->todo->view = "待办详情";
$lang->todo->viewAB = "详情";
$lang->todo->finish = "完成";
$lang->todo->batchFinish = "批量完成";
$lang->todo->export = "导出";
$lang->todo->delete = "删除待办";
$lang->todo->browse = "浏览待办";
$lang->todo->import2Today = "导入到今天";
$lang->todo->import = "导入";
$lang->todo->changeStatus = "更改";
$lang->todo->legendBasic = "基本信息";
$lang->todo->id = '编号';
$lang->todo->account = '所有者';
$lang->todo->date = '日期';
$lang->todo->begin = '开始时间';
$lang->todo->beginAB = '开始';
$lang->todo->end = '结束时间';
$lang->todo->endAB = '结束';
$lang->todo->beginAndEnd = '起止时间';
$lang->todo->type = '类型';
@@ -41,7 +35,6 @@ $lang->todo->name = '名称';
$lang->todo->status = '状态';
$lang->todo->desc = '描述';
$lang->todo->private = '私人事务';
$lang->todo->idvalue = '任务或Bug';
$lang->todo->confirmBug = '该Todo关联的是Bug #%s,需要修改它吗?';
$lang->todo->confirmTask = '该Todo关联的是Task #%s,需要修改它吗?';
@@ -62,7 +55,6 @@ $lang->todo->typeList['bug'] = 'Bug';
$lang->todo->typeList['task'] = $lang->projectCommon . '任务';
$lang->todo->confirmDelete = "您确定要删除这条待办吗?";
$lang->todo->successMarked = "成功切换状态!";
$lang->todo->thisIsPrivate = '这是一条私人事务。:)';
$lang->todo->lblDisableDate = '暂时不设定时间';
@@ -81,4 +73,3 @@ $lang->todo->periods['all'] = '所有';
$lang->todo->action = new stdclass();
$lang->todo->action->finished = array('main' => '$date, 由 <strong>$actor</strong>完成');
$lang->todo->action->marked = array('main' => '$date, 由 <strong>$actor</strong> 标记为<strong>$extra</strong>。', 'extra' => 'statusList');
-4
View File
@@ -11,9 +11,7 @@
*/
$lang->tree = new stdclass();
$lang->tree->common = 'Module manage';
$lang->tree->add = 'Add';
$lang->tree->edit = 'Edit';
$lang->tree->addChild = 'Add child';
$lang->tree->delete = 'Delete';
$lang->tree->browse = 'Manage general module';
$lang->tree->browseTask = 'Manage task module';
@@ -31,8 +29,6 @@ $lang->tree->manageBugChild = 'Manage bug child';
$lang->tree->manageCaseChild = 'Manage case child';
$lang->tree->manageTaskChild = "Manage {$lang->projectCommon} child";
$lang->tree->syncFromProduct = 'Copy';
$lang->tree->ajaxGetOptionMenu = 'API: Get select menu';
$lang->tree->ajaxGetSonModules = 'API: Get son modules';
$lang->tree->confirmDelete = 'Are you sure to delete this module and its children?';
$lang->tree->confirmRoot = "Modify the module {$lang->productCommon}s, modified the {$lang->productCommon}s belong to the needs of the module, bug, use case, and {$lang->projectCommon} and {$lang->productCommon} relationship. This is dangerous, please be careful. To confirm the change?";
-4
View File
@@ -11,9 +11,7 @@
*/
$lang->tree = new stdclass();
$lang->tree->common = '模块维护';
$lang->tree->add = '添加';
$lang->tree->edit = '编辑';
$lang->tree->addChild = '添加子模块';
$lang->tree->delete = '删除模块';
$lang->tree->browse = '通用模块维护';
$lang->tree->browseTask = '任务模块维护';
@@ -31,8 +29,6 @@ $lang->tree->manageBugChild = '维护Bug子模块';
$lang->tree->manageCaseChild = '维护用例子模块';
$lang->tree->manageTaskChild = "维护{$lang->projectCommon}子模块";
$lang->tree->syncFromProduct = '复制';
$lang->tree->ajaxGetOptionMenu = '接口:获取下拉列表';
$lang->tree->ajaxGetSonModules = '接口:获得子菜单列表';
$lang->tree->confirmDelete = '该模块及其子模块都会被删除,您确定删除吗?';
$lang->tree->confirmRoot = "模块的所属{$lang->productCommon}修改,会关联修改该模块下的需求、Bug、用例的所属{$lang->productCommon},以及{$lang->projectCommon}和{$lang->productCommon}的关联关系。该操作比较危险,请谨慎操作。是否确认修改?";
-15
View File
@@ -21,7 +21,6 @@ $lang->user->group = 'Group';
$lang->user->realname = 'Fullname';
$lang->user->nickname = 'Nickname';
$lang->user->commiter = 'Commit account';
$lang->user->avatar = 'Avatar';
$lang->user->birthyear = 'Birth year';
$lang->user->gender = 'Gender';
$lang->user->email = 'Email';
@@ -43,7 +42,6 @@ $lang->user->visits = 'Visits';
$lang->user->ip = 'Last IP';
$lang->user->last = 'Last login';
$lang->user->ranzhi = 'Ranzhi account';
$lang->user->status = 'Status';
$lang->user->ditto = 'Ditto';
$lang->user->originalPassword = 'Original password';
$lang->user->verifyPassword = 'Enter your password';
@@ -53,33 +51,24 @@ $lang->user->index = "Index";
$lang->user->view = "Info";
$lang->user->create = "Add";
$lang->user->batchCreate = "Batch add user";
$lang->user->read = "Info";
$lang->user->edit = "Edit";
$lang->user->batchEdit = "Batch Edit";
$lang->user->editGroup = "Edit Group";
$lang->user->unlock = "Unlock";
$lang->user->update = "Upgrade";
$lang->user->delete = "Delete";
$lang->user->browse = "Browse";
$lang->user->unbind = "Unbind ranzhi";
$lang->user->login = "Login";
$lang->user->mobileLogin = "Mobile";
$lang->user->userView = "User view";
$lang->user->editProfile = "Edit profile";
$lang->user->editPassword = "Change password";
$lang->user->manageContacts = 'Manage contacts';
$lang->user->deleteContacts = 'Delete contacts';
$lang->user->deny = "Denied";
$lang->user->confirmDelete = "Are you sure to delete this user?";
$lang->user->confirmActivate = "Are you sure to activate this user?";
$lang->user->confirmUnlock = "Are you sure to unlock this user?";
$lang->user->confirmUnbind = "Are you sure to unbind this user to ranzhi?";
$lang->user->relogin = "Relogin";
$lang->user->asGuest = "Guest";
$lang->user->goback = "Back";
$lang->user->allUsers = 'All users';
$lang->user->deleted = '(deleted)';
$lang->user->select = 'Select user';
$lang->user->profile = 'Profile';
$lang->user->project = $lang->projectCommon;
@@ -90,9 +79,7 @@ $lang->user->testTask = 'Test task';
$lang->user->testCase = 'Test case';
$lang->user->todo = 'Todo';
$lang->user->story = 'Story';
$lang->user->team = 'Team';
$lang->user->dynamic = 'Dynamic';
$lang->user->ajaxGetUser = 'AJAX:get users';
$lang->user->openedBy = 'Opened by him';
$lang->user->assignedTo = 'Assigned to him';
@@ -111,7 +98,6 @@ $lang->user->loginFailed = "Login failed, please check your account and passwor
$lang->user->lockWarning = "You only have %s times to try.";
$lang->user->loginLocked = "You try the password too many times, please contact the administrator or try again after %s minutes.";
$lang->user->weakPassword = "Your password strength is less than the system settings.";
$lang->user->ipLimited = "Login failed, this ip is limited.";
$lang->user->roleList[''] = '';
$lang->user->roleList['dev'] = 'Developer';
@@ -162,7 +148,6 @@ $lang->user->error->originalPassword = "The original password is not correct";
$lang->user->contacts = new stdclass();
$lang->user->contacts->common = 'Contacts';
$lang->user->contacts->listName = 'List name';
$lang->user->contacts->userList = 'User list';
$lang->user->contacts->manage = 'Manage List';
$lang->user->contacts->contactsList = 'List';
-15
View File
@@ -21,7 +21,6 @@ $lang->user->group = '分组';
$lang->user->realname = '真实姓名';
$lang->user->nickname = '昵称';
$lang->user->commiter = '源代码帐号';
$lang->user->avatar = '头像';
$lang->user->birthyear = '出生年';
$lang->user->gender = '性别';
$lang->user->email = '邮箱';
@@ -43,7 +42,6 @@ $lang->user->visits = '访问次数';
$lang->user->ip = '最后IP';
$lang->user->last = '最后登录';
$lang->user->ranzhi = '然之账号';
$lang->user->status = '状态';
$lang->user->ditto = '同上';
$lang->user->originalPassword = '原密码';
$lang->user->verifyPassword = '请输入你的密码';
@@ -53,33 +51,24 @@ $lang->user->index = "用户视图首页";
$lang->user->view = "用户详情";
$lang->user->create = "添加用户";
$lang->user->batchCreate = "批量添加用户";
$lang->user->read = "查看用户";
$lang->user->edit = "编辑用户";
$lang->user->batchEdit = "批量编辑";
$lang->user->editGroup = "编辑用户分组";
$lang->user->unlock = "解锁用户";
$lang->user->update = "编辑用户";
$lang->user->delete = "删除用户";
$lang->user->browse = "浏览用户";
$lang->user->unbind = "解除然之绑定";
$lang->user->login = "用户登录";
$lang->user->mobileLogin = "手机访问";
$lang->user->userView = "人员视图";
$lang->user->editProfile = "修改档案";
$lang->user->editPassword = "修改密码";
$lang->user->manageContacts = '维护联系人';
$lang->user->deleteContacts = '删除联系人';
$lang->user->deny = "访问受限";
$lang->user->confirmDelete = "您确定删除该用户吗?";
$lang->user->confirmActivate = "您确定激活该用户吗?";
$lang->user->confirmUnlock = "您确定解除该用户的锁定状态吗?";
$lang->user->confirmUnbind = "您确定解除该用户跟然之的绑定吗?";
$lang->user->relogin = "重新登录";
$lang->user->asGuest = "游客访问";
$lang->user->goback = "返回前一页";
$lang->user->allUsers = '全部用户';
$lang->user->deleted = '(已删除)';
$lang->user->select = '请选择用户';
$lang->user->profile = '档案';
$lang->user->project = $lang->projectCommon;
@@ -90,9 +79,7 @@ $lang->user->testTask = '测试任务';
$lang->user->testCase = '测试用例';
$lang->user->todo = '待办';
$lang->user->story = '需求';
$lang->user->team = '团队';
$lang->user->dynamic = '动态';
$lang->user->ajaxGetUser = '接口:获得用户';
$lang->user->openedBy = '由他创建';
$lang->user->assignedTo = '指派给他';
@@ -111,7 +98,6 @@ $lang->user->loginFailed = "登录失败,请检查您的用户名或密码是
$lang->user->lockWarning = "您还有%s次尝试机会。";
$lang->user->loginLocked = "密码尝试次数太多,请联系管理员解锁,或%s分钟后重试。";
$lang->user->weakPassword = "您的密码强度小于系统设定。";
$lang->user->ipLimited = "登录失败,管理员限制当前IP登录。";
$lang->user->roleList[''] = '';
$lang->user->roleList['dev'] = '研发';
@@ -162,7 +148,6 @@ $lang->user->error->originalPassword = "原密码不正确";
$lang->user->contacts = new stdclass();
$lang->user->contacts->common = '联系人';
$lang->user->contacts->listName = '列表名称';
$lang->user->contacts->userList = '联系人列表';
$lang->user->contacts->manage = '维护列表';
$lang->user->contacts->contactsList = '已有列表';