Skip to content

Commit 6d91b3a

Browse files
authored
Merge pull request #434 from dbarzin/dev
add attributes export
2 parents d0229a7 + f99fcc9 commit 6d91b3a

File tree

6 files changed

+9
-10
lines changed

6 files changed

+9
-10
lines changed

app/Exports/AttributesExport.php

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@ public function headings(): array
2424

2525
public function styles(Worksheet $sheet)
2626
{
27-
// Fix unused
28-
$sheet;
27+
$sheet = null;
2928
// Return
3029
return [
3130
// Style the first row as bold text.
@@ -41,9 +40,6 @@ public function columnWidths(): array
4140
];
4241
}
4342

44-
/**
45-
* @var Attribute $attribute
46-
*/
4743
public function map($attribute): array
4844
{
4945
return [
@@ -54,7 +50,7 @@ public function map($attribute): array
5450
}
5551

5652
/**
57-
* @return \Illuminate\Support\Collection
53+
* @return \Illuminate\Database\Query\Builder
5854
*/
5955
public function query()
6056
{

app/Exports/MeasuresExport.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function styles(Worksheet $sheet)
4040
'wrapText' => true,
4141
'vertical' => 'top',
4242
],
43-
],
43+
² ],
4444
];
4545
}
4646

@@ -69,9 +69,6 @@ public function columnWidths(): array
6969
];
7070
}
7171

72-
/**
73-
* @var Measure $measure
74-
*/
7572
public function map($measure): array
7673
{
7774
return [

resources/lang/de/cruds.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,7 @@
191191
'report_title' => 'Report',
192192
'steering' => 'ISMS Lenkungsbericht',
193193
'data_export_title' => 'Datenexport',
194+
'attributes_export' => 'Exportiere Attributen',
194195
'domains_export'=> 'Exportiere Domänen',
195196
'measures_export' => 'Exportiere Sicherheitsmaßnahmen',
196197
'controls_export' => 'Exportiere Kontrollen',

resources/lang/en/cruds.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,7 @@
194194
'steering' => 'ISMS steering report',
195195
'data_export_title' => 'Data Export',
196196
'domains_export'=> 'Export domains ',
197+
'attributes_export' => 'Export attributes',
197198
'measures_export' => 'Export security measures',
198199
'controls_export' => 'Export controls',
199200
'import' => 'Import',

resources/lang/fr/cruds.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,7 @@
194194
'steering' => 'Rapport de pilotage du SMSI',
195195
'data_export_title' => 'Exportation des données',
196196
'domains_export'=> 'Exportation des domaines',
197+
'attributes_export' => 'Exportation des attributs',
197198
'measures_export' => 'Exportation des contrôles',
198199
'controls_export' => 'Exportation des mesures de sécurité',
199200
'actions_export' => 'Exporter les plans d\'action',

resources/views/reports.blade.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,9 @@
9595
<li>
9696
<a href="/export/domains" target="_blank">{{ trans('cruds.exports.domains_export') }}</a>
9797
</li>
98+
<li>
99+
<a href="/export/attributes" target="_blank">{{ trans('cruds.exports.attributes_export') }}</a>
100+
</li>
98101
<li>
99102
<a href="/export/alices" target="_blank">{{ trans('cruds.exports.controls_export') }}</a>
100103
</li>

0 commit comments

Comments
 (0)