Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/HuasoFoundries/phpPgAdmin6.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelipe Figueroa <amenadiel@gmail.com>2021-11-25 06:08:15 +0300
committerFelipe Figueroa <amenadiel@gmail.com>2021-11-25 06:08:15 +0300
commitb74660b55e38fd359732a441eb14652dec65e067 (patch)
tree816dcba16c6356bf8fa5c312714def4eecb75fd9 /src/controllers/BrowserController.php
parentf7b0193500faec8da57a29e907d9cf445b8356a8 (diff)
renames folders to align with namespacesHEADdevelop
Diffstat (limited to 'src/controllers/BrowserController.php')
-rw-r--r--src/controllers/BrowserController.php86
1 files changed, 0 insertions, 86 deletions
diff --git a/src/controllers/BrowserController.php b/src/controllers/BrowserController.php
deleted file mode 100644
index 64fadb58..00000000
--- a/src/controllers/BrowserController.php
+++ /dev/null
@@ -1,86 +0,0 @@
-<?php
-
-/**
- * PHPPgAdmin6
- */
-
-namespace PHPPgAdmin\Controller;
-
-use PHPPgAdmin\ArrayRecordSet;
-use PHPPgAdmin\Decorators\Decorator;
-
-/**
- * Base controller class.
- */
-class BrowserController extends BaseController
-{
- protected $no_db_connection = true;
-
- /**
- * Default method to render the controller according to the action parameter.
- *
- * @param null|mixed $action
- *
- * @return string
- */
- public function render($action = null)
- {
- if (null === $action) {
- $action = $this->action;
- }
-
- switch ($action) {
- case 'tree':
- return $this->doTree();
-
- break;
-
- default:
- return $this->doDefault();
-
- break;
- }
- }
-
- /**
- * Default method to render the browser iframe using jstree.
- *
- * @return string rendered html of the jstree template
- */
- public function doDefault()
- {
- $this->misc->setNoDBConnection(true);
-
- $this->setNoBottomLink(true);
-
- $viewVars = ['icon' => [
- 'Refresh' => $this->view->icon('Refresh'),
- 'Servers' => $this->view->icon('Servers'),
- ]];
-
- return $this->view->fetch('browser.twig', $viewVars);
- }
-
- /**
- * Renders the root element of the jstree.
- *
- * @return string json representation of the root element of the jstree
- */
- public function doTree()
- {
- $treedata = new ArrayRecordSet([]);
- $reqvars = [];
- $action = Decorator::url('/src/views/servers');
- $branch = Decorator::url('/src/views/servers', $reqvars, ['action' => 'tree']);
- // $this->dump($branch);
- $attrs = [
- 'text' => 'Servers',
- 'icon' => 'Servers',
- 'is_root' => 'true',
- 'action' => $action,
- 'branch' => $branch,
- ];
-
- return $this->printTree($treedata, $attrs, 'server');
- }
-}