* Fix bug #27615 and adjust code.

This commit is contained in:
曹延义
2022-09-23 13:43:05 +08:00
parent 7488846987
commit 2b13096af4
2 changed files with 3 additions and 6 deletions
+1 -4
View File
@@ -147,10 +147,7 @@ class port extends control
{
$filter = '';
if($model == 'task') $filter = 'estimate';
if($model == 'story')
{
if($this->session->storyType) $this->loadModel('story')->replaceUserRequirementLang();
}
if($model == 'story' and $this->session->storyType) $this->loadModel('story')->replaceUserRequirementLang();
$this->loadModel($model);
$importFields = !empty($_SESSION[$model . 'TemplateFields']) ? $_SESSION[$model . 'TemplateFields'] : $this->config->$model->templateFields;
+2 -2
View File
@@ -259,6 +259,8 @@ class portModel extends model
foreach($fields as $key => $field)
{
$field = trim($field);
if($model == 'bug' and $this->session->currentProductType == 'normal' and $field == 'branch') continue;
$modelFieldList = isset($this->modelFieldList[$field]) ? $this->modelFieldList[$field] : array();
foreach($portFieldList as $portField => $value)
@@ -472,9 +474,7 @@ class portModel extends model
if(!$tmpFile)
{
$rows = $this->getRowsFromExcel();
$modelData = $this->processRows4Fields($rows, $fields);
$modelData = $this->getNatureDatas($model, $modelData, $filter, $fields);
$this->createTmpFile($modelData);