0.2.0-beta.5
This commit is contained in:
parent
4a22088559
commit
ec12976b0f
17
CHANGELOG.md
17
CHANGELOG.md
|
|
@ -5,6 +5,14 @@ All notable changes to this project will be documented in this file.
|
|||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||
|
||||
## [0.2.0-beta.5]
|
||||
### Added
|
||||
- `Context::getBody()` method to retrieve the parsed JSON:API payload from the request
|
||||
- `Context::sortRequested()` method to determine if a sort field has been requested
|
||||
|
||||
### Fixed
|
||||
- `Laravel\rules()`: Fix regression disallowing use of advanced validation rules like callbacks and `Rule` instances. (@SychO9)
|
||||
|
||||
## [0.2.0-beta.4]
|
||||
### Added
|
||||
- `Laravel\rules()`: Replace `{id}` placeholder in rules with the model's key.
|
||||
|
|
@ -62,7 +70,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
### Fixed
|
||||
- Fix pagination next link appearing when it shouldn't
|
||||
|
||||
[0.2.0-beta.4]: https://github.com/tobyzerner/json-api-models/compare/v0.2.0-beta.4...v0.2.0-beta.3
|
||||
[0.2.0-beta.3]: https://github.com/tobyzerner/json-api-models/compare/v0.2.0-beta.3...v0.2.0-beta.2
|
||||
[0.2.0-beta.2]: https://github.com/tobyzerner/json-api-models/compare/v0.2.0-beta.2...v0.2.0-beta.1
|
||||
[0.2.0-beta.1]: https://github.com/tobyzerner/json-api-models/compare/v0.2.0-beta.1...v0.1.0-beta.1
|
||||
[0.2.0-beta.5]: https://github.com/tobyzerner/json-api-server/compare/v0.2.0-beta.5...v0.2.0-beta.4
|
||||
[0.2.0-beta.4]: https://github.com/tobyzerner/json-api-server/compare/v0.2.0-beta.4...v0.2.0-beta.3
|
||||
[0.2.0-beta.3]: https://github.com/tobyzerner/json-api-server/compare/v0.2.0-beta.3...v0.2.0-beta.2
|
||||
[0.2.0-beta.2]: https://github.com/tobyzerner/json-api-server/compare/v0.2.0-beta.2...v0.2.0-beta.1
|
||||
[0.2.0-beta.1]: https://github.com/tobyzerner/json-api-server/compare/v0.2.0-beta.1...v0.1.0-beta.1
|
||||
|
|
|
|||
|
|
@ -57,9 +57,15 @@ This object contains a number of useful methods:
|
|||
* `getPath(): string`
|
||||
Get the request path relative to the API's base path.
|
||||
|
||||
* `getBody(): ?array`
|
||||
Get the parsed JSON:API payload.
|
||||
|
||||
* `fieldRequested(string $type, string $field, bool $default = true): bool`
|
||||
Determine whether a field has been requested in a [sparse fieldset](https://jsonapi.org/format/1.1/#fetching-sparse-fieldsets).
|
||||
|
||||
* `sortRequested(string $field): bool`
|
||||
Determine whether a sort field has been requested.
|
||||
|
||||
* `filter(string $name): ?string`
|
||||
Get the value of a filter.
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue