Skip to content

Commit

Permalink
Prepare to release 2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
andersao committed Jun 27, 2015
1 parent 028acf8 commit 9d6ff9b
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 1 deletion.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ Laravel 5 Repositories is used to abstract the data layer, making our applicatio
[![Analytics](https://ga-beacon.appspot.com/UA-61050740-1/l5-repository/readme)](https://packagist.org/packages/prettus/l5-repository)

#### [See version 1.0.*](https://github.com/andersao/l5-repository/tree/1.0.4)
#### [See version 2.0.*](https://github.com/andersao/l5-repository/tree/2.0.14)
#### [Migrate to 2.0](migration-to-2.0.md)
#### [Migrate to 2.1](migration-to-2.1.md)

You want to know a little more about the Repository pattern? [Read this great article](http://bit.ly/1IdmRNS).

Expand Down Expand Up @@ -691,9 +693,11 @@ The cacheable methods are : all, paginate, find, findByField, findWhere, getByCr

### Validators

Requires [prettus/laravel-validator](https://github.com/prettus/laravel-validator). `composer require prettus/laravel-validator`

Easy validation with `prettus/laravel-validator`

[For more details click here](https://github.com/andersao/laravel-validator)
[For more details click here](https://github.com/prettus/laravel-validator)

#### Using a Validator Class

Expand Down Expand Up @@ -812,6 +816,8 @@ Presenters function as a wrapper and renderer for objects.

#### Fractal Presenter

Requires [Fractal](http://fractal.thephpleague.com/). `composer require league/fractal`

There are two ways to implement the Presenter, the first is creating a TransformerAbstract and set it using your Presenter class as described in the Create a Transformer Class.

The second way is to make your model implement the Transformable interface, and use the default Prenseter ModelFractarPresenter, this will have the same effect.
Expand Down
32 changes: 32 additions & 0 deletions migration-to-2.1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Laravel 5 Repositories

[![Analytics](https://ga-beacon.appspot.com/UA-61050740-1/l5-repository/migration-to-2.1)](https://packagist.org/packages/prettus/l5-repository)

Some changes between version 2.0 and 2.1

## Migrate from version 2.0 to 2.1

### Lumen Support

To use this package with Lumen , register the following service provider

```php
$app->register(Prettus\Repository\Providers\LumenRepositoryServiceProvider::class);
```

### Composer requirements

In version 2.0 some dependencies that could sometimes not be used in your project were always being downloaded regardless of whether they are used. In version 2.1 this package are as suggestions that will only be required if you want some features


#### [Validators](https://github.com/prettus/l5-repository#validators)

If you want to use validations directly to your repository, as is disbelieved in Section [Validators](https://github.com/prettus/l5-repository#validators) , you need to use the library `prettus/laravel-validator`.

`composer require prettus/laravel-validator`

#### [Presenters](https://github.com/prettus/l5-repository#presenters)

If you want to use presenters in your repository, you need to use the library [`league/fractal`](http://fractal.thephpleague.com/).

`composer require league/fractal`

0 comments on commit 9d6ff9b

Please sign in to comment.