Download the PHP package allanvb/nova-exports without Composer
On this page you can find all versions of the php package allanvb/nova-exports. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package nova-exports
Laravel Nova package to export resources
This package adds and universal export action to your nova application.
Requirements
laravel/nova: ^3.0
gobrightspot/nova-detached-actions: ^1.1
optimistdigital/nova-multiselect-field: ^2.0
kpolicar/nova-date-range: dev-master
rap2hpoutre/fast-excel: ^2.5
Usage
To use the export action, you must add it to actions
method of your resource.
Available methods
only(array $columns)
- Define whitelist of fields that can be exported.except(array $columns)
- Excludes the given fields from exporting list.filename(string $name)
- Sets the download filename.withUserSelection()
- Enables multi-select field that allow user to select the columns when exporting.usesDateRange(string $columnName)
- Enables field that allow user to select the range of dates when exporting. Default:created_at
usesGenerator()
- Enables cursor usage when getting data from database.queryBuilder(callable $query)
- Use own query on data exportation.disk(string $disk)
- The storage you want to use for storing export files.
withUserSelection
method cannot be used together with queryBuilder
method.
You are also able to use all of Nova Action methods, and all of Detached Actions methods on ExportResourceAction
.
Exceptions
The package can throw the following exceptions:
Exception | Reason |
---|---|
ColumnNotFoundException | Column does not exist in given table. |
EmptyDataException | No records to export. |
RangeColumnNotDateException | Given column for date range is not a date. |
To do
- [x] Export single resource
- [x] Implement user selection export
- [x] Implement generator on exporting
- [x] Add way to perform joins on export
- [ ] Add Eloquent relations export
- [ ] Add option to export to PDF
License
The MIT License (MIT). Please see License File for more information.
All versions of nova-exports with dependencies
PHP Build Version
Package Version
Requires
php Version
>=7.2.0|^8.0
nesbot/carbon Version ^2.31
laravel/nova Version ^3.0
gobrightspot/nova-detached-actions Version ^1.1
optimistdigital/nova-multiselect-field Version ^2.0
kpolicar/nova-date-range Version dev-master
rap2hpoutre/fast-excel Version ^3.0
nesbot/carbon Version ^2.31
laravel/nova Version ^3.0
gobrightspot/nova-detached-actions Version ^1.1
optimistdigital/nova-multiselect-field Version ^2.0
kpolicar/nova-date-range Version dev-master
rap2hpoutre/fast-excel Version ^3.0
The package allanvb/nova-exports contains the following files
Loading the files please wait ....