📄 role.java
字号:
/**
* @function 角色管理
* @date 2006/12/08
* @author Janet
*
*/
package com.ufmobile.common.role.bo;
import java.util.List;
import javax.ejb.Local;
import javax.ejb.Remote;
import com.ufmobile.common.exception.RoleException;
import com.ufmobile.common.login.entity.UserInfo;
import com.ufmobile.common.role.entity.MemberroleEntity;
import com.ufmobile.common.role.entity.MenuEntity;
import com.ufmobile.common.role.entity.RoleEntity;
import com.ufmobile.common.role.entity.RolefuncEntity;
/**
* <p>
* <p>
* 创建日期:Dec 13, 2006
*
* @author msf
* @since v3.0
*/
@Remote
@Local
public interface Role {
public static final long ADMIN = 0L;//商街或中心管理员
public static final long OWNER = 100000L;//店主
public static final long ACCOUNTER = 100001L;//账房
public static final long WAITER = 100002L;//店小二
public static final long AGENT = 200000L;//代理商
/**
* @function 添加角色
* @param roleEntity 角色
* @throws RoleException
*/
public void addRole(RoleEntity roleEntity) throws RoleException;
/**
* @function 删除角色
* @param roleId 角色id
* @throws RoleException
*/
public void deleteRole(Long roleId) throws RoleException;
/**
* @function 更新角色
* @param roleEntity
* @throws RoleException
*/
public void updateRole(RoleEntity roleEntity) throws RoleException;
/**
* @funtion 查询角色
* @param roleId 角色Id
* @return 角色实体
* @throws RoleException
*/
public RoleEntity getRoleEntity(Long roleId) throws RoleException;
/**
* @function 获得所有的角色
* @return 角色列表
* @throws RoleException
*/
public List<RoleEntity> getAllRoles() throws RoleException;
/**
* @function 保存角色功能
* @param roleEntity
* @param sMenuCode 菜单编码数组
* @throws RoleException
*/
public void saveAssign(RoleEntity roleEntity, List<String> sMenuCode) throws RoleException;
/**
* @function 获得初始化的菜单,此时roleId=0
* @return 才单列表对象
* @throws RoleException
*/
public List<MenuEntity> getRoleMenu() throws RoleException;
/**
* <p>
* <p>
* 作者:msf <br>
* 日期:Dec 13, 2006
*
* @param ursid 用户id
* @param sysid 系统id(商街id或商铺id,由itype决定)
* @param roleid 角色id
* @param itype 0 会员,1 操作员,2 代理商
* @throws RoleException
*/
public void assignRole(Long ursid, Long sysid, Long Roleid, Integer itype) throws RoleException;
/**
* <p>
*
* <p>
* 作者:msf <br>
* 日期:Dec 22, 2006
* @param ursid
* @param sysid
* @param lRoleid 多个角色
* @param itype
* @throws RoleException
*/
public void assignRole(Long ursid, Long sysid, List lRoleid, Integer itype) throws RoleException;
/**
* <p>
* 收回角色
* <p>
* 作者:msf <br>
* 日期:Jan 9, 2007
* @param ursid
* @param itype
*/
public void revokeRole(Long ursid,Long sysid,Integer itype) throws RoleException;
/**
* <p>
* 获取指定类型的所有角色
* 0 会员 1 操作员 2 代理商
*
* <p>
* 作者:msf <br>
* 日期:Dec 13, 2006
*
* @param itype 0 会员,1 操作员,2 代理商
* @return
* @throws RoleException
*/
public List<RoleEntity> getRoles(Integer itype) throws RoleException;
/**
* <p>
*
* <p>
* 作者:msf <br>
* 日期:Dec 22, 2006
* @param itype
* @param usrid
* @return
* @throws RoleException
*/
@Deprecated
public List<RoleEntity> getRoles(Integer itype,Long systemid) throws RoleException;
/**
* <p>
*
* <p>
* 作者:msf <br>
* 日期:Dec 22, 2006
* @param itype
* @param systemid
* @param usrid
* @return
* @throws RoleException
*/
public List<List> getRolesbyUsrID(Integer itype,Long systemid,Long usrid) throws RoleException;
/**
* <p>
* 根据用户的id取角色
* <p>
* 作者:msf <br>
* 日期:Jan 24, 2007
* @param itype
* @param systemid
* @param usrid
* @return
* @throws RoleException
*/
public RoleEntity getRolesbyUsrID2(Integer itype,Long systemid,Long usrid) throws RoleException;
/**
* <p>
*分页查询
* <p>
* 作者:Janet Feng <br>
* 日期:Dec 18, 2006
* @param beginIndex 开始索引记录
* @param totalNumber 总记录
* @return
* @throws RoleException
*/
public List<RoleEntity> queryRoles ( int beginIndex , int maxNumber ) throws RoleException;
/**
* <p>
*
* <p>
* 作者:Janet Feng <br>
* 日期:Dec 25, 2006
* @param beginIndex
* @param maxNumber
* @param sys
* @return
* @throws RoleException
*/
public List<RoleEntity> queryRolesBySysPage ( int beginIndex , int maxNumber ,int sys) throws RoleException;
/**
* <p>
* 获取所有的角色
* <p>
* 作者:msf <br>
* 日期:Dec 26, 2006
* @param sys 0会员 1操作员 2代理商
* @return
* @throws RoleException
*/
public Long queryRolesBySysTotal ( int sys ) throws RoleException;
/**
* <p>
*
* 获取所有的需要控制的URL
* <p>
* 作者:msf <br>
* 日期:Dec 26, 2006
* @return
*/
public List<MenuEntity> getAllMenus()throws RoleException;
/**
* <p>
*根据商铺的id获得相应的
* <p>
* 作者:Janet Feng <br>
* 日期:Jan 8, 2007
* @param shopId
* @return
* @throws RoleException
*/
public List<MemberroleEntity> findMemberRoleEntityByShopId( Long shopId )throws RoleException;
/**
* <p>
* 根据角色id取角色菜单
* <p>
* 作者:msf <br>
* 日期:Jan 24, 2007
* @param roleID
* @return
* @throws RoleException
*/
public List<MenuEntity> getMenu(Long roleID) throws RoleException;
/**
* <p>
* 根据会员id取会员对应的商铺id和角色id
* <p>
* 作者:msf <br>
* 日期:Jan 25, 2007
* @param memberid
* @return
* @throws RoleException
*/
public List<MemberroleEntity> getRolebyMemberID(Long memberid)throws RoleException;
/**
* <p>
* 获取所有的功能点对应的页面
* <p>
* 作者:msf <br>
* 日期:Jan 26, 2007
* @return
* @throws RoleException
*/
public List<RolefuncEntity> queryFunc() throws RoleException;
/**
* <p>
* 获取相应类型的所有菜单
* <p>
* 作者:msf <br>
* 日期:Jan 26, 2007
* @param iType
* @return
* @throws RoleException
*/
public List<MenuEntity> getAllMenus(Integer iType) throws RoleException;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -