/**
  * Akce pro vygenerování náhledu na data
  * @param string $file
  * @param string $separator
  * @param string $encoding
  * @param string $enclosure
  * @param string $escape
  * @param string $nullValue="none"
  */
 public function renderImportCsvDataPreview($file, $separator = ',', $encoding = 'utf8', $enclosure = '"', $escape = '\\', $nullValue = "none")
 {
     $this->layout = 'blank';
     $this->fileImportsFacade->changeFileEncoding($file, $encoding);
     $this->template->colsCount = $this->fileImportsFacade->getColsCountInCSV($file, $separator, $enclosure, $escape);
     $rows = $this->fileImportsFacade->getRowsFromCSV($file, 20, $separator, $enclosure, $escape, $nullValue == 'none' ? null : $nullValue, 0);
     $rows[0] = CsvImport::sanitizeColumnNames($rows[0]);
     $this->template->rows = $rows;
 }