New

Just launched: Vueblocks, a brand-new search engine for Vue packages! Explore Vueblocks →

klepak/nova-multiselect-filter

Multiselect filter for Laravel Nova
183,939 14
Install
composer require klepak/nova-multiselect-filter
Latest Version:v1.2.4
PHP:^7.1|^8.0|^8.1
Laravel:5 – 9
License:MIT
Last Updated:Jun 20, 2024
Links: GitHub  ·  Packagist
Maintainer: knutle

Installation

composer require klepak/nova-multiselect-filter

Description

Multiselect filter for Laravel Nova. Based on vue-multiselect

example

Usage

use Illuminate\Http\Request;
use Klepak\NovaMultiselectFilter\NovaMultiselectFilter;

class CustomFilter extends NovaMultiselectFilter
{
    public function apply(Request $request, $query, $value)
    {
        return $query->whereIn('field', $value);
    }

    public function options(Request $request)
    {
        return [
            'Label 1' => 'value-1',
            'Label 2' => 'value-2',
            'Label 3' => 'value-3',
        ];
    }
}

Testing

composer test

Related Packages

outl1ne/nova-multiselect-field

A multiple select field for Laravel Nova.

4,251,130 343
optimistdigital/nova-multiselect-field

A multiple select field for Laravel Nova.

3,865,351 343
ampeco/nova-date-range-filter

A Laravel Nova date range filter.

1,077,590 35
suenerds/nova-searchable-belongs-to-filter

Searchable Nova filter for belongsTo relationships.

719,658 29
webard/nova-havingable

Havingable macro for Laravel Nova fields, allowing filtering of aggregated value...

3,172 0

Version History

Version Released PHP Laravel License
v1.2.4 ^7.1|^8.0|^8.1 ^5.8 || ^6.0 || ^7.0 || ^8.0 || ^9.0 MIT
v1.2.3 ^7.1|^8.0 ^5.8 || ^6.0 || ^7.0 || ^8.0 MIT
v1.2.2 ^7.1 ^5.8 || ^6.0 || ^7.0 || ^8.0 MIT
v1.2.1 ^7.1 ^5.8 || ^6.0 || ^7.0 MIT
v1.2 ^7.1 ^5.8 || 6.0 || ^7.0 MIT