Skip to content

Commit

Permalink
Merge pull request #19 from kirkita/3.x
Browse files Browse the repository at this point in the history
export visibility property of file upload
  • Loading branch information
eighty9nine authored Jul 20, 2024
2 parents d3acf88 + 49515c9 commit b9c8a5a
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/ExcelImportAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ class ExcelImportAction extends Action

protected ?string $disk = null;

protected string | Closure $visibility = 'public';

public function use(string $class = null, ...$attributes): static
{
$this->importClass = $class ?: DefaultImport::class;
Expand All @@ -28,6 +30,13 @@ protected function getDisk()
return $this->disk ?: config('filesystems.default');
}

public function visibility(string | Closure | null $visibility): static
{
$this->visibility = $visibility;

return $this;
}

public static function getDefaultName(): ?string
{
return 'import';
Expand Down Expand Up @@ -57,6 +66,7 @@ protected function getDefaultForm(): array
})
->default(1)
->disk($this->getDisk())
->visibility($this->visibility)
->columns()
->required(),
];
Expand Down

0 comments on commit b9c8a5a

Please sign in to comment.