removed before sheet event

This commit is contained in:
Cihan Şentürk 2024-04-25 12:19:18 +03:00 committed by GitHub
parent eef5227b45
commit cd00f26db9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 0 additions and 27 deletions

View File

@ -146,30 +146,6 @@ abstract class Export implements FromCollection, HasLocalePreference, ShouldAuto
}
}
public function beforeSheet($event)
{
$condition = class_exists($this->request_class)
? ! ($request = new $this->request_class) instanceof FormRequest
: true;
if (empty($this->column_validations) && $condition) {
return [];
}
$alphas = range('A', 'Z');
foreach ($this->fields as $key => $value) {
$drop_column = $alphas[$key];
if ($this->setColumnValidations($drop_column, $event, $value)) {
continue;
};
$this->validationWarning($drop_column, $event, $value, $request);
}
}
public function setColumnValidations($drop_column, $event, $value)
{
if (! isset($this->column_validations[$value])) {
@ -305,9 +281,6 @@ abstract class Export implements FromCollection, HasLocalePreference, ShouldAuto
AfterSheet::class => function(AfterSheet $event) {
$this->afterSheet($event);
},
BeforeSheet::class => function(BeforeSheet $event) {
$this->beforeSheet($event);
},
];
}
}