[Custom CSS Theme Support] Added fetching of theme list in options as well.
这个提交包含在:
		
							父节点
							
								
									d24eeafcdf
								
							
						
					
					
						当前提交
						ffbc7c4b6d
					
				
					共有  2 个文件被更改,包括 20 次插入 和 13 次删除
				
			
		|  | @ -41,6 +41,10 @@ class Options extends CI_Controller { | ||||||
| 		$data['page_title'] = "Cloudlog Options"; | 		$data['page_title'] = "Cloudlog Options"; | ||||||
| 		$data['sub_heading'] = "Appearance"; | 		$data['sub_heading'] = "Appearance"; | ||||||
| 
 | 
 | ||||||
|  | 		$this->load->model('Themes_model'); | ||||||
|  | 
 | ||||||
|  | 		$data['themes'] = $this->Themes_model->getThemes(); | ||||||
|  | 
 | ||||||
| 		$this->load->view('interface_assets/header', $data); | 		$this->load->view('interface_assets/header', $data); | ||||||
| 		$this->load->view('options/appearance'); | 		$this->load->view('options/appearance'); | ||||||
| 		$this->load->view('interface_assets/footer'); | 		$this->load->view('interface_assets/footer'); | ||||||
|  |  | ||||||
|  | @ -47,12 +47,15 @@ | ||||||
|                         <div class="form-group"> |                         <div class="form-group"> | ||||||
|                             <label for="themeSelect">Theme</label> |                             <label for="themeSelect">Theme</label> | ||||||
|                             <select class="custom-select" id="themeSelect" name="theme" aria-describedby="themeHelp" required> |                             <select class="custom-select" id="themeSelect" name="theme" aria-describedby="themeHelp" required> | ||||||
|                                 <option value='default' <?php if($this->optionslib->get_option('theme') == "default") { echo "selected=\"selected\""; } ?>>Default</option>
 | 								<?php | ||||||
|                                 <option value='blue' <?php if($this->optionslib->get_option('theme')== "blue") { echo "selected=\"selected\""; } ?>>Blue</option>
 | 								foreach ($themes as $theme) { | ||||||
|                                 <option value='cosmo' <?php if($this->optionslib->get_option('theme') == "cosmo") { echo "selected=\"selected\""; } ?>>Cosmo</option>
 | 									echo '<option value="' . $theme->foldername . '"'; | ||||||
|                                 <option value='cyborg' <?php if($this->optionslib->get_option('theme') == "cyborg") { echo "selected=\"selected\""; } ?>>Cyborg (Dark)</option>
 | 									if ($this->optionslib->get_option('theme') == $theme->foldername) { | ||||||
|                                 <option value='darkly' <?php if($this->optionslib->get_option('theme') == "darkly") { echo "selected=\"selected\""; } ?>> Darkly (Dark)</option>
 | 										echo 'selected="selected"'; | ||||||
|                                 <option value='superhero' <?php if($this->optionslib->get_option('theme') == "superhero") { echo "selected=\"selected\""; } ?>>Superhero (Dark)</option>
 | 									} | ||||||
|  | 									echo '>' . $theme->name . '</option>'; | ||||||
|  | 								} | ||||||
|  | 								?>
 | ||||||
|                                 </select> |                                 </select> | ||||||
|                             <small id="themeHelp" class="form-text text-muted">Global Theme Choice, this is used when users arent logged in.</small> |                             <small id="themeHelp" class="form-text text-muted">Global Theme Choice, this is used when users arent logged in.</small> | ||||||
|                         </div> |                         </div> | ||||||
|  |  | ||||||
		正在加载…
	
		在新工单中引用