Initial commit
This commit is contained in:
@@ -14,8 +14,9 @@ class SqlController extends Controller
|
||||
{
|
||||
parent::__construct();
|
||||
|
||||
// Only logged-in users can access the SQL console
|
||||
// Only admin users can access the SQL console
|
||||
Auth::checkAuthentication();
|
||||
Auth::checkAdminAuthentication();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -28,7 +29,7 @@ class SqlController extends Controller
|
||||
$database_name = Config::get('DB_NAME');
|
||||
}
|
||||
|
||||
$this->View->render('sql/index', array(
|
||||
$this->View->renderDbManager('sql/index', array(
|
||||
'database_name' => $database_name,
|
||||
'databases' => DatabaseModel::getAllDatabases(),
|
||||
'history' => SqlModel::getQueryHistory(Session::get('user_id'))
|
||||
|
||||
Reference in New Issue
Block a user