diff options
author | vincent-peugnet <v.peugnet@free.fr> | 2019-01-29 13:39:28 +0100 |
---|---|---|
committer | vincent-peugnet <v.peugnet@free.fr> | 2019-01-29 13:39:28 +0100 |
commit | 5e1ca86211da0439003303cf3e0741edf31bced4 (patch) | |
tree | 99fb2548f6eab18b510c9e5850af2459b05d1401 /app/class/controllerhome.php | |
parent | bd2ddfda3a922766ea2165963f2b2386066deeb2 (diff) | |
download | wcms-5e1ca86211da0439003303cf3e0741edf31bced4.tar.gz wcms-5e1ca86211da0439003303cf3e0741edf31bced4.zip |
home redirect
Diffstat (limited to 'app/class/controllerhome.php')
-rw-r--r-- | app/class/controllerhome.php | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/app/class/controllerhome.php b/app/class/controllerhome.php index cc2850f..043ac3e 100644 --- a/app/class/controllerhome.php +++ b/app/class/controllerhome.php @@ -16,17 +16,22 @@ class Controllerhome extends Controller public function desktop() { + if($this->user->isvisitor() && Config::homepage() === 'redirect' && Config::homeredirect() !== null) { + $this->routedirect('artread/', ['art' => Config::homeredirect()]); + } else { - $table = $this->modelhome->getlister(); - $this->opt = $this->modelhome->optinit($table); - - $table2 = $this->modelhome->table2($table, $this->opt); - - $columns = $this->modelhome->setcolumns($this->user->columns()); - - $this->showtemplate('home', ['user' => $this->user, 'table2' => $table2, 'opt' =>$this->opt, 'columns' => $columns]); - - + + $table = $this->modelhome->getlister(); + $this->opt = $this->modelhome->optinit($table); + + $table2 = $this->modelhome->table2($table, $this->opt); + + $columns = $this->modelhome->setcolumns($this->user->columns()); + + $this->showtemplate('home', ['user' => $this->user, 'table2' => $table2, 'opt' =>$this->opt, 'columns' => $columns]); + + + } } public function columns() |