Skip to content

Commit

Permalink
Fixed issue: Survey timings not imported when importing survey archiv…
Browse files Browse the repository at this point in the history
…e (.lsa)
  • Loading branch information
c-schmitz committed Feb 24, 2013
1 parent bd5689f commit 6e4f6dc
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions application/helpers/admin/import_helper.php
Expand Up @@ -3377,6 +3377,7 @@ function importSurveyFile($sFullFilepath, $bTranslateLinksFields, $sNewSurveyNam
}
}
// Step 4 - import the timings file - if exists
Yii::app()->db->schema->refresh();
foreach ($aFiles as $aFile)
{
if (pathinfo($aFile['filename'], PATHINFO_EXTENSION) == 'lsi' && tableExists("survey_{$aImportResults['newsid']}_timings"))
Expand Down Expand Up @@ -4147,10 +4148,11 @@ function XMLImportTimings($sFullFilepath,$iSurveyID,$aFieldReMap=array())
$aLanguagesSupported[]=(string)$language;
}
$results['languages']=count($aLanguagesSupported);




// Return if there are no timing records to import
if (!isset($xml->timings->rows))
{
return $results;
}
switchMSSQLIdentityInsert('survey_'.$iSurveyID.'_timings',true);
foreach ($xml->timings->rows->row as $row)
{
Expand Down

0 comments on commit 6e4f6dc

Please sign in to comment.