Skip to content
This repository was archived by the owner on Sep 10, 2021. It is now read-only.

Commit 2d36ccc

Browse files
author
Jamie Snape
committed
Remove demo
1 parent 50a13f0 commit 2d36ccc

File tree

19 files changed

+4
-606
lines changed

19 files changed

+4
-606
lines changed

core/AppController.php

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -267,10 +267,6 @@ public function preDispatch()
267267

268268
// Init Dynamic Help (the order makes sense for the animation)
269269
if ($this->view->isDynamicHelp) {
270-
if ($this->isDemoMode()) {
271-
$this->addDynamicHelp('.loginLink', MIDAS_DEMO_DYNAMIC_HELP, 'bottom left', 'top right');
272-
}
273-
274270
if ($this->logged) {
275271
$this->addDynamicHelp(
276272
'#startingGuideLink',
@@ -434,23 +430,6 @@ public function addDynamicHelp($selector, $text, $location = 'bottom right', $ar
434430
);
435431
}
436432

437-
/**
438-
* Check if demo mode is set.
439-
*
440-
* @return bool
441-
*/
442-
public function isDemoMode()
443-
{
444-
if (in_array('demo', Zend_Registry::get('modulesEnable'))) {
445-
/** @var SettingModel $settingModel */
446-
$settingModel = MidasLoader::loadModel('Setting');
447-
448-
return $settingModel->getValueByName('enabled', 'demo');
449-
}
450-
451-
return false;
452-
}
453-
454433
/** Disable the layout. */
455434
public function disableLayout()
456435
{

core/controllers/AdminController.php

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,6 @@ class AdminController extends AppController
2626
public $_components = array('Upgrade', 'Utility', 'MIDAS2Migration');
2727
public $_forms = array('Admin', 'Assetstore', 'Migrate');
2828

29-
/** init the controller */
30-
public function init()
31-
{
32-
if ($this->isDemoMode()) {
33-
$this->disableView();
34-
35-
return false;
36-
}
37-
}
38-
3929
/** run a task */
4030
public function taskAction()
4131
{

core/controllers/UserController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -699,7 +699,7 @@ public function userexistsAction()
699699
/** Settings page action */
700700
public function settingsAction()
701701
{
702-
if (!$this->logged || $this->isDemoMode()) {
702+
if (!$this->logged) {
703703
$this->disableView();
704704

705705
return false;

modules/demo/AppController.php

Lines changed: 0 additions & 25 deletions
This file was deleted.

modules/demo/Bootstrap.php

Lines changed: 0 additions & 24 deletions
This file was deleted.

modules/demo/Notification.php

Lines changed: 0 additions & 42 deletions
This file was deleted.

modules/demo/configs/module.ini

Lines changed: 0 additions & 8 deletions
This file was deleted.

modules/demo/constant/module.php

Lines changed: 0 additions & 36 deletions
This file was deleted.

modules/demo/controllers/AdminController.php

Lines changed: 0 additions & 88 deletions
This file was deleted.

0 commit comments

Comments
 (0)