Download the PHP package marshmallow/nova-date-range-field without Composer
On this page you can find all versions of the php package marshmallow/nova-date-range-field. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download marshmallow/nova-date-range-field
More information about marshmallow/nova-date-range-field
Files in marshmallow/nova-date-range-field
Package nova-date-range-field
Short Description A Laravel Nova field.
License MIT
Informations about the package nova-date-range-field

Date Range Field for Laravel Nova
A Laravel Nova field that provides a date range picker (powered by flatpickr). It can store a range across two model attributes (a "from" and a "till"), as a single value, or as JSON.
Installation
Install the package via Composer in your Nova project:
The field's assets are registered automatically through Marshmallow\NovaDateRangeField\FieldServiceProvider (Laravel package auto-discovery), so there is nothing else to publish or configure.
Usage
Use the DateRange field on a Nova resource and define the names of the from and till attributes together with the label. If no fields are set, the string value is stored in the database column of the field's attribute.
flatpickr options
Additional flatpickr options can be passed through the options array. These overwrite the field's default options (weekNumbers, defaultHour, defaultMinute).
Field options
The available chainable options (with their default behaviour) are:
When saveAsJSON() is used (or when the field's attribute is cast to array on the model), the range is stored as JSON on a single attribute instead of being split across the from and till columns.
Credits
Security Vulnerabilities
Please report security vulnerabilities by email rather than via the public issue tracker.
License
The MIT License (MIT). Please see the License File for more information.