cyl/dev
wangxia 2 years ago
parent c19f4323e7
commit 7d5c6a5a46

@ -1816,7 +1816,7 @@ export default {
}
> .ant-input {
width: 607px;
height: 36px;
height: 40px;
text-indent: 60px;
background: #fff;
border: 2px solid #ff4400;
@ -1839,7 +1839,7 @@ export default {
}
button {
width: 80px;
height: 36px;
height: 40px;
color: white;
background: #ff4400;
border-color: #ff4400;

@ -40,30 +40,8 @@
<div class="f12 c9 ml24 mb8">自定义角色8</div>
<a-menu :selectedKeys="selectedKeys" class="bgf" mode="inline" :class="'leftMenu'" style="overflow-y:scroll;height:calc(100%);overflow-x:hidden;">
<!-- <template v-for="(item, index) in groupList"> -->
<a-menu-item key="角色18人" class="fsa showdot" @click="selectGroup('角色18人')">
{{'角色18人'}}
<a-dropdown overlayClassName="groupdropdown" :trigger="['click']" placement="bottomRight">
<i class="iconfont icon-gengduo3 thedot f12" @click.stop></i>
<div class="groupdropdownbox backTable" slot="overlay">
<div>修改名称</div>
<div>删除</div>
<div>上移</div>
<div>下移</div>
</div>
</a-dropdown>
</a-menu-item>
<a-menu-item key="角色28人" class="fsa showdot" @click="selectGroup('角色28人')">
{{'角色28人'}}
<a-dropdown overlayClassName="groupdropdown" :trigger="['click']" placement="bottomRight">
<i class="iconfont icon-gengduo3 thedot f12" @click.stop></i>
<div class="groupdropdownbox backTable" slot="overlay">
<div>修改名称</div>
<div>删除</div>
<div>上移</div>
<div>下移</div>
</div>
</a-dropdown>
</a-menu-item>
<a-menu-item key="角色18人" class="fsa showdot" @click="selectGroup('角色18人')">{{'18'}}</a-menu-item>
<a-menu-item key="角色28人" class="fsa showdot" @click="selectGroup('角色28人')">{{'28'}}</a-menu-item>
<!-- </template> -->
</a-menu>
</div>
@ -81,8 +59,8 @@
<div class="groupdropdownbox backTable" slot="overlay">
<div @click="[addGroupShow = true,isEdit = true,recordId = item.id,groupName=item.teamName]">修改名称</div>
<div @click="delGroup(item)"></div>
<div>上移</div>
<div>下移</div>
<div @click="index != 0?moveList(index,'up'):null" :class="index == 0 ? 'unactive':''">上移</div>
<div @click="index + 1 < groupList.length?moveList(index,'down'):null" :class="index + 1 == groupList.length? 'unactive':''">下移</div>
</div>
</a-dropdown>
</a-menu-item>
@ -100,7 +78,7 @@
<div class="fsa pb14 bb1 mb24">
<div class="f16 fw500">{{modalTitle ? modalTitle : selectedKeys[0] == 'all' ? '全部成员19人':selectedKeys[0] + '8人' }}</div>
<!-- <button class="addGroup" @click="addGroupShow = true">添加部门</button> -->
<a-button class="addmemeber f14" v-if="modalTitle == ''" @click="showDetail('add')">
<a-button class="addmemeber f14" @click="showDetail('add')">
<i class="iconfont icon-fangda"></i> 添加成员
</a-button>
<!-- <button @click="changepage(1)"></button> -->
@ -909,6 +887,19 @@ export default {
that.$forceUpdate()
}, 10)
},
moveList(index, type) {
console.log(index)
if (type == 'up') {
let middle = this.groupList[index - 1]
this.groupList[index - 1] = this.groupList[index]
this.groupList[index] = middle
} else {
let middle = this.groupList[index + 1]
this.groupList[index + 1] = this.groupList[index]
this.groupList[index] = middle
}
this.$forceUpdate()
},
},
}
</script>
@ -1057,6 +1048,9 @@ export default {
i {
font-size: 12px;
}
&:hover {
background: #40a9ff;
}
}
.addRole {
position: absolute;
@ -1260,7 +1254,7 @@ export default {
text-align: left;
box-shadow: 0px 0px 10px rgba(128, 128, 128, 0.4);
padding: 8px 0;
> div {
> div:not(.unactive) {
height: 32px;
padding: 0 12px;
line-height: 32px;
@ -1271,5 +1265,13 @@ export default {
}
}
}
.unactive {
color: #cccccc;
height: 32px;
padding: 0 12px;
line-height: 32px;
cursor: no-drop;
}
}
</style>

@ -870,6 +870,9 @@ export default {
i {
font-size: 12px;
}
&:hover {
background: #40a9ff;
}
}
.addItem {
width: 468px;

@ -18,7 +18,7 @@
</div>
<a-menu :selectedKeys="[$route.name]" :openKeys.sync="openKeys" @click="handleClick" class mode="inline" style="overflow-y:scroll;height:calc(100vh - 49px);overflow-x:hidden">
<template v-for="(item, index) in roles">
<a-menu-item :key="item.name" v-if="item.path != '' && item.level < 3">
<!-- <a-menu-item :key="item.name" v-if="item.path != '' && item.level < 3">
<router-link :to="{ name: item.name }">
<i class="iconfont f12 mr8" :class="item.icon" />
<a-badge dot v-if="myStatisticRedDot && item.name == 'myStatistic'">
@ -26,7 +26,7 @@
</a-badge>
<span v-else class="nav-text" v-text="item.title"></span>
</router-link>
</a-menu-item>
</a-menu-item>-->
<a-sub-menu :key="item.name" v-if="item.path == ''">
<span slot="title">
<i class="iconfont f12 mr8" :class="item.icon" />
@ -292,7 +292,29 @@ export default {
* el 被新创建的 vm.el 替换并挂载到实例上去之后调用该钩子
* 如果 root 实例挂载了一个文档内元素 mounted 被调用时 vm.el 也在文档内
*/
mounted() {},
mounted() {
console.log(this.$route)
var _openKey = []
this.roles.forEach((item) => {
if (item.children) {
item.children.forEach((sItem) => {
if (sItem.name == this.$route.name) {
_openKey[0] = item.name
}
})
}
})
this.openKeys = _openKey
// if (this.$route.meta.menuName != '' && this.$route.meta.menuName != undefined && this.$route.meta.menuName != null) {
// var _openKey = []
// if (this.$route.meta.menuName != this.$route.name) {
// //
// _openKey.push(this.$route.meta.menuName, this.$route.name)
// } else {
// _openKey.push(this.$route.name)
// }
// }
},
//
methods: {
handleClick(e) {

Loading…
Cancel
Save