Skip to content

Commit

Permalink
Merge branch 'release/1.0.5'
Browse files Browse the repository at this point in the history
  • Loading branch information
hakobyansen committed Jan 25, 2021
2 parents bf6b775 + 983975a commit 52f4318
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 5 deletions.
16 changes: 12 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,19 +31,27 @@ or
```

## Installation
`composer require codebot/laravel-response-builder:0.2.*`
```
composer require codebot/laravel-response-builder:^1
```

**For Laravel 5.4 and versions below add `\Rb\Core\RbServiceProvider::class` to providers in config/app.php file.**

Next run `php artisan vendor:publish --tag=laravel-response-builder` command in your console.
Next run the command below in your console:

```
php artisan vendor:publish --tag=laravel-response-builder
```

## Requests

Once you published vendor, you should see `App\Http\Requests\Rb\RbRequest class`. This will be base class for
laravel-response-builder's requests.
To generate a request that extends RbRequest, do:
To generate a request that extends RbRequest, run:

`php artisan make:rbrequest YourNewRequest`
```
php artisan make:rbrequest YourNewRequest
```

If you are using Laravel's Validator class, you can use `Rb\Core\RbValidator` to standardize the structure of failed response.

Expand Down
3 changes: 3 additions & 0 deletions VERSIONLOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Versions

## 1.0.5 2021-01-25
* Documentation updated.

## 1.0.4 2021-01-25
* Updated the `RbServiceProvider` to publish `RbRequest` in same directory as specified in configs.

Expand Down
1 change: 1 addition & 0 deletions src/Configs/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

/**
* Generated request classes will be stored in specified "request_path" directory.
* Must be wrapped in base_path() helper.
*/

'request_path' => base_path( 'app/Http/Requests/ResponseBuilder' ),
Expand Down
2 changes: 1 addition & 1 deletion version.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"major":1,"minor":0,"patch":4}
{"major":1,"minor":0,"patch":5}

0 comments on commit 52f4318

Please sign in to comment.