This commit is contained in:
Yagami
2023-05-14 11:36:21 +08:00
parent 585d8e044a
commit cccf5cbd83
2 changed files with 6 additions and 2 deletions
+1 -1
View File
@@ -3520,7 +3520,7 @@ class execution extends control
/* Build the search form. */
$actionURL = $this->createLink($this->app->rawModule, 'linkStory', "objectID=$objectID&browseType=bySearch&queryID=myQueryID&recTotal=$recTotal&recPerPage=$recPerPage&pageID=$pageID&storyType=$storyType");
$branchGroups = $this->loadModel('branch')->getByProducts(array_keys($products));
$this->execution->buildStorySearchForm($products, $branchGroups, $modules, $queryID, $actionURL, 'linkStory', $object);
$this->execution->buildStorySearchForm($products, $branchGroups, $modules, $queryID, $actionURL, 'linkStory', $object, $storyType);
if($browseType == 'bySearch')
{
+5 -1
View File
@@ -2700,10 +2700,11 @@ class executionModel extends model
* @param string $actionURL
* @param string $type
* @param object $execution
* @param string $storyType
* @access public
* @return void
*/
public function buildStorySearchForm($products, $branchGroups, $modules, $queryID, $actionURL, $type = 'executionStory', $execution = null)
public function buildStorySearchForm($products, $branchGroups, $modules, $queryID, $actionURL, $type = 'executionStory', $execution = null, $storyType = 'story')
{
$this->app->loadLang('branch');
$branchPairs = array(BRANCH_MAIN => $this->lang->branch->main);
@@ -2760,6 +2761,9 @@ class executionModel extends model
$this->config->product->search['fields']['branch'] = sprintf($this->lang->product->branch, $this->lang->product->branchName[$productType]);
$this->config->product->search['params']['branch']['values'] = array('' => '') + $branchPairs;
}
if($storyType == 'requirement') unset($this->config->product->search['fields']['plan']);
$this->config->product->search['params']['status'] = array('operator' => '=', 'control' => 'select', 'values' => $this->lang->story->statusList);
$project = $execution;