This file contains 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 | |
public function index() | |
{ | |
if(Input::get('sort')) { | |
$this->offices->sort(Input::get('sort'), Input::get('direction')); | |
} | |
$offices = $this->offices->all(); | |
return View::make('app.offices.list', compact('offices')); | |
} |
This file contains 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 Infrastructure\Database; | |
use DateTime, | |
Domain\Person\PersonEntity as Person, | |
Domain\Person\Name, | |
Domain\Person\Email; | |
class ExamplePersonDomainObjectTransformer extends AbstractTransformer | |
{ |
This file contains 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 | |
class ContactFormHandler | |
{ | |
public function __construct(ContactFormTemplate $template, ContactFormValidator $validator, ContactFormMailer $mailer) | |
{ | |
$this->template = $template; | |
$this->validator = $validator; | |
$this->mailer = $mailer; | |
} |
This file contains 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 | |
//Template for all required environment variables | |
return array( | |
'DB_USER' => '', | |
'DB_PASS' => '', | |
'DB_DATABASE' => '', | |
'BUGSNAG_KEY' => '', | |
'NEW_RELIC_APPNAME' => '' | |
); |
This file contains 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 | |
class ServiceContainer | |
{ | |
protected $services = []; | |
protected function setCallable($serviceKey, Callable $service) | |
{ | |
$this->services[$serviceKey] = $service; | |
return $this; |
This file contains 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 | |
class FacebookUrlHelper | |
{ | |
private $graphApiUrl; | |
private $fbHostname; | |
public function __construct($graphApiUrl = 'http://graph.facebook.com', $fbHostname = 'facebook.com') | |
{ |
This file contains 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 MyAppName\Http\Requests\Members; | |
use Illuminate\Contracts\Validation\Validator; | |
use InternalPackage\Laravel\Traits\SessionFlashNotifierTrait; | |
use MyAppName\Http\Requests\Request; | |
class ImportMembersRequest extends Request | |
{ | |
use SessionFlashNotifierTrait; |
This file contains 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 AppName\Posts\Post; | |
use Illuminate\Http\Request; | |
class GenericAclMiddleware | |
{ | |
private $entityClasses = [ | |
'post' => Post::class | |
]; |
This file contains 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 | |
//namespaces and imports excluded for brevity | |
abstract class AbstractImporter implements Importer | |
{ | |
/** | |
* @var ImportTransformer | |
*/ | |
private $transformer; | |
/** |
This file contains 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 MyApp\Domain; | |
class CountyElectionResult | |
{ | |
/** | |
* @var string | |
*/ | |
private $county; |
OlderNewer