8000 Merge tag 'v2.0.0-beta.1' into develop · ollivr/laravel-json-api@0bd5b07 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0bd5b07

Browse files
committed
Merge tag 'v2.0.0-beta.1' into develop
Initial version supporting Laravel 7
2 parents 6ecf775 + bca935e commit 0bd5b07

File tree

5 files changed

+8
-5
lines changed

5 files changed

+8
-5
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
All notable changes to this project will be documented in this file. This project adheres to
33
[Semantic Versioning](http://semver.org/) and [this changelog format](http://keepachangelog.com/).
44

5-
## 2.x
5+
## [2.0.0-beta.1] - 2020-03-04
66

77
### Added
88
- [#348](https://github.com/cloudcreativity/laravel-json-api/issues/348)

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ A demo application is available at [here](https://github.com/cloudcreativity/dem
6262

6363
| Laravel | This Package |
6464
| --- | --- |
65-
| `^7.0` | `^2.0` |
65+
| `^7.0` | `2.0.0-beta.1` |
6666
| `^6.0` | `^1.0` |
6767
| `5.8.*` | `^1.0` |
6868
| `5.7.*` | `^1.0` |

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@
7777
}
7878
}
7979
},
80-
"minimum-stability": "dev",
80+
"minimum-stability": "stable",
8181
"prefer-stable": true,
8282
"config": {
8383
"sort-packages": true

docs/basics/validators.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,8 @@ Accept: application/vnd.api+json
161161
"type": "posts",
162162
"attributes": {
163163
"title": "Hello World",
164-
"content": "..."
164+
"content": "...",
165+
"another-field": "..."
165166
},
166167
"relationships": {
167168
"author": {
@@ -195,6 +196,7 @@ Your validator will be provided with the following array of data:
195196
"id" => null,
196197
"title" => "Hello World",
197198
"content" => "...",
199+
"another-field" => "...",
198200
"author" => ["type" => "users", "id" => "123"],
199201
"tags" => [
200202
["type" => "tags", "id" => "1"],
@@ -221,6 +223,7 @@ class Validators extends AbstractValidators
221223
return [
222224
'title' => 'required|string|min:1|max:255',
223225
'content' => 'required|string|min:1',
226+
"another-field" => 'string|unique:posts,another_field',
224227
'author' => [
225228
'required',
226229
new HasOne('users'),

src/Api/Api.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ public function getJobs()
243243
}
244244

245245
/**
246-
* @return ContainerInterface|null
246+
* @return ContainerInterface
247247
*/
248248
public function getContainer()
249249
{

0 commit comments

Comments
 (0)
0