package com.ssm.service.system;

import java.util.List;

import javax.servlet.http.HttpSession;

import com.ssm.model.system.SysMenu;
import com.ssm.model.system.SysUser;




public interface SysMenuService {

	/**
	 * 获取菜单列表
	 * @param session 
	 * @param sysUser 
	 * @return
	 */
	public List<SysMenu> getMenuList(HttpSession session, SysUser sysUser);
	
	/**
	 * 设置当前选中的菜单项
	 */
	public void setCurrentMenu(List<SysMenu> lstMenuInfo, String menuId);

	public List<SysMenu> selectMenus(SysMenu menu);
	public List<SysMenu> menuTree(SysMenu menu);


	public List<SysMenu> updateMenu(SysMenu list);

	public void insertMenu(SysMenu menu);

	public void deleteMenuById(String id, Integer integer);

	public SysMenu selectByPrimaryKey(Integer menuid);

	public Integer selectCountByParentid(Integer parentid);

	public Integer selectMaxmenuIdByParentid(Integer parentid);

	public SysMenu selectByMenuId(Integer menuid);

	public List<SysMenu> selectFirstMenu();

	public List<SysMenu> selectFirstMenuByParentId(int parentId);

	public List<SysMenu> selectAllpageMenus();
	public List<SysMenu> selectMenusByPage();

	public Integer freezeMenuById(SysMenu menu);
	
	public void renewalMenuSession(HttpSession session,SysUser sysUser);
	
	public Integer selectMaxOrder();
	
	public Integer selectMaxOrderUnderParent(Integer parentId);
	
	public Integer selectMaxOrderIdUnderParent(Integer parentId);
	
	public int updateOrderBy(Integer orderBy);
	
	public int updateOrderByCount(Integer addNum, Integer orderBy);
	
	public int countSonMenu(Integer menuId);
	
	public int selectPrevOrder(Integer level, Integer orderBy, Integer parentId);
	
	public SysMenu selectMenuByOrderAndParent(Integer orderBy, Integer parentId);
	
	public List<SysMenu> selectMenuByOrderBy(Integer orderBy);
	
	public Integer selectNextOrder(Integer level, Integer orderBy, Integer parentId);
	
	public Integer selectNextLevel(Integer level, Integer orderBy);
	
	public Integer countAdd(Integer from, Integer to);
	
	public List<SysMenu> addOrderBy(Integer to, Integer from);
	
	public List<SysMenu> deleteOrderBy(Integer from, Integer next);
	
	public SysMenu selectMenuByUrl(String menuUrl);
}
