新增用户界面的时区切换
This commit is contained in:
@@ -431,6 +431,8 @@ public class FormFilter extends org.apache.shiro.web.filter.authc.FormAuthentica
|
||||
data.put("company", Global.getProperty("companyName"));
|
||||
data.put("version", Global.getProperty("productVersion"));
|
||||
data.put("year", Global.getProperty("copyrightYear"));
|
||||
data.put("lang", Global.getLang(request));
|
||||
data.put("timeZone", Global.getTimeZone(request));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -458,7 +460,8 @@ public class FormFilter extends org.apache.shiro.web.filter.authc.FormAuthentica
|
||||
data.put("company", Global.getProperty("companyName"));
|
||||
data.put("version", Global.getProperty("productVersion"));
|
||||
data.put("year", Global.getProperty("copyrightYear"));
|
||||
data.put("lang", Global.getLang());
|
||||
data.put("lang", Global.getLang(request));
|
||||
data.put("timeZone", Global.getTimeZone(request));
|
||||
List<Map<String, Object>> roleList = ListUtils.newArrayList();
|
||||
String desktopUrl = null; String roleCode = (String)session.getAttribute("roleCode");
|
||||
Set<String> roleCodes = roleCode != null ? SetUtils.newHashSet(StringUtils.splitComma(roleCode)) : null;
|
||||
|
||||
@@ -8,6 +8,19 @@
|
||||
<% for(var dict in @DictUtils.getDictList('sys_lang_type')){ %>
|
||||
<li><a href="${ctxPath}/lang/${dict.dictValue}" onclick="location=this.href+'?url='+location.href;return false;">${dict.dictLabel}</a></li>
|
||||
<% } %>
|
||||
<li><a href="javascript:$('#timeZoneSelectName').click()">${@Global.getTimeZone()}</a></li>
|
||||
<div class="hide">
|
||||
<#form:treeselect id="timeZoneSelect" title="${text('时区选择')}" allowClear="false"
|
||||
url="${ctxPath}/timeZone/treeData" callbackFuncName="timeZoneSelectCallback" boxWidth="350"/>
|
||||
<script>
|
||||
function timeZoneSelectCallback(id, act){
|
||||
if (id == 'timeZoneSelect' && (act == 'ok')){
|
||||
var timeZoneId = $('#timeZoneSelectCode').val();
|
||||
location = '${ctxPath}/timeZone?id=' + js.encodeUrl(timeZoneId) + '&url=' + location.href;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<li class="mt10"></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
Reference in New Issue
Block a user