BUGFIX: Fixed CSV export generating file with duplicated headers

This commit is contained in:
Carlos Barberis 2010-04-26 22:55:52 +00:00
parent 826c6b5829
commit f9152b6108

View File

@ -93,7 +93,12 @@ class SubmittedFormReportField extends FormField {
foreach($tmp as $array) {
$csvHeaderNames[] = $array['Name'];
$csvHeaderTitle[] = $array['Title'];
}
// We need Headers to be unique, query is returning headers multiple times (number of submissions).
// TODO: Fix query
$csvHeaderNames = array_unique($csvHeaderNames);
$csvHeaderTitle = array_unique($csvHeaderTitle);
// For every submission...
$i = 0;