예제 #1
0
 /**
  * 테마를 출력한다.
  *
  * @return string
  */
 public function render()
 {
     // load assets
     $this->loadAssets();
     // get configuration data of theme
     $config = $this->getConfig();
     // get menu & selected menu
     $mainMenu = $this->getMenu($config, 'mainmenu', true);
     $selectedMenu = $this->selectedMenu;
     // get submenus
     $subMenus = [];
     if ($config['submenu1_title']) {
         $subMenus[$config['submenu1_title']] = $this->getMenu($config, 'submenu1');
     }
     if ($config['submenu2_title']) {
         $subMenus[$config['submenu2_title']] = $this->getMenu($config, 'submenu2');
     }
     if ($config['no_snb'] !== 'no_snb') {
         //$ctClass = 'container section';
         $sideMenu = $this->getMenu($config, 'mainmenu', true);
     }
     $config['sub'] = 'sub';
     $config['no_spot'] = '';
     $config['ct_class'] = 'container section';
     // render html
     return \View::make(Alice::getIdWith('views.sub'), compact('config', 'mainMenu', 'subMenus', 'selectedMenu', 'sideMenu'));
 }
예제 #2
0
 public function edit(Request $request)
 {
     $config = Theme::getThemeConfig($this->configId);
     // mode
     $sel_mode = [['value' => '', 'text' => 'none'], ['value' => 'green_mode', 'text' => 'green'], ['value' => 'red_mode', 'text' => 'red'], ['value' => 'yellow_mode', 'text' => 'yellow']];
     // snb
     $sel_no_snb = [['value' => '', 'text' => '사용'], ['value' => 'no_snb', 'text' => '사용 안 함']];
     // bg_none
     $sel_bg_none = [['value' => 'bg_none', 'text' => '숨김'], ['value' => '', 'text' => '보임']];
     // header_scroll
     $sel_header_scroll = [['value' => 'blue_scroll', 'text' => 'blue'], ['value' => 'white_scroll', 'text' => 'white'], ['value' => 'black_scroll', 'text' => 'black']];
     $alias = Alice::getIdWith('option.update');
     $formAction = route($alias);
     return Presenter::make(Alice::getIdWith('views.config'), ['config' => $config, 'action' => $formAction, 'sel_mode' => $sel_mode, 'sel_no_snb' => $sel_no_snb, 'sel_bg_none' => $sel_bg_none, 'sel_header_scroll' => $sel_header_scroll]);
 }
예제 #3
0
 /**
  * 테마를 출력한다.
  *
  * @return string
  */
 public function render()
 {
     // load assets
     $this->loadAssets();
     // get configuration data of theme
     $config = $this->getConfig();
     $mainMenu = $this->getMenu($config, 'mainmenu');
     $subMenus = [];
     if ($config['submenu1_title']) {
         $subMenus[$config['submenu1_title']] = $this->getMenu($config, 'submenu1');
     }
     if ($config['submenu2_title']) {
         $subMenus[$config['submenu2_title']] = $this->getMenu($config, 'submenu2');
     }
     $config['no_snb'] = '';
     $config['no_spot'] = '';
     $config['snb'] = '';
     $config['ct_class'] = '';
     // render html
     return \View::make(Alice::getIdWith('views.main'), compact('config', 'mainMenu', 'subMenus'));
 }
예제 #4
0
 public static function getSettingsURI()
 {
     return route(Alice::getIdWith('option.edit'));
 }