Package Data | |
---|---|
Maintainer Username: | JUB4 |
Maintainer Contact: | julianobailao@gmail.com (Juliano Bailão) |
Package Create Date: | 2017-01-29 |
Package Last Update: | 2017-02-01 |
Home Page: | |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-12-14 15:00:11 |
Package Statistics | |
---|---|
Total Downloads: | 66 |
Monthly Downloads: | 1 |
Daily Downloads: | 0 |
Total Stars: | 13 |
Total Watchers: | 1 |
Total Forks: | 2 |
Total Open Issues: | 0 |
This package will helps you build as quickly as possible your APIs, using pre-configured traits and resource controllers, see the wiki for more information.
Via Composer
$ composer require julianobailao/laravel-easy-api
Please, see the wiki for the full documentation of this project.
Create a model and configure it has you wish.
namespace App;
use Illuminate\Database\Eloquent\Model;
class Donkey extends Model
{
//
}
Create a controller, and use the ResourceTrait of this package. Exists one trait for each method from resource controller equivalent, if you want use a especific methods, and not all of then, read about Independent Methods.
namespace App\Http\Controllers;
use JulianoBailao\LaravelEasyApi\ResourceTrait;
class DonkeyController extends Controller
{
use ResourceTrait;
}
Configure your route like a resource controller:
Route::resource('donkeys', 'DonkeyController', ['except' => ['create', 'edit']]);
You have a resource controller with the index, show, store, update and destroy methods, runing for model Donkey, in the /donkeys route.
Please, see the wiki for the full documentation of this project.
The MIT License (MIT). Please see License File for more information.
Support this project and others, via PayPal.