This commit is contained in:
hufangzhou
2022-01-17 10:14:50 +08:00
parent 717ebf0004
commit a49076b0d8
3 changed files with 10 additions and 1 deletions
+1
View File
@@ -98,5 +98,6 @@ $lang->search->objectTypeList['story'] = $lang->SRCommon;
$lang->search->objectTypeList['requirement'] = $lang->URCommon;
$lang->search->objectTypeList['stage'] = 'stage';
$lang->search->objectTypeList['sprint'] = $lang->executionCommon;
$lang->search->objectTypeList['kanban'] = 'kanban';
$lang->search->objectTypeList['commonIssue'] = 'Issue';
$lang->search->objectTypeList['stakeholderIssue'] = 'Stakeholder Issue';
+1
View File
@@ -98,5 +98,6 @@ $lang->search->objectTypeList['story'] = $lang->SRCommon;
$lang->search->objectTypeList['requirement'] = $lang->URCommon;
$lang->search->objectTypeList['stage'] = '阶段';
$lang->search->objectTypeList['sprint'] = $lang->executionCommon;
$lang->search->objectTypeList['kanban'] = '看板';
$lang->search->objectTypeList['commonIssue'] = '问题';
$lang->search->objectTypeList['stakeholderIssue'] = '干系人问题';
+8 -1
View File
@@ -609,9 +609,16 @@ class searchModel extends model
$record->url = helper::createLink($module, $method, "id={$record->objectID}", '', false, $issue->project);
$record->extraType = empty($issue->owner) ? 'commonIssue' : 'stakeholderIssue';
}
elseif($module == 'project')
{
$projectModel = $this->dao->select('model')->from(TABLE_PROJECT)->where('id')->eq($record->objectID)->fetch('model');
$method = $projectModel == 'kanban' ? 'index' : 'view';
$record->url = helper::createLink('project', $method, "id={$record->objectID}");
}
elseif($module == 'execution')
{
$execution = $this->dao->select('id,type,project')->from(TABLE_EXECUTION)->where('id')->eq($record->objectID)->fetch();
$method = $execution->type == 'kanban' ? 'kanban' : $method;
$record->url = helper::createLink('execution', $method, "id={$record->objectID}");
$record->extraType = empty($execution->type) ? '' : $execution->type;
}
@@ -1015,7 +1022,7 @@ class searchModel extends model
->where('1')
->beginIF($type == 'program')->andWhere('type')->eq('program')->fi()
->beginIF($type == 'project')->andWhere('type')->eq('project')->fi()
->beginIF($type == 'execution')->andWhere('type')->in('stage,sprint')->fi()
->beginIF($type == 'execution')->andWhere('type')->in('stage,sprint,kanban')->fi()
->beginIF(isset($data->deleted))->andWhere('t1.deleted')->eq(0)->fi();
}
return $query;