-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
hulu8004
committed
Dec 11, 2015
0 parents
commit 2838e65
Showing
5,581 changed files
with
1,183,974 additions
and
0 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
APP_ENV=local | ||
APP_DEBUG=true | ||
APP_KEY=SomeRandomString | ||
|
||
DB_HOST=localhost | ||
DB_DATABASE=homestead | ||
DB_USERNAME=homestead | ||
DB_PASSWORD=secret | ||
|
||
CACHE_DRIVER=file | ||
SESSION_DRIVER=file | ||
QUEUE_DRIVER=sync | ||
|
||
MAIL_DRIVER=mandrill | ||
|
||
MANDRILL_SECRET= | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
* text=auto | ||
*.css linguist-vendored | ||
*.less linguist-vendored |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
/.idea | ||
/vendor | ||
/node_modules | ||
Homestead.yaml | ||
Homestead.json | ||
.env |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?php | ||
|
||
namespace App; | ||
|
||
use Illuminate\Database\Eloquent\Model; | ||
|
||
class Article extends Model | ||
{ | ||
public $table = 'pweb_articles'; | ||
|
||
public $dates = [ 'created_at', 'updated_at' ]; | ||
|
||
public $fillable = [ 'title', 'content', 'category' ]; | ||
|
||
public function categoryColor( $type ) | ||
{ | ||
$colors = [ | ||
'update' => 'primary', | ||
'maintenance' => 'danger', | ||
'event' => 'success', | ||
'contest' => 'warning', | ||
'other' => 'default' | ||
]; | ||
return $colors[$type]; | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<?php | ||
|
||
namespace App\Console\Commands; | ||
|
||
use Illuminate\Console\Command; | ||
use Illuminate\Foundation\Inspiring; | ||
|
||
class Inspire extends Command | ||
{ | ||
/** | ||
* The name and signature of the console command. | ||
* | ||
* @var string | ||
*/ | ||
protected $signature = 'inspire'; | ||
|
||
/** | ||
* The console command description. | ||
* | ||
* @var string | ||
*/ | ||
protected $description = 'Display an inspiring quote'; | ||
|
||
/** | ||
* Execute the console command. | ||
* | ||
* @return mixed | ||
*/ | ||
public function handle() | ||
{ | ||
$this->comment(PHP_EOL.Inspiring::quote().PHP_EOL); | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?php | ||
|
||
namespace App\Console; | ||
|
||
use Illuminate\Console\Scheduling\Schedule; | ||
use Illuminate\Foundation\Console\Kernel as ConsoleKernel; | ||
|
||
class Kernel extends ConsoleKernel | ||
{ | ||
/** | ||
* The Artisan commands provided by your application. | ||
* | ||
* @var array | ||
*/ | ||
protected $commands = [ | ||
\App\Console\Commands\Inspire::class, | ||
]; | ||
|
||
/** | ||
* Define the application's command schedule. | ||
* | ||
* @param \Illuminate\Console\Scheduling\Schedule $schedule | ||
* @return void | ||
*/ | ||
protected function schedule(Schedule $schedule) | ||
{ | ||
$schedule->command('inspire') | ||
->hourly(); | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<?php | ||
|
||
namespace App\Events; | ||
|
||
abstract class Event | ||
{ | ||
// | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
<?php | ||
|
||
namespace App\Exceptions; | ||
|
||
use Exception; | ||
use Illuminate\Database\Eloquent\ModelNotFoundException; | ||
use Symfony\Component\HttpKernel\Exception\HttpException; | ||
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; | ||
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler; | ||
|
||
class Handler extends ExceptionHandler | ||
{ | ||
/** | ||
* A list of the exception types that should not be reported. | ||
* | ||
* @var array | ||
*/ | ||
protected $dontReport = [ | ||
HttpException::class, | ||
ModelNotFoundException::class, | ||
]; | ||
|
||
/** | ||
* Report or log an exception. | ||
* | ||
* This is a great spot to send exceptions to Sentry, Bugsnag, etc. | ||
* | ||
* @param \Exception $e | ||
* @return void | ||
*/ | ||
public function report(Exception $e) | ||
{ | ||
return parent::report($e); | ||
} | ||
|
||
/** | ||
* Render an exception into an HTTP response. | ||
* | ||
* @param \Illuminate\Http\Request $request | ||
* @param \Exception $e | ||
* @return \Illuminate\Http\Response | ||
*/ | ||
public function render($request, Exception $e) | ||
{ | ||
if ($e instanceof ModelNotFoundException) { | ||
$e = new NotFoundHttpException($e->getMessage(), $e); | ||
} | ||
|
||
return parent::render($request, $e); | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
<?php | ||
|
||
namespace App\Hash; | ||
|
||
use Illuminate\Contracts\Hashing\Hasher as HasherContract; | ||
|
||
class Base64Hasher implements HasherContract | ||
{ | ||
/** | ||
* Hash the given value. | ||
* | ||
* @param string $value | ||
* @param array $options | ||
* @return string | ||
* @internal param bool $output | ||
*/ | ||
public function make( $value, array $options = [] ) | ||
{ | ||
return base64_encode( md5( $value, true ) ); | ||
} | ||
|
||
/** | ||
* Check the given plain value against a hash. | ||
* | ||
* @param string $value | ||
* @param string $hashedValue | ||
* @param array $options | ||
* @return bool | ||
*/ | ||
public function check($value, $hashedValue, array $options = []) | ||
{ | ||
if (strlen($hashedValue) === 0) { | ||
return false; | ||
} | ||
|
||
return $this->make($value) === $hashedValue; | ||
} | ||
|
||
/** | ||
* Check if the given hash has been hashed using the given options. | ||
* | ||
* @param string $hashedValue | ||
* @param array $options | ||
* @return bool | ||
*/ | ||
public function needsRehash($hashedValue, array $options = []) | ||
{ | ||
return false; | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
<?php | ||
|
||
namespace App\Hash; | ||
|
||
use Illuminate\Contracts\Hashing\Hasher as HasherContract; | ||
|
||
class MD5Hasher implements HasherContract | ||
{ | ||
/** | ||
* Hash the given value. | ||
* | ||
* @param string $value | ||
* @param array $options | ||
* @return string | ||
* @internal param bool $output | ||
*/ | ||
public function make( $value, array $options = [] ) | ||
{ | ||
return '0x' . md5( $value ); | ||
} | ||
|
||
/** | ||
* Check the given plain value against a hash. | ||
* | ||
* @param string $value | ||
* @param string $hashedValue | ||
* @param array $options | ||
* @return bool | ||
*/ | ||
public function check($value, $hashedValue, array $options = []) | ||
{ | ||
if (strlen($hashedValue) === 0) { | ||
return false; | ||
} | ||
|
||
return $this->make($value) === $hashedValue; | ||
} | ||
|
||
/** | ||
* Check if the given hash has been hashed using the given options. | ||
* | ||
* @param string $hashedValue | ||
* @param array $options | ||
* @return bool | ||
*/ | ||
public function needsRehash($hashedValue, array $options = []) | ||
{ | ||
return false; | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?php | ||
|
||
namespace App\Http\Controllers\Admin; | ||
|
||
use Efriandika\LaravelSettings\Facades\Settings; | ||
use Illuminate\Http\Request; | ||
|
||
use App\Http\Requests; | ||
use App\Http\Controllers\Controller; | ||
|
||
class InstallController extends Controller | ||
{ | ||
public function getIndex() | ||
{ | ||
|
||
} | ||
} |
Oops, something went wrong.