* finish task #5061.

This commit is contained in:
wangyidong
2018-11-07 11:58:40 +08:00
parent 4865ebe9f4
commit 6c6e84c52d
6 changed files with 21 additions and 21 deletions
+3 -3
View File
@@ -82,9 +82,9 @@ class bug extends control
if($this->cookie->preProductID != $productID or $this->cookie->preBranch != $branch)
{
$_COOKIE['bugModule'] = 0;
setcookie('bugModule', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('bugModule', 0, 0, $this->config->webRoot);
}
if($browseType == 'bymodule') setcookie('bugModule', (int)$param, $this->config->cookieLife, $this->config->webRoot);
if($browseType == 'bymodule') setcookie('bugModule', (int)$param, 0, $this->config->webRoot);
if($browseType != 'bymodule') $this->session->set('bugBrowseType', $browseType);
$moduleID = ($browseType == 'bymodule') ? (int)$param : ($browseType == 'bysearch' ? 0 : ($this->cookie->bugModule ? $this->cookie->bugModule : 0));
@@ -96,7 +96,7 @@ class bug extends control
/* Process the order by field. */
if(!$orderBy) $orderBy = $this->cookie->qaBugOrder ? $this->cookie->qaBugOrder : 'id_desc';
setcookie('qaBugOrder', $orderBy, $this->config->cookieLife, $this->config->webRoot);
setcookie('qaBugOrder', $orderBy, 0, $this->config->webRoot);
/* Append id for secend sort. */
$sort = $this->loadModel('common')->appendOrder($orderBy);
+3 -3
View File
@@ -118,9 +118,9 @@ class product extends control
if($this->cookie->preProductID != $productID or $this->cookie->preBranch != $branch)
{
$_COOKIE['storyModule'] = 0;
setcookie('storyModule', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('storyModule', 0, 0, $this->config->webRoot);
}
if($browseType == 'bymodule') setcookie('storyModule', (int)$param, $this->config->cookieLife, $this->config->webRoot);
if($browseType == 'bymodule') setcookie('storyModule', (int)$param, 0, $this->config->webRoot);
if($browseType != 'bymodule') $this->session->set('storyBrowseType', $browseType);
$moduleID = ($browseType == 'bymodule') ? (int)$param : ($browseType == 'bysearch' ? 0 : ($this->cookie->storyModule ? $this->cookie->storyModule : 0));
@@ -131,7 +131,7 @@ class product extends control
/* Process the order by field. */
if(!$orderBy) $orderBy = $this->cookie->productStoryOrder ? $this->cookie->productStoryOrder : 'id_desc';
setcookie('productStoryOrder', $orderBy, $this->config->cookieLife, $this->config->webRoot);
setcookie('productStoryOrder', $orderBy, 0, $this->config->webRoot);
/* Append id for secend sort. */
$sort = $this->loadModel('common')->appendOrder($orderBy);
+8 -8
View File
@@ -130,18 +130,18 @@ class project extends control
if($this->cookie->preProjectID != $projectID)
{
$_COOKIE['moduleBrowseParam'] = $_COOKIE['productBrowseParam'] = 0;
setcookie('moduleBrowseParam', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('productBrowseParam', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('moduleBrowseParam', 0, 0, $this->config->webRoot);
setcookie('productBrowseParam', 0, 0, $this->config->webRoot);
}
if($browseType == 'bymodule')
{
setcookie('moduleBrowseParam', (int)$param, $this->config->cookieLife, $this->config->webRoot);
setcookie('productBrowseParam', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('moduleBrowseParam', (int)$param, 0, $this->config->webRoot);
setcookie('productBrowseParam', 0, 0, $this->config->webRoot);
}
elseif($browseType == 'byproduct')
{
setcookie('moduleBrowseParam', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('productBrowseParam', (int)$param, $this->config->cookieLife, $this->config->webRoot);
setcookie('moduleBrowseParam', 0, 0, $this->config->webRoot);
setcookie('productBrowseParam', (int)$param, 0, $this->config->webRoot);
}
else
{
@@ -161,7 +161,7 @@ class project extends control
/* Process the order by field. */
if(!$orderBy) $orderBy = $this->cookie->projectTaskOrder ? $this->cookie->projectTaskOrder : 'status,id_desc';
setcookie('projectTaskOrder', $orderBy, $this->config->cookieLife, $this->config->webRoot);
setcookie('projectTaskOrder', $orderBy, 0, $this->config->webRoot);
/* Append id for secend sort. */
$sort = $this->loadModel('common')->appendOrder($orderBy);
@@ -592,7 +592,7 @@ class project extends control
/* Process the order by field. */
if(!$orderBy) $orderBy = $this->cookie->projectStoryOrder ? $this->cookie->projectStoryOrder : 'pri';
setcookie('projectStoryOrder', $orderBy, $this->config->cookieLife, $this->config->webRoot);
setcookie('projectStoryOrder', $orderBy, 0, $this->config->webRoot);
/* Append id for secend sort. */
$sort = $this->loadModel('common')->appendOrder($orderBy);
+3 -3
View File
@@ -69,10 +69,10 @@ class testcase extends control
if($this->cookie->preProductID != $productID or $this->cookie->preBranch != $branch)
{
$_COOKIE['caseModule'] = 0;
setcookie('caseModule', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('caseModule', 0, 0, $this->config->webRoot);
}
if($browseType == 'bymodule') setcookie('caseModule', (int)$param, $this->config->cookieLife, $this->config->webRoot);
if($browseType == 'bysuite') setcookie('caseSuite', (int)$param, $this->config->cookieLife, $this->config->webRoot);
if($browseType == 'bymodule') setcookie('caseModule', (int)$param, 0, $this->config->webRoot);
if($browseType == 'bysuite') setcookie('caseSuite', (int)$param, 0, $this->config->webRoot);
if($browseType != 'bymodule') $this->session->set('caseBrowseType', $browseType);
$moduleID = ($browseType == 'bymodule') ? (int)$param : ($browseType == 'bysearch' ? 0 : ($this->cookie->caseModule ? $this->cookie->caseModule : 0));
+2 -2
View File
@@ -404,10 +404,10 @@ class testsuite extends control
if($this->cookie->preCaseLibID != $libID)
{
$_COOKIE['libCaseModule'] = 0;
setcookie('libCaseModule', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('libCaseModule', 0, 0, $this->config->webRoot);
}
if($browseType == 'bymodule') setcookie('libCaseModule', (int)$param, $this->config->cookieLife, $this->config->webRoot);
if($browseType == 'bymodule') setcookie('libCaseModule', (int)$param, 0, $this->config->webRoot);
if($browseType != 'bymodule') $this->session->set('libBrowseType', $browseType);
$moduleID = ($browseType == 'bymodule') ? (int)$param : ($browseType == 'bysearch' ? 0 : ($this->cookie->libCaseModule ? $this->cookie->libCaseModule : 0));
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
+2 -2
View File
@@ -263,9 +263,9 @@ class testtask extends control
if($this->cookie->preTaskID != $taskID)
{
$_COOKIE['taskCaseModule'] = 0;
setcookie('taskCaseModule', 0, $this->config->cookieLife, $this->config->webRoot);
setcookie('taskCaseModule', 0, 0, $this->config->webRoot);
}
if($browseType == 'bymodule') setcookie('taskCaseModule', (int)$param, $this->config->cookieLife, $this->config->webRoot);
if($browseType == 'bymodule') setcookie('taskCaseModule', (int)$param, 0, $this->config->webRoot);
if($browseType != 'bymodule') $this->session->set('taskCaseBrowseType', $browseType);
$moduleID = ($browseType == 'bymodule') ? (int)$param : ($browseType == 'bysearch' ? 0 : ($this->cookie->taskCaseModule ? $this->cookie->taskCaseModule : 0));