This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php namespace App\Providers; | |
use Illuminate\Support\ServiceProvider; | |
class AppServiceProvider extends ServiceProvider { | |
//... | |
public function boot() | |
{ | |
//... | |
$this->loadViewsFrom(base_path('resources/views/painel'), 'painel'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php namespace App\Contracts\Repositories\Segregated; | |
use Illuminate\Database\Eloquent\Model; | |
interface Common | |
{ | |
/** | |
* @param bool $paginate | |
* @param \Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Query\Builder $query |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Illuminate\Database\Seeder; | |
use Illuminate\Database\Eloquent\Model; | |
#/database/seeds/DatabaseSeeder.php | |
class DatabaseSeeder extends Seeder | |
{ | |
// Este é o método executado quando executamos -> php artisan db:seed | |
public function run() | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Get the available container instance. | |
* | |
* @param string $make | |
* @param array $parameters | |
* @return mixed|\Illuminate\Foundation\Application | |
*/ | |
function app($make = null, $parameters = []) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Handle dynamic, static calls to the object. | |
*/ | |
public static function __callStatic($method, $args) | |
{ | |
$instance = static::getFacadeRoot(); | |
switch (count($args)) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php namespace Artesaos\SEOTools\Facades; | |
use Illuminate\Support\Facades\Facade; | |
class SEOMeta extends Facade | |
{ | |
protected static function getFacadeAccessor() | |
{ | |
return 'seotools.metatags'; | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$route = Route::getFacadeRoot(); ## \Illuminate\Routing\Router | |
$route = app('router'); ## \Illuminate\Routing\Router | |
$route->get(); | |
####################################### | |
use Illuminate\Http\Request; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
SEOMeta::setTitle('Página Inicial'); | |
SEOMeta::setDescription('Esta é a descrição da minha página'); | |
OpenGraph::setDescription('Esta é a descrição da minha página'); | |
OpenGraph::setTitle('Página Inicial'); | |
OpenGraph::setUrl('http://exemplo.url.com'); | |
OpenGraph::addProperty('type', 'articles'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use App\User; | |
use Illuminate\Database\Seeder; | |
class UserTableSeeder extends Seeder | |
{ | |
public function run() | |
{ | |
// Apaga toda a tabela de usuários |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Illuminate\Support\Collection; | |
use Illuminate\Database\Seeder; | |
class DefenderSeeder extends Seeder | |
{ | |
/** | |
* @var Collection; | |
*/ |