2017 © Pedro Peláez
 

library atlas-laravel

A Laravel 5 service provider for including the Atlas library.

image

fivesqrd/atlas-laravel

A Laravel 5 service provider for including the Atlas library.

  • Thursday, May 17, 2018
  • by christianjburger
  • Repository
  • 1 Watchers
  • 0 Stars
  • 45 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Atlas-Laravel

A Laravel service provider for the Atlas library, (*1)

Install

composer require fivesqrd/atlas-laravel, (*2)

Composer will automaticall register the provider and facade. If not:, (*3)

In config/app.php register the Atlas Service Provider in the "providers" array:, (*4)

    'providers' => array(
        // ...
        Atlas\Laravel\ServiceProvider::class,
    )

In config/app.php add the Atlas facade under "aliases":, (*5)

    'aliases' => array(
        // ...
        'Atlas' => Atlas\Laravel\AtlasFacade::class,
    )

Config

The config should be automatically created from the composer install. If not, run php artisan vendor:publish, (*6)

Atlas uses 'DB_DATABASE', 'DB_USERNAME' and 'DB_PASSWORD' values defined in the .env config file., (*7)

Usage

Atlas facade is now available can be instantiated throughout the application like this:, (*8)

\Atlas::model(App\Model\User::class)
  ->isActive(true)
  ->query()
  ->fetch()->all();
$user = \Atlas::model(App\Model\User::class)->fetch(1);
\Atlas::save($user);
\Atlas::relation($user)->tickets()->fetch()->all();

More usage examples for the Atlas API are avilable on the Atlas repo: http://github.com/Five-Squared/Atlas, (*9)

The Versions

17/05 2018

dev-master

9999999-dev

A Laravel 5 service provider for including the Atlas library.

  Sources   Download

MIT

The Requires

  • php >=5.5.9

 

The Development Requires

laravel laravel 5