mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2026-01-13 13:49:33 +00:00
Add export functionality to batch select and fix errors
This commit is contained in:
parent
facfb37383
commit
1fb137e89f
5 changed files with 10 additions and 5 deletions
|
|
@ -92,7 +92,7 @@ class EntityExporter
|
|||
$options = $resolver->resolve($options);
|
||||
|
||||
//Handle Excel formats by converting from CSV
|
||||
if (in_array($options['format'], ['xlsx', 'xls'])) {
|
||||
if (in_array($options['format'], ['xlsx', 'xls'], true)) {
|
||||
return $this->exportToExcel($entities, $options);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -346,7 +346,7 @@ class EntityImporter
|
|||
$this->configureOptions($resolver);
|
||||
$options = $resolver->resolve($options);
|
||||
|
||||
if (in_array($options['format'], ['xlsx', 'xls'])) {
|
||||
if (in_array($options['format'], ['xlsx', 'xls'], true)) {
|
||||
$this->logger->info('Converting Excel file to CSV', [
|
||||
'filename' => $file->getFilename(),
|
||||
'format' => $options['format'],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue