在 java文件中:
Map user= (Map) ServletActionContext.getContext().getSession().get(Constants.USER_CONTENT);
或者
Map user= (Map) ServletActionContext.getContext().getSession().get("tydic.dbp.user");
String staffCode = user.get("staffName")
在 jsp 中
<input id="userId" type="hidden" value="${session['tydic.dbp.user'].userId}" />
<input id="areaId" type="hidden" value="${session['tydic.dbp.user'].areaId }" />
<cas:zoneId>10000106</cas:zoneId>
<cas:userId>1</cas:userId>
<cas:deptName>省公司未知部门</cas:deptName>
<cas:staffLevelId>1</cas:staffLevelId>
<cas:updatePsdDate>2012-03-13 00:00:00.0</cas:updatePsdDate>
<cas:moble>18900000002</cas:moble>
<cas:areaId>0</cas:areaId>
<cas:mail>
[email protected]</cas:mail>
<cas:isSso>0</cas:isSso>
<cas:positions>211</cas:positions>
<cas:empeePwd>1351562559213712921061951838224223133111149</cas:empeePwd>
<cas:staffCode>superAdmin</cas:staffCode>
<cas:imNo>0</cas:imNo>
<cas:zoneLevel>7770001</cas:zoneLevel>
<cas:staffAccount>admin</cas:staffAccount>
<cas:state>G01</cas:state>
<cas:createDate>2012-03-14 11:10:57.0</cas:createDate>
<cas:staffName>超级管理员</cas:staffName>