* code for task #1812.

This commit is contained in:
wyd621
2014-03-19 02:22:39 +00:00
parent 0c9211a2b1
commit 1a29d43cb0
8 changed files with 11 additions and 10 deletions

View File

@@ -28,7 +28,7 @@ class bug extends control
$this->loadModel('action');
$this->loadModel('story');
$this->loadModel('task');
$this->products = $this->product->getPairs();
$this->products = $this->product->getPairs('nocode');
if(empty($this->products))
{
echo js::alert($this->lang->product->errorNoProduct);

View File

@@ -194,12 +194,12 @@ class company extends control
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Get products' list.*/
$products = $this->loadModel('product')->getPairs();
$products = $this->loadModel('product')->getPairs('nocode');
$products = array($this->lang->product->select) + $products;
$this->view->products = $products;
/* Get projects' list.*/
$projects = $this->loadModel('project')->getPairs();
$projects = $this->loadModel('project')->getPairs('nocode');
$projects = array($this->lang->project->select) + $projects;
$this->view->projects = $projects;

View File

@@ -125,8 +125,8 @@ class doc extends control
/* Build the search form. */
$this->config->doc->search['actionURL'] = $this->createLink('doc', 'browse', "libID=$libID&moduleID=$moduleID&procuctID=$productID&projectID=$projectID&browseType=bySearch&queryID=myQueryID");
$this->config->doc->search['queryID'] = $queryID;
$this->config->doc->search['params']['product']['values'] = array(''=>'') + $this->product->getPairs() + array('all'=>$this->lang->doc->allProduct);
$this->config->doc->search['params']['project']['values'] = array(''=>'') + $this->project->getPairs() + array('all'=>$this->lang->doc->allProject);
$this->config->doc->search['params']['product']['values'] = array(''=>'') + $this->product->getPairs('nocode') + array('all'=>$this->lang->doc->allProduct);
$this->config->doc->search['params']['project']['values'] = array(''=>'') + $this->project->getPairs('nocode') + array('all'=>$this->lang->doc->allProject);
$this->config->doc->search['params']['lib']['values'] = array(''=>'') + $this->libs;
$this->config->doc->search['params']['type']['values'] = array(''=>'') + $this->config->doc->search['params']['type']['values'];

View File

@@ -325,7 +325,7 @@ class productplan extends control
$this->loadModel('bug');
$plan = $this->productplan->getByID($planID);
$this->commonAction($plan->product);
$products = $this->product->getPairs();
$products = $this->product->getPairs('nocode');
$productID = $plan->product;
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;

View File

@@ -378,7 +378,7 @@ class project extends control
$this->app->session->set('projectList', $uri);
$this->loadModel('bug');
$projects = $this->project->getPairs();
$projects = $this->project->getPairs('nocode');
$this->project->setMenu($projects, $projectID);
/* Load pager. */

View File

@@ -970,10 +970,11 @@ class storyModel extends model
* @param int $queryID
* @param string $orderBy
* @param object $pager
* @param string $projectID
* @access public
* @return array
*/
public function getBySearch($productID, $queryID, $orderBy, $pager, $projectID = '')
public function getBySearch($productID, $queryID, $orderBy, $pager = null, $projectID = '')
{
if($projectID != '')
{

View File

@@ -25,7 +25,7 @@ class testcase extends control
$this->loadModel('product');
$this->loadModel('tree');
$this->loadModel('user');
$this->view->products = $this->products = $this->product->getPairs();
$this->view->products = $this->products = $this->product->getPairs('nocode');
}
/**

View File

@@ -23,7 +23,7 @@ class testtask extends control
{
parent::__construct();
$this->loadModel('product');
$this->view->products = $this->products = $this->product->getPairs();
$this->view->products = $this->products = $this->product->getPairs('nocode');
}
/**