|
|
@@ -53,9 +53,12 @@ public class DzCardsController extends BaseController
|
|
|
@ApiOperation("列表")
|
|
|
public TableDataInfo list(DzCards dzCards)
|
|
|
{
|
|
|
- String userType = SecurityUtils.getLoginUser().getUser().getUserType();
|
|
|
- if(UserTypeEnum.isInstitution(userType)&&null==dzCards.getDeptId()){
|
|
|
+ SysUser sysUser = SecurityUtils.getLoginUser().getUser();
|
|
|
+ String userType = sysUser.getUserType();
|
|
|
+ if(UserTypeEnum.isInstitution(userType)){
|
|
|
dzCards.setDeptId(SecurityUtils.getDeptId());
|
|
|
+ } else if(UserTypeEnum.isSchool(userType)){
|
|
|
+ dzCards.setCampusId(sysUser.getUserTypeId());
|
|
|
}
|
|
|
if((UserTypeEnum.isAgent(userType)||UserTypeEnum.isTeacher(userType))&&null==dzCards.getAgentId()){
|
|
|
//代理商及老师只能查看分配给自己的卡
|