* Finish task #5111.

This commit is contained in:
chenfeiCF
2018-11-13 13:49:08 +08:00
parent c30ce17efc
commit 424a98db4a
10 changed files with 64 additions and 7 deletions
+14 -1
View File
@@ -1421,10 +1421,11 @@ class bug extends control
*
* @param string $productID
* @param string $orderBy
* @param string $browseType
* @access public
* @return void
*/
public function export($productID, $orderBy)
public function export($productID, $orderBy, $browseType = '')
{
if($_POST)
{
@@ -1603,6 +1604,18 @@ class bug extends control
$this->fetch('file', 'export2' . $this->post->fileType, $_POST);
}
$fileName = $this->lang->bug->common;
$productName = $this->dao->findById($productID)->from(TABLE_PRODUCT)->fetch('name');
if(isset($this->lang->bug->featureBar['browse'][$browseType]))
{
$browseType = $this->lang->bug->featureBar['browse'][$browseType];
}
else
{
$browseType = $this->lang->bug->moreSelects[$browseType];
}
$this->view->fileName = $productName . $this->lang->dash . $browseType . $fileName;
$this->view->allExportFields = $this->config->bug->list->exportFields;
$this->view->customExport = true;
$this->display();
+1 -1
View File
@@ -129,7 +129,7 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
</button>
<ul class='dropdown-menu' id='exportActionMenu'>
<?php
$link = $this->createLink('bug', 'export', "productID=$productID&orderBy=$orderBy");
$link = $this->createLink('bug', 'export', "productID=$productID&orderBy=$orderBy&browseType=$browseType");
echo "<li>" . html::a($link, $lang->bug->export, '', "class='export'") . "</li>";
?>
</ul>