新增 切换部门功能、多部门岗位权限
This commit is contained in:
@@ -153,8 +153,11 @@ user:
|
||||
# 二级管理员的控制权限类型(1拥有的权限 2管理的权限,管理功能包括:用户管理、组织机构、公司管理等)(v4.1.5+)
|
||||
adminCtrlPermi: 2
|
||||
|
||||
# 是否启用岗位角色,开启后将 用户->岗位->关联角色,纳入菜单和权限管理
|
||||
# 是否启用岗位角色,开启后将 用户->岗位->关联角色,纳入菜单和权限管理 v5.9.2
|
||||
postRolePermi: false
|
||||
|
||||
# 是否启用切换部门功能,再开启启用岗位角色后可支持 用户->附属部门->岗位->关联角色,纳入菜单和权限管理 v5.10.1
|
||||
switchOffice: false
|
||||
|
||||
# 多租户模式(SAAS模式)(专业版)
|
||||
useCorpModel: false
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
<div class="navbar-custom-menu">
|
||||
<ul class="nav navbar-nav">
|
||||
<% include('/include/sysIndex/topMenuCorp.html'){} %>
|
||||
<% include('/include/sysIndex/topMenuOffice.html'){} %>
|
||||
<li><a href="javascript:" id="fullScreen" title="${text('全屏')}" data-placement="bottom" data-container="body"><i class="fa fa-arrows-alt"></i></a></li>
|
||||
<li><a href="javascript:" id="switchSkin" title="${text('切换主题')}" style="margin-top:-1px;" data-placement="bottom" data-container="body" data-layer-width="600" data-layer-height="350"><i class="fa fa-dashboard"></i></a></li>
|
||||
<% include('/include/sysIndex/topMenuLang.html'){} %>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<% if(@Global.getConfigToBoolean('user.useCorpModel', 'false') && hasPermi('sys:corpAdmin:edit')){ %>
|
||||
<li>
|
||||
<a href="javascript:" id="switchCorp">
|
||||
<i class="fa icon-home"></i> ${text('当前租户')}:(${session.corpCode}) ${session.corpName}
|
||||
<i class="fa icon-home"></i> ${text('当前租户')}:${currentCorpName}
|
||||
</a>
|
||||
<div class="hide"><#form:treeselect id="switchCorpSelect" title="${text('租户切换')}" allowClear="false"
|
||||
url="${ctx}/sys/corpAdmin/treeData?isShowCode=true" callbackFuncName="switchCorpSelectCallback"/>
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
<% if(toBoolean(switchOffice!)){ %>
|
||||
<li>
|
||||
<a href="javascript:" id="switchOffice">
|
||||
<i class="fa icon-grid" style="font-size:12px;"></i> ${officeName!}
|
||||
</a>
|
||||
<div class="hide"><#form:treeselect id="switchOfficeSelect" title="${text('部门切换')}" allowClear="false"
|
||||
url="${ctx}/sys/empUser/officeListData?isShowCode=true" callbackFuncName="switchOfficeSelectCallback"
|
||||
fieldNames="{'id':'officeCode','name':'fullName'}"/>
|
||||
</div>
|
||||
<script>
|
||||
$('#switchOffice').click(function(){
|
||||
$('#switchOfficeSelectButton').click();
|
||||
});
|
||||
function switchOfficeSelectCallback(id, act, index, layero, nodes){
|
||||
if (act == 'ok'){
|
||||
var officeCode = $('#switchOfficeSelectCode').val();
|
||||
if (officeCode != ''){
|
||||
js.ajaxSubmit("${ctx}/sys/empUser/switchOffice/"+officeCode, function(data){
|
||||
js.showMessage(data.message);
|
||||
js.window.location.reload();
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</li>
|
||||
<% } %>
|
||||
@@ -47,7 +47,7 @@
|
||||
<% }else{ %>
|
||||
<li class="mt10"></li>
|
||||
<% } %>
|
||||
<% if(postList.~size > 0){ %>
|
||||
<% if(toBoolean(postRolePermi!) && postList.~size > 0){ %>
|
||||
<li class="divider"></li>
|
||||
<% var postCode = @ObjectUtils.toStringIgnoreNull(session.postCode, ''); %>
|
||||
<li class="dropdown-header mb5">${text('选择岗位')}:<% if(isNotBlank(postCode)){ %>
|
||||
|
||||
Reference in New Issue
Block a user