Skip to content

Commit

Permalink
Merge pull request #4 from worksome/feature/laravel-11
Browse files Browse the repository at this point in the history
feat: add support for Laravel 11
  • Loading branch information
owenvoke authored Mar 20, 2024
2 parents 015dc6f + 601be54 commit 07f8ae4
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 39 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/static.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
name: PHPStan
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,20 @@ jobs:
fail-fast: true
matrix:
os: [ubuntu-latest]
php: [8.2]
laravel: [10.*]
stability: [prefer-lowest, prefer-stable]
php: [8.2, 8.3]
laravel: [10.*, 11.*]
stability: [prefer-stable]
include:
- laravel: 10.*
testbench: 8.*
- laravel: 11.*
testbench: 9.*

name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }} - ${{ matrix.stability }} - ${{ matrix.os }}

steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
Expand Down
7 changes: 0 additions & 7 deletions CHANGELOG.md

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ composer test

## Changelog

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.
Please see [GitHub Releases](https://github.com/worksome/laravel-filters/releases) for more information on what has changed recently.

## Contributing

Expand Down
9 changes: 0 additions & 9 deletions RELEASE.md

This file was deleted.

20 changes: 10 additions & 10 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,19 @@
],
"require": {
"php": "^8.2",
"illuminate/contracts": "^10.0",
"illuminate/database": "^10.0",
"spatie/laravel-package-tools": "^1.14.1",
"tucker-eric/eloquentfilter": "^3.2"
"illuminate/contracts": "^10.0 || ^11.0",
"illuminate/database": "^10.0 || ^11.0",
"spatie/laravel-package-tools": "^1.16",
"tucker-eric/eloquentfilter": "^3.3"
},
"require-dev": {
"ext-pdo": "*",
"nunomaduro/collision": "^7.0",
"nunomaduro/larastan": "^2.4.0",
"orchestra/testbench": "^8.0",
"pestphp/pest": "^2.0",
"pestphp/pest-plugin-laravel": "^2.0",
"worksome/coding-style": "^2.5"
"nunomaduro/collision": "^7.10 || ^8.1",
"larastan/larastan": "^2.6",
"orchestra/testbench": "^8.21 || ^9.0",
"pestphp/pest": "^2.33",
"pestphp/pest-plugin-laravel": "^2.2",
"worksome/coding-style": "^2.8"
},
"autoload": {
"psr-4": {
Expand Down
12 changes: 6 additions & 6 deletions src/FilterQuery.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function __construct(Repository $config)
}

/**
* @param class-string<TModel> $modelClass
* @param class-string<TModel> $modelClass
*
* @return self<TModel, TFilter>
*/
Expand All @@ -57,7 +57,7 @@ public function model(string $modelClass): self
}

/**
* @param class-string<TFilter> $filterClass
* @param class-string<TFilter> $filterClass
*
* @return self<TModel, TFilter>
*/
Expand All @@ -73,7 +73,7 @@ public function apply(string $filterClass): self
}

/**
* @param array<string, mixed> $input
* @param array<string, mixed> $input
*
* @return self<TModel, TFilter>
*/
Expand All @@ -85,7 +85,7 @@ public function input(array $input = []): self
}

/**
* @param Builder<TModel> $query
* @param Builder<TModel> $query
*
* @return self<TModel, TFilter>
*/
Expand Down Expand Up @@ -119,7 +119,7 @@ public function get(): Collection
}

/**
* @param array<string> $columns
* @param array<string> $columns
*
* @return LengthAwarePaginator<TModel>
*
Expand All @@ -140,7 +140,7 @@ public function paginateFilter(
}

/**
* @param array<int, string> $columns
* @param array<int, string> $columns
*
* @return Paginator<TModel>
*
Expand Down
1 change: 0 additions & 1 deletion src/ModelFilter.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
namespace Worksome\Filters;

use EloquentFilter\ModelFilter as BaseModelFilter;
use Illuminate\Database\Eloquent\SoftDeletes;
use Illuminate\Support\Str;

/**
Expand Down

0 comments on commit 07f8ae4

Please sign in to comment.