Package com.lanyuan.controller

Source Code of com.lanyuan.controller.LogController

package com.lanyuan.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import com.lanyuan.entity.Log;
import com.lanyuan.service.LogService;
import com.lanyuan.util.Common;
import com.lanyuan.util.PageView;

/**
*
* @author lanyuan
* 2013-11-19
* @Email: mmm333zzz520@163.com
* @version 1.0v
*/
@Controller
@RequestMapping(value="/background/log/")
public class LogController {
  @Autowired
  private LogService logService;
 
  /**
   * 查询客户登陆信息
   * @param model
   * @param log
   * @param pageNow
   * @return
   */
  @RequestMapping(value="query")
  public String queryUserLogin(Model model, Log log, String pageNow){
    PageView pageView = null;
    if(Common.isEmpty(pageNow)){
      pageView = new PageView(1);
    }else{
      pageView = new PageView(Integer.parseInt(pageNow));
    }
    logService.query(pageView, log);
    model.addAttribute("pageView", pageView);
    return "/background/log/list";
  }

}
TOP

Related Classes of com.lanyuan.controller.LogController

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.