2017 © Pedro Peláez
 

library laravel-repository-gateway-maker

image

nch7/laravel-repository-gateway-maker

  • Tuesday, July 21, 2015
  • by nch7
  • Repository
  • 1 Watchers
  • 0 Stars
  • 1 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

laravel-repository-gateway-maker

Repositories and Gateways are cool, but we are sometimes too lazy to set them up., (*1)

This package solves the problem, it handles automatic initialization and creating new Repositories & Gateways for you!, (*2)

Instructions

Install with composer, (*3)

"nch7/laravel-repository-gateway-maker" : "dev-master"

Add package service provider to app.php, (*4)

Nch7\LaravelRepositoryGatewayMaker\LaravelRepositoryGatewayMakerServiceProvider

Add psr-4 autoloading, (*5)

"psr-4" : {
  "acme\\": "app/acme/"
}

Initialize, (*6)

php artisan repogate:init

Add repository service provider to app.php, (*7)

acme\Repositories\RepositoryServiceProvider

Create Gateway and Repository for specific model, (*8)

php artisan repogate:make User

Examples

<?php

use acme\Gateways\UserGateway;

class UsersController extends BaseController {

    public function __construct(UserGateway $users) {
        $this->users = $users;
    }

    public function index()
    {
        return $this->users->all();
    }

}

The Versions

21/07 2015

dev-master

9999999-dev

  Sources   Download

The Requires

 

by Nick Chikovani