Skip to content

Commit 7afea1c

Browse files
Update config comments
1 parent ec511b2 commit 7afea1c

File tree

1 file changed

+55
-43
lines changed

1 file changed

+55
-43
lines changed

config/excel.php

Lines changed: 55 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
use Maatwebsite\Excel\Excel;
44

55
return [
6-
76
'exports' => [
87

98
/*
@@ -64,19 +63,29 @@
6463

6564
'imports' => [
6665

66+
/*
67+
|--------------------------------------------------------------------------
68+
| Read Only
69+
|--------------------------------------------------------------------------
70+
|
71+
| When dealing with imports, you might only be interested in the
72+
| data that the sheet exists. By default we ignore all styles,
73+
| however if you want to do some logic based on style data
74+
| you can enable it by setting read_only to false.
75+
|
76+
*/
6777
'read_only' => true,
6878

79+
/*
80+
|--------------------------------------------------------------------------
81+
| Heading Row Formatter
82+
|--------------------------------------------------------------------------
83+
|
84+
| Configure the heading row formatter.
85+
| Available options: none|slug|custom
86+
|
87+
*/
6988
'heading_row' => [
70-
71-
/*
72-
|--------------------------------------------------------------------------
73-
| Heading Row Formatter
74-
|--------------------------------------------------------------------------
75-
|
76-
| Configure the heading row formatter.
77-
| Available options: none|slug|custom
78-
|
79-
*/
8089
'formatter' => 'slug',
8190
],
8291

@@ -104,7 +113,7 @@
104113
| Configure e.g. default title, creator, subject,...
105114
|
106115
*/
107-
'properties' => [
116+
'properties' => [
108117
'creator' => '',
109118
'lastModifiedBy' => '',
110119
'title' => '',
@@ -123,9 +132,8 @@
123132
| Extension detector
124133
|--------------------------------------------------------------------------
125134
|
126-
| Configure here which writer type should be used when
127-
| the package needs to guess the correct type
128-
| based on the extension alone.
135+
| Configure here which writer/reader type should be used when the package
136+
| needs to guess the correct type based on the extension alone.
129137
|
130138
*/
131139
'extension_detector' => [
@@ -157,39 +165,43 @@
157165
'pdf' => Excel::DOMPDF,
158166
],
159167

168+
/*
169+
|--------------------------------------------------------------------------
170+
| Value Binder
171+
|--------------------------------------------------------------------------
172+
|
173+
| PhpSpreadsheet offers a way to hook into the process of a value being
174+
| written to a cell. In there some assumptions are made on how the
175+
| value should be formatted. If you want to change those defaults,
176+
| you can implement your own default value binder.
177+
|
178+
| Possible value binders:
179+
|
180+
| [x] Maatwebsite\Excel\DefaultValueBinder::class
181+
| [x] PhpOffice\PhpSpreadsheet\Cell\StringValueBinder::class
182+
| [x] PhpOffice\PhpSpreadsheet\Cell\AdvancedValueBinder::class
183+
|
184+
*/
160185
'value_binder' => [
161-
162-
/*
163-
|--------------------------------------------------------------------------
164-
| Default Value Binder
165-
|--------------------------------------------------------------------------
166-
|
167-
| PhpSpreadsheet offers a way to hook into the process of a value being
168-
| written to a cell. In there some assumptions are made on how the
169-
| value should be formatted. If you want to change those defaults,
170-
| you can implement your own default value binder.
171-
|
172-
*/
173186
'default' => Maatwebsite\Excel\DefaultValueBinder::class,
174187
],
175188

189+
/*
190+
|--------------------------------------------------------------------------
191+
| Transaction Handler
192+
|--------------------------------------------------------------------------
193+
|
194+
| By default the import is wrapped in a transaction. This is useful
195+
| for when an import may fail and you want to retry it. With the
196+
| transactions, the previous import gets rolled-back.
197+
|
198+
| You can disable the transaction handler by setting this to null.
199+
| Or you can choose a custom made transaction handler here.
200+
|
201+
| Supported handlers: null|db
202+
|
203+
*/
176204
'transactions' => [
177-
178-
/*
179-
|--------------------------------------------------------------------------
180-
| Transaction Handler
181-
|--------------------------------------------------------------------------
182-
|
183-
| By default the import is wrapped in a transaction. This is useful
184-
| for when an import may fail and you want to retry it. With the
185-
| transactions, the previous import gets rolled-back.
186-
|
187-
| You can disable the transaction handler by setting this to null.
188-
| Or you can choose a custom made transaction handler here.
189-
|
190-
| Supported handlers: null|db
191-
|
192-
*/
193205
'handler' => 'db',
194206
],
195207

0 commit comments

Comments
 (0)