-
Notifications
You must be signed in to change notification settings - Fork 210
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #927 from LuckyCyborg/master
Implementation of a **CRUD** for Users management on the Users Module
- Loading branch information
Showing
58 changed files
with
1,573 additions
and
197 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,7 +2,7 @@ | |
/** | ||
* Active Modules | ||
* | ||
* @author David Carr - [email protected] | ||
* @author David Carr - [email protected] | ||
* @author Virgil-Adrian Teaca - [email protected] | ||
* @version 3.0 | ||
*/ | ||
|
@@ -11,6 +11,7 @@ | |
|
||
|
||
Config::set('modules', array( | ||
'Dashboard', | ||
'Demos', | ||
'Users', | ||
)); |
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,13 @@ | ||
<?php | ||
/** | ||
* Config - the Module's specific Configuration. | ||
* | ||
* @author Virgil-Adrian Teaca - [email protected] | ||
* @version 3.0 | ||
*/ | ||
|
||
use Core\Config; | ||
|
||
/** | ||
* Configuration constants and options. | ||
*/ |
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,57 @@ | ||
<?php | ||
/** | ||
* Dasboard - Implements a simple Administration Dashboard. | ||
* | ||
* @author Virgil-Adrian Teaca - [email protected] | ||
* @version 3.0 | ||
*/ | ||
|
||
namespace App\Modules\Dashboard\Controllers\Admin; | ||
|
||
use Core\Controller; | ||
use Core\View; | ||
use Helpers\Url; | ||
|
||
|
||
class Dashboard extends Controller | ||
{ | ||
protected $template = 'AdminLte'; | ||
protected $layout = 'backend'; | ||
|
||
|
||
public function __construct() | ||
{ | ||
parent::__construct(); | ||
} | ||
|
||
protected function before() | ||
{ | ||
// Calculate and share on Views the URIs. | ||
$uri = Url::detectUri(); | ||
|
||
// Prepare the base URI. | ||
$parts = explode('/', trim($uri, '/')); | ||
|
||
// Make the path equal with the first part if it exists, i.e. 'admin' | ||
$baseUri = array_shift($parts); | ||
|
||
// Add to path the next part, if it exists, defaulting to 'dashboard'. | ||
if(! empty($parts)) { | ||
$baseUri .= '/' .array_shift($parts); | ||
} else if ($withDashboard) { | ||
$baseUri .= '/dashboard'; | ||
} | ||
|
||
View::share('currentUri', $uri); | ||
View::share('baseUri', $baseUri); | ||
|
||
return parent::before(); | ||
} | ||
|
||
public function index() | ||
{ | ||
return $this->getView() | ||
->shares('title', __d('dashboard', 'Dashboard')); | ||
} | ||
|
||
} |
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,12 @@ | ||
<?php | ||
/** | ||
* Events - all Module's specific Events are defined here. | ||
* | ||
* @author Virgil-Adrian Teaca - [email protected] | ||
* @version 3.0 | ||
*/ | ||
|
||
use Support\Facades\Event; | ||
|
||
|
||
/** Define Events. */ |
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,12 @@ | ||
<?php | ||
/** | ||
* Routing Filters - all Module's specific Routing Filters are defined here. | ||
* | ||
* @author Virgil-Adrian Teaca - [email protected] | ||
* @version 3.0 | ||
*/ | ||
|
||
use Routing\Route; | ||
|
||
|
||
/** Define Route Filters. */ |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => 'Skrivebord', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => 'داشبورد', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,7 @@ | ||
<?php | ||
|
||
return array ( | ||
'Dashboard' => '', | ||
'Someday, we\'ll have widgets and stuff on here...' => '', | ||
'Yup. This is the Dashboard.' => '', | ||
); |
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,18 @@ | ||
<?php | ||
/** | ||
* Routes - all Module's specific Routes are defined here. | ||
* | ||
* @author Virgil-Adrian Teaca - [email protected] | ||
* @version 3.0 | ||
*/ | ||
|
||
use Routing\Router; | ||
|
||
|
||
/** Define static routes. */ | ||
|
||
// The Adminstrations's Dashboard. | ||
Router::get('admin(/dashboard)', array( | ||
'filters' => 'auth', | ||
'uses' => 'App\Modules\Dashboard\Controllers\Admin\Dashboard@index' | ||
)); |
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
Oops, something went wrong.