-
Notifications
You must be signed in to change notification settings - Fork 19
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
Showing
80 changed files
with
7,119 additions
and
588 deletions.
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 |
---|---|---|
|
@@ -2,4 +2,6 @@ | |
/vendor | ||
composer.phar | ||
composer.lock | ||
.DS_Store | ||
.DS_Store | ||
/app/config/database.php | ||
/app/config/app.php |
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
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 |
---|---|---|
@@ -1,3 +1,7 @@ | ||
# Contribution Guidelines | ||
|
||
Please submit all issues and pull requests to the [laravel/framework](http://github.com/laravel/framework) repository! | ||
Bug reports go into issues. Be as detailed as possible. | ||
|
||
Discussion should ideally be first on IRC (#r/a/[email protected]) and then in a github issue if the discussion has any merit. | ||
|
||
Pull request to your heart's content if you fancy doing something that's lacking. |
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
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
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
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,70 @@ | ||
<?php | ||
|
||
class Admin extends BaseController { | ||
|
||
/* | ||
|-------------------------------------------------------------------------- | ||
| Admin Controller - Split this up maybe? | ||
|-------------------------------------------------------------------------- | ||
| | ||
| SUPAH SEKRIT | ||
| Except it's open-sourced. So that means no funky hacks. | ||
| Brace for an ACTUAL DASHBOARD | ||
| | ||
| // Dashboard | ||
| Route::controller('admin', 'AdminController'); | ||
| | ||
| MAGIC GOES HERE. | ||
| | ||
*/ | ||
|
||
public function __construct() { | ||
|
||
// Auth, naturally. | ||
//$this->beforeFilter('auth'); | ||
|
||
// ALL POST/PUT/DELETE REQUIRE CSRF TOKENS. | ||
$this->beforeFilter('csrf', ['on' => ['post', 'put', 'delete']]); | ||
|
||
} | ||
protected $layout = "admin"; | ||
|
||
public function getIndex() { | ||
$this->layout->content = View::make('admin.dashboard') | ||
->with("base", Config::get("app.base", "")); | ||
//->with("user", $this->user); | ||
} | ||
|
||
public function getUsers() {} | ||
public function getLogin() {} | ||
public function getLogout() {} | ||
public function getPending() {} | ||
public function getSongs() {} | ||
public function getProfile() {} | ||
public function getSettings() {} | ||
public function getNews() {} | ||
public function getBans() {} | ||
// /admin/dev-functions | ||
public function getDevFunctions() {} | ||
|
||
|
||
|
||
/** | ||
* DELETE functions | ||
* I am well aware that these dont properly adhere to REST. | ||
* TODO (Maybe): fix that. | ||
*/ | ||
|
||
// DELETE /admin/users?id={id}? | ||
public function deleteUsers() {} | ||
|
||
// DELETE /admin/pending?id={id} | ||
public function deletePending() {} | ||
|
||
// DELETE /admin/bans?id={id} | ||
public function deleteBans() {} | ||
|
||
// DELETE /admin/news?id={id} | ||
public function deleteNews() {} | ||
|
||
} |
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
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,107 @@ | ||
<?php | ||
|
||
class Home extends Player { | ||
|
||
/* | ||
|-------------------------------------------------------------------------- | ||
| Default Home Controller | ||
|-------------------------------------------------------------------------- | ||
| | ||
| Default Home Controller. | ||
| Passes in default variables since they are otherwise not available | ||
| in an @section() block. | ||
| | ||
| Route::get('/', 'HomeController@showHome'); | ||
| | ||
*/ | ||
|
||
protected $layout = 'master'; | ||
|
||
|
||
/** | ||
* Builds the homepage queue | ||
* | ||
* @return string | ||
*/ | ||
private function makeQueue() { | ||
$curqueue = $this->getQueueArray(); | ||
|
||
if (!$curqueue) | ||
$curqueue = [ | ||
["timestr" => "", "track" => ""], | ||
["timestr" => "", "track" => ""], | ||
["timestr" => "", "track" => ""], | ||
["timestr" => "", "track" => ""], | ||
["timestr" => "", "track" => ""], | ||
]; | ||
|
||
$html = ""; | ||
|
||
foreach($curqueue as $queue) { | ||
|
||
$queue["meta"] = htmlspecialchars($queue["meta"]); | ||
$diff = Helper::humanTimeDiff($queue["time"]); | ||
|
||
|
||
if ($queue["type"] == 1) | ||
$queue["meta"] = "<b>" . $queue["meta"] . "</b>"; | ||
|
||
$html .= <<<QUEUE | ||
<li class="list-group-item"> | ||
<div class="container"> | ||
<div class="col-md-4"> | ||
in {$diff} | ||
</div> | ||
<div class="col-md-8" style="line-height: 1; height: 30px;"> | ||
{$queue["meta"]} | ||
</div> | ||
</div> | ||
</li> | ||
QUEUE; | ||
} | ||
|
||
return $html; | ||
} | ||
|
||
private function makeLastPlayed() { | ||
$last_played = $this->getLastPlayedArray(); | ||
|
||
$html = ""; | ||
|
||
foreach ($last_played as $lp) { | ||
$diff = Helper::humanTimeDiff($lp["time"]); | ||
$html .= <<<LP | ||
<li class="list-group-item"> | ||
<div class="container"> | ||
<div class="col-md-4"> | ||
{$diff} ago | ||
</div> | ||
<div class="col-md-8" style="line-height: 1; height: 30px;"> | ||
{$lp["meta"]} | ||
</div> | ||
</div> | ||
</li> | ||
LP; | ||
} | ||
|
||
return $html; | ||
} | ||
|
||
|
||
/** | ||
* Show the homepage (and throw in a load of variables) | ||
* | ||
* @return void | ||
*/ | ||
public function showHome() { | ||
|
||
$this->layout->content = View::make($this->getTheme() . ".home") | ||
->with("base", Config::get("app.base", "")) | ||
->with("theme", $this->getTheme()) | ||
->with("queue", $this->makeQueue()) | ||
->with("lp", $this->makeLastPlayed()); | ||
|
||
} | ||
|
||
} |
This file was deleted.
Oops, something went wrong.
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,10 @@ | ||
<?php | ||
|
||
class IRC extends BaseController { | ||
|
||
protected $layout = "master"; | ||
|
||
public function show() { | ||
$this->layout->content = View::make($this->getTheme() . '.irc'); | ||
} | ||
} |
Oops, something went wrong.