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 | |
class Member extends Model implements MemberInterface | |
{ | |
const ATTR_DISPLAY_NAME = ‘display_name’; | |
const ATTR_LOGIN_NAME = ‘login_name’; | |
const ATTR_POST_COUNT = ‘posts’; | |
protected $fillable = [ | |
self::ATTR_LOGIN_NAME, |
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 | |
interface MemberInterface | |
{ | |
public function getID(); | |
public function getLoginName(); | |
public function getDisplayName(); | |
public function getPostCount(); | |
public function incrementPostCount(); | |
public function decrementPostCount(); |
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 ... // folded for brevity | |
return [ | |
'league.enable' => [ | |
'rules' => [ | |
AtLeastAdmin::class, | |
HasJurisdiction::class, | |
LeagueIsNotEnabled::class |
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 | |
class Member extends Model implements CurrentMember | |
{ | |
use ModelCache; | |
public function getLeaguePlayer(SectionInterface $section) | |
{ | |
return $this->cache(function(SectionInterface $section) { | |
return $this->leaguePlayers() | |
->where('section_id', $section->getID()) |
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; | |
use Request; | |
use View; | |
use App; | |
abstract class ApplicationsServiceProvider extends ServiceProvider | |
{ | |
public function register() |
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 GR\Clan; | |
use Illuminate\Database\Eloquent\Model; | |
use GR\Section\SectionInterface; | |
use GR\Member\MemberInterface; | |
use GR\Lib\ModelCache; | |
use GR\Member\Member; | |
class Clan extends Model implements ClanInterface | |
{ |
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
swwwwwwwwwwwwwwwwwwwwwwwt |
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
cat *.sql | mysql |
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
#!bin/bash | |
folder=$1 | |
if [ -z $1 ] | |
then | |
echo 'Please provide the root destination of the export:' | |
read folder | |
fi | |
git fetch --all |