You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					
					
						
							48 lines
						
					
					
						
							1.2 KiB
						
					
					
				
			
		
		
		
			
			
			
				
					
				
				
					
				
			
		
		
	
	
							48 lines
						
					
					
						
							1.2 KiB
						
					
					
				
								<?php
							 | 
						|
								
							 | 
						|
								/**
							 | 
						|
								
							 | 
						|
								 * [Laike System] Copyright (c) 2018 laiketui.com
							 | 
						|
								
							 | 
						|
								 * Laike is not a free software, it under the license terms, visited http://www.laiketui.com/ for more details.
							 | 
						|
								
							 | 
						|
								 */
							 | 
						|
								require_once(MO_LIB_DIR . '/DBAction.class.php');
							 | 
						|
								require_once(MO_LIB_DIR . '/ShowPager.class.php');
							 | 
						|
								require_once(MO_LIB_DIR . '/Tools.class.php');
							 | 
						|
								
							 | 
						|
								class IndexAction extends Action {
							 | 
						|
								
							 | 
						|
								    public function getDefaultView() {
							 | 
						|
								        $db = DBAction::getInstance();
							 | 
						|
								        $request = $this->getContext()->getRequest();
							 | 
						|
								        $sql = "select * from lkt_config where id = '1'";
							 | 
						|
								        $r = $db->select($sql);
							 | 
						|
								        $uploadImg = $r[0]->uploadImg; // 图片上传位置
							 | 
						|
								        // 查询插件表
							 | 
						|
								        $sql = "select * from lkt_set_notice";
							 | 
						|
								        $r = $db->select($sql);
							 | 
						|
								        if(!empty($r)){
							 | 
						|
								            foreach ($r as $k => $v) {
							 | 
						|
								                if($v->img_url == ''){
							 | 
						|
								                    $v->img_url = 'nopic.jpg';
							 | 
						|
								                }
							 | 
						|
								            }
							 | 
						|
								        }
							 | 
						|
								        $request->setAttribute("uploadImg",$uploadImg);
							 | 
						|
								        $request->setAttribute("list",$r);
							 | 
						|
								
							 | 
						|
								        return View :: INPUT;
							 | 
						|
								    }
							 | 
						|
								
							 | 
						|
								    public function execute() {
							 | 
						|
								
							 | 
						|
								    }
							 | 
						|
								
							 | 
						|
								    public function getRequestMethods(){
							 | 
						|
								        return Request :: NONE;
							 | 
						|
								    }
							 | 
						|
								
							 | 
						|
								}
							 | 
						|
								
							 | 
						|
								?>
							 |