Commit 17fc8121 by 杨明

fixed

1 parent 709ae132
.el-select {
width: 100%;
width: 100%;
}
.el-pagination {
display: flex;
margin-top: 18px;
display: flex;
margin-top: 18px;
}
.el-button--small {
min-width: 68px;
}
.glsx-table .el-pagination.is-background .el-pager li:not(.disabled).active {
background-color: $btnBlue;
color: #fff;
background-color: $btnBlue;
color: #fff;
}
.el-dialog__header .el-dialog__title {
height: 28px;
font-size: 20px;
font-weight: bold;
color: #333333;
line-height: 28px;
height: 28px;
font-size: 20px;
font-weight: bold;
color: #333333;
line-height: 28px;
}
/deep/ .el-input__inner:focus {
border-color: $btnBlue !important;
border-color: $btnBlue !important;
}
/deep/.el-range-editor.is-active,
.el-range-editor.is-active:hover {
border-color: $btnBlue;
border-color: $btnBlue;
}
.el-message-box {
width: 547px;
height: 310px;
box-sizing: border-box;
padding-bottom: 10px;
width: 547px;
height: 310px;
box-sizing: border-box;
padding-bottom: 10px;
}
.el-message-box__title {
padding-left: 0;
margin-bottom: 0;
font-size: 20px;
line-height: 1;
color: #333;
padding-left: 0;
margin-bottom: 0;
font-size: 20px;
line-height: 1;
color: #333;
}
.el-message-box__title {
display: block !important;
display: block !important;
}
.el-message-box__headerbtn {
display: block !important;
color: #666666;
display: block !important;
color: #666666;
}
.el-message-box__header {
position: relative;
padding: 15px 20px;
border-bottom: 1px solid #e6e6e6;
position: relative;
padding: 15px 20px;
border-bottom: 1px solid #e6e6e6;
}
.el-message-box__content {
text-align: center;
padding: 60px 0;
text-align: center;
padding: 60px 0;
}
.el-icon-warning {
display: block !important;
font-size: 33px !important;
color: #5850ff !important;
position: relative;
left: 50%;
transform: translateX(-50%);
margin-bottom: 12px;
display: block !important;
font-size: 33px !important;
color: #5850ff !important;
position: relative;
left: 50%;
transform: translateX(-50%);
margin-bottom: 12px;
}
// .el-icon-error {
// display: block !important;
// font-size: 33px !important;
// position: relative;
// left: 50%;
// transform: translateX(-50%);
// margin-bottom: 12px;
// }
.el-message-box__status.el-icon-error {
display: block !important;
font-size: 33px !important;
position: relative;
left: 50%;
transform: translateX(-50%);
margin-bottom: 12px;
}
.el-tooltip__popper.is-dark {
background: #666666 !important;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.06) !important;
font-size: 12px;
font-weight: 400;
color: #ffffff;
line-height: 18px;
background: #666666 !important;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.06) !important;
font-size: 12px;
font-weight: 400;
color: #ffffff;
line-height: 18px;
}
.el-tooltip__popper[x-placement^="top"] .popper__arrow {
border-top-color: #666666 !important;
border-top-color: #666666 !important;
}
.el-tooltip__popper[x-placement^="top"] .popper__arrow:after {
border-top-color: #666666 !important;
}
\ No newline at end of file
border-top-color: #666666 !important;
}
<template>
<div>
<el-dialog :title="dialogTitle" :visible.sync="groupVisible" width="50%" :before-close="handleClose">
<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="grouping-ruleForm">
<el-form-item label="分群名称" prop="crowdGroupName" size="small">
<el-input v-model="ruleForm.crowdGroupName" placeholder="请输入分群名称" maxlength="30"></el-input>
</el-form-item>
......@@ -51,7 +51,7 @@
</div>
</template>
</div>
<div class="el-form-item__error" v-show="crowdStatus"></div>
<div class="el-form-item__error" v-show="crowdStatus">请选择人群</div>
<!-- <div class="group-tree-panel" :style="{ height: heightBox + 'px' }">
<el-tree @node-expand="nodeExpand" accordion :data="crowdUnitList" :props="defaultProps" show-checkbox></el-tree>
</div> -->
......@@ -155,6 +155,7 @@ export default {
group.isIndeterminateGroup = false
this.rightSelectNum = 0
})
this.autoExpand()
},
//推送左侧
handleLeft() {
......@@ -172,13 +173,14 @@ export default {
group.isIndeterminateGroup_right = false
this.leftSelectNum = 0
})
this.autoExpand()
},
handleSelect() {
this.$refs['ruleForm'].validate(valid => {
if (valid) {
let crowdArr = []
this.crowdUnitList.forEach(crowd => {
Object.assign(crowdArr, crowd.selectGroup)
crowdArr = [...crowdArr, ...crowd.selectGroup]
})
if (crowdArr.length == 0) {
this.crowdStatus = true
......@@ -277,6 +279,17 @@ export default {
this.crowdUnitList[1].selectGroup.push(item)
}
})
this.autoExpand()
},
autoExpand() {
if (this.crowdUnitList[0].selectGroup.length == 0 && this.crowdUnitList[1].selectGroup.length > 0) {
this.crowdUnitList[0].checked_right = false
this.crowdUnitList[1].checked_right = true
}
if (this.crowdUnitList[0].selectGroup.length > 0 && this.crowdUnitList[1].selectGroup.length == 0) {
this.crowdUnitList[0].checked = false
this.crowdUnitList[1].checked = true
}
},
//左侧展开
handleExpand(index) {
......
......@@ -4,8 +4,8 @@
<div class="scrm-sub-client-container">
<div class="pageContent">
<GLCombiForm :formObj="searchForm" :formData="clientGroupFormList" @handleOk="searchTable" @handleRest="resetTable"></GLCombiForm>
<GLTable @setTableFinishFun="setTableFinishFun" v-if="isReload" ref="clientGroupManage" :hasNum="true" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :noDataImg="url" :pageConf="pageConf" :searchForm="searchFormTable" :tableParams="tableParams" :expand-row-keys="expandArr">
<GLCombiForm :rowNumber="1" :formObj="searchForm" :formData="clientGroupFormList" @handleOk="searchTable" @handleRest="resetTable"></GLCombiForm>
<GLTable @setTableFinishFun="setTableFinishFun" v-if="isReload" ref="clientGroupManage" :hasNum="false" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :noDataImg="url" :pageConf="pageConf" :searchForm="searchFormTable" :tableParams="tableParams" :expand-row-keys="expandArr">
<div slot="groupInfo" slot-scope="scope" v-if="scope.scope.crowdUnitList && scope.scope.crowdUnitList.length">
<div class="table-tr">
<div class="tabel-th">人群名称</div>
......@@ -37,6 +37,11 @@
</div>
</div>
<add-or-edit ref="addOrEditForm"></add-or-edit>
<GLFooter>
<el-button type="primary" @click="goback">
返回
</el-button>
</GLFooter>
</div>
</template>
......@@ -170,6 +175,9 @@ export default {
handleAdd(row) {
this.$refs.addOrEditForm.init(row)
},
goback() {
this.$router.push(`/clientDataOverview/index`)
},
//删除
handleDelete(scope) {
this.$confirm('是否确认将此分群删除?', '删除', {
......@@ -200,9 +208,8 @@ export default {
.catch(() => {})
},
againConfirm() {
this.$confirm('此分群已被招揽活动任务调用,不支持删除', '提示', {
this.$alert('此分群已被招揽活动任务调用,不支持删除', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'error'
})
.then(() => {})
......@@ -295,6 +302,8 @@ export default {
border-top: 1px solid #e8e8ea;
&:first-child {
background: #f4f6fc;
color: #333333;
font-weight: 700;
}
div {
height: 40px;
......@@ -304,6 +313,7 @@ export default {
}
}
.scrm-sub-client-container {
margin-bottom: 60px;
.pageTitle {
position: relative;
margin-bottom: 20px;
......
......@@ -94,9 +94,39 @@ export default {
this.$emit('getCheckItem', this.$refs.tagTree)
})
},
filterNode(value, data) {
filterNode(value, data, node) {
if (!value) return true
return data.name.indexOf(value) !== -1
// let val = value.toLowerCase()
// this.$nextTick(() => {
// this.setTreeHeight()
// })
// return this.chooseNode(val, data, node) // 调用过滤二层方法
},
chooseNode(value, data, node) {
if (data.name.indexOf(value) !== -1) {
return true
}
const level = node.level
// 如果传入的节点本身就是一级节点就不用校验了
if (level === 1) {
return false
}
// 先取当前节点的父节点
let parentData = node.parent
// 遍历当前节点的父节点
let index = 0
while (index < level - 1) {
// 如果匹配到直接返回,此处name值是中文字符,enName是英文字符。判断匹配中英文过滤
if (parentData.data.name.indexOf(value) !== -1) {
return true
}
// 否则的话再往上一层做匹配
parentData = parentData.parent
index++
}
// 没匹配到返回false
return false
},
//勾选
checkChange() {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!