* Finish task #38920.

This commit is contained in:
tianshujie98
2021-06-04 17:30:09 +08:00
parent e4f221bf59
commit 80b876383c
7 changed files with 2 additions and 43 deletions
-1
View File
@@ -24,7 +24,6 @@ class todo extends control
$this->loadModel('task');
$this->loadModel('bug');
$this->loadModel('my')->setMenu();
if(!isset($this->config->qcVersion)) unset($this->lang->todo->typeList['review']);
}
/**
-1
View File
@@ -97,7 +97,6 @@ $lang->todo->typeList['cycle'] = 'Wiederkehrend';
$lang->todo->typeList['bug'] = 'Bug';
$lang->todo->typeList['task'] = 'Aufgabe';
$lang->todo->typeList['story'] = 'Story';
$lang->todo->typeList['review'] = 'Review';
$lang->todo->typeList['testtask'] = 'Testtask';
$lang->todo->confirmDelete = "Möchten Sie diesen ToDo löschen?";
-1
View File
@@ -98,7 +98,6 @@ $lang->todo->typeList['cycle'] = 'Recur';
$lang->todo->typeList['bug'] = 'Bug';
$lang->todo->typeList['task'] = 'Task';
$lang->todo->typeList['story'] = 'Story';
$lang->todo->typeList['review'] = 'Review';
$lang->todo->typeList['testtask'] = 'Testtask';
$lang->todo->confirmDelete = "Do you want to delete this todo?";
-1
View File
@@ -97,7 +97,6 @@ $lang->todo->typeList['cycle'] = 'Récur';
$lang->todo->typeList['bug'] = 'Bug';
$lang->todo->typeList['task'] = 'Tâche';
$lang->todo->typeList['story'] = 'Story';
$lang->todo->typeList['review'] = 'Review';
$lang->todo->typeList['testtask'] = 'Testtask';
$lang->todo->confirmDelete = "Voulez-vous supprimer cette entrée de l'agenda ?";
-1
View File
@@ -97,7 +97,6 @@ $lang->todo->typeList['cycle'] = 'Lặp lại';
$lang->todo->typeList['bug'] = 'Bug';
$lang->todo->typeList['task'] = 'Nhiệm vụ';
$lang->todo->typeList['story'] = 'Câu chuyện';
$lang->todo->typeList['review'] = 'Review';
$lang->todo->typeList['testtask'] = 'Testtask';
$lang->todo->confirmDelete = "Bạn có muốn xóa việc này?";
-1
View File
@@ -98,7 +98,6 @@ $lang->todo->typeList['cycle'] = '周期';
$lang->todo->typeList['bug'] = 'Bug';
$lang->todo->typeList['task'] = '任务';
$lang->todo->typeList['story'] = $lang->SRCommon;
$lang->todo->typeList['review'] = '评审';
$lang->todo->typeList['testtask'] = '测试单';
$lang->todo->confirmDelete = "您确定要删除这条待办吗?";
+2 -37
View File
@@ -39,44 +39,9 @@ class todoModel extends model
->remove(implode(',', $this->config->todo->moduleList) . ',uid')
->get();
if(!isset($todo->pri))
if(!isset($todo->pri) and in_array($this->post->type, $this->config->todo->moduleList) and $this->post->type !== 'review')
{
if($this->post->type == 'task')
{
$todo->pri = $this->dao->select('pri')->from(TABLE_TASK)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
elseif($this->post->type == 'bug')
{
$todo->pri = $this->dao->select('pri')->from(TABLE_BUG)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
elseif($this->post->type == 'story')
{
$todo->pri = $this->dao->select('pri')->from(TABLE_STORY)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
elseif($this->post->type == 'testtask')
{
$todo->pri = $this->dao->select('pri')->from(TABLE_TESTTASK)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
elseif($this->post->type == 'issue' and isset($this->config->maxVersion))
{
$todo->pri = $this->dao->select('pri')->from(TABLE_ISSUE)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
elseif($this->post->type == 'risk' and isset($this->config->maxVersion))
{
$todo->pri = $this->dao->select('pri')->from(TABLE_RISK)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
elseif($this->post->type == 'review' and isset($this->config->maxVersion))
{
$todo->pri = $this->dao->select('pri')->from(TABLE_REVIEW)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
elseif($this->post->type == 'feedback' and isset($this->config->maxVersion))
{
$todo->pri = $this->dao->select('pri')->from(TABLE_FEEDBACK)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
elseif($this->post->type == 'opportunity' and isset($this->config->maxVersion))
{
$todo->pri = $this->dao->select('pri')->from(TABLE_OPPORTUNITY)->where('id')->eq($this->post->idvalue)->fetch('pri');
}
$todo->pri = $this->dao->select('pri')->from($this->config->objectTables[$this->post->type])->where('id')->eq($this->post->idvalue)->fetch('pri');
if($todo->pri == 'high') $todo->pri = 1;
if($todo->pri == 'middle') $todo->pri = 2;