Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-custom
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 3a6fb9f8
authored
Feb 24, 2022
by
xuyl
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修复UI样式以及查看客户页面bug
1 parent
8c3b921e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
67 additions
and
67 deletions
src/views/tagsManage/viewCustomers.vue
src/views/tagsManage/viewCustomers.vue
View file @
3a6fb9f
...
@@ -39,7 +39,7 @@
...
@@ -39,7 +39,7 @@
</div>
</div>
<div
class=
"export"
@
click=
"handleExport"
>
导出
</div>
<div
class=
"export"
@
click=
"handleExport"
>
导出
</div>
</div>
</div>
<GLTable
@
setTableFinishFun=
"setTableFinishFun"
v-if=
"isReload"
ref=
"viewCustomers"
:
hasNum=
"true"
:getListApi=
"getListApi"
:beforeSearchFn=
"beforeSearchFn"
:noDataImg=
"url"
:pageConf=
"pageConf"
:searchForm=
"searchFormTable
"
:tableParams=
"tableParams"
>
<GLTable
@
setTableFinishFun=
"setTableFinishFun"
v-if=
"isReload"
ref=
"viewCustomers"
:
layout=
"layout"
:hasNum=
"true"
:tableData=
"tableData"
:tableTotal=
"tableTotal"
:noDataImg=
"url"
:pageConf=
"pageConf"
:searchForm=
"searchFormTable"
@
refreshTable=
"getCustomersListData
"
:tableParams=
"tableParams"
>
<span
slot=
"carVin"
slot-scope=
"scope"
>
<span
slot=
"carVin"
slot-scope=
"scope"
>
<span>
{{
myStandNo
(
scope
.
scope
.
carVin
)
}}
</span>
<span>
{{
myStandNo
(
scope
.
scope
.
carVin
)
}}
</span>
</span>
</span>
...
@@ -66,26 +66,24 @@
...
@@ -66,26 +66,24 @@
<img
src=
"@/assets/tagsManage/doc.png"
alt=
""
/>
<img
src=
"@/assets/tagsManage/doc.png"
alt=
""
/>
<span
class=
"iconLabelstext"
>
{{ labelGroupName }}
</span>
<span
class=
"iconLabelstext"
>
{{ labelGroupName }}
</span>
</div>
</div>
<div
class=
"label-panle"
:style=
"{ height: boxHeight + 'px' }"
v-if=
"items.length
>
0"
>
<div
class=
"label-panle"
:style=
"{ height: boxHeight + 'px' }"
v-if=
"items.length
>
0"
>
<
template
v-for=
"(item, index) in items"
>
<
template
v-for=
"(item, index) in items"
>
<!--
<div
class=
"iconLabelsName"
:class=
"
{ active: checkedTag.indexOf(index) > -1 }" v-if="item.isHidden" :key="index" @click="seletLabelActive(item.labelId, index, item.labelName)">
<!--
<div
class=
"iconLabelsName"
:class=
"
{ active: checkedTag.indexOf(index) > -1 }" v-if="item.isHidden" :key="index" @click="seletLabelActive(item.labelId, index, item.labelName)">
<img
src=
"@/assets/tagsManage/label.png"
alt=
""
/>
<img
src=
"@/assets/tagsManage/label.png"
alt=
""
/>
<span
:title=
"item.labelName.length > 10 ? 'item.labelName' : ''"
class=
"LabelsNameTxt"
>
{{
item
.
labelName
}}
</span>
<span
:title=
"item.labelName.length > 10 ? 'item.labelName' : ''"
class=
"LabelsNameTxt"
>
{{
item
.
labelName
}}
</span>
<img
v-if=
"checkedTag.indexOf(index) > -1"
class=
"labelChecked"
src=
"@/assets/tagsManage/checked.png"
alt=
""
/>
<img
v-if=
"checkedTag.indexOf(index) > -1"
class=
"labelChecked"
src=
"@/assets/tagsManage/checked.png"
alt=
""
/>
</div>
-->
</div>
-->
<div
class=
"iconLabelsName"
:class=
"
{
'active': checkedId==
item.labelId }" :key="index" @click="seletLabelActive(item.labelId, item)">
<div
class=
"iconLabelsName"
:class=
"
{
active: checkedId ==
item.labelId }" :key="index" @click="seletLabelActive(item.labelId, item)">
<img
src=
"@/assets/tagsManage/label.png"
alt=
""
/>
<img
src=
"@/assets/tagsManage/label.png"
alt=
""
/>
<span
:title=
"item.labelName.length > 10 ? 'item.labelName' : ''"
class=
"LabelsNameTxt"
>
{{
item
.
labelName
}}
</span>
<span
:title=
"item.labelName.length > 10 ? 'item.labelName' : ''"
class=
"LabelsNameTxt"
>
{{
item
.
labelName
}}
</span>
<img
v-if=
"checkedId
==
item.labelId"
class=
"labelChecked"
src=
"@/assets/tagsManage/checked.png"
alt=
""
/>
<img
v-if=
"checkedId
==
item.labelId"
class=
"labelChecked"
src=
"@/assets/tagsManage/checked.png"
alt=
""
/>
</div>
</div>
</
template
>
</
template
>
</div>
</div>
<div
class=
"noRelatedLabel"
v-else
>
<div
class=
"noRelatedLabel"
v-else
>
<img
src=
"@/assets/tagsManage/noData.png"
alt=
""
>
<img
src=
"@/assets/tagsManage/noData.png"
alt=
""
/>
<div>
无相关{{searchLabel}}数据
</div>
<div>
暂无 {{ searchLabel }} 相关内容
</div>
</div>
</div>
</div>
</div>
<span
slot=
"footer"
class=
"dialog-footer"
>
<span
slot=
"footer"
class=
"dialog-footer"
>
<el-button
@
click=
"resetSearch"
>
重置
</el-button>
<el-button
@
click=
"resetSearch"
>
重置
</el-button>
...
@@ -104,12 +102,10 @@ export default {
...
@@ -104,12 +102,10 @@ export default {
data
()
{
data
()
{
return
{
return
{
checkedId
:
''
,
checkedId
:
''
,
allListParams
:{
allListParams
:
{
pageSize
:
10
,
tagLists
:
[]
pageNum
:
1
,
tagLists
:[]
},
},
allLabeltags
:[],
allLabeltags
:
[],
customerListsNum
:
0
,
customerListsNum
:
0
,
checkedTag
:
[],
checkedTag
:
[],
isActive
:
-
1
,
isActive
:
-
1
,
...
@@ -122,7 +118,7 @@ export default {
...
@@ -122,7 +118,7 @@ export default {
dialogVisible
:
false
,
dialogVisible
:
false
,
labelType
:
''
,
labelType
:
''
,
isReload
:
true
,
isReload
:
true
,
noRelatedLabel
:
false
,
noRelatedLabel
:
false
,
url
:
url
,
url
:
url
,
sloading
:
false
,
sloading
:
false
,
searchForm
:
{},
searchForm
:
{},
...
@@ -210,13 +206,15 @@ export default {
...
@@ -210,13 +206,15 @@ export default {
placeholder
:
''
placeholder
:
''
}
}
],
],
layout
:
'sizes, prev, pager, next, jumper, ->, total'
,
tableTotal
:
0
,
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'pageNum'
,
totalCount
:
'count'
},
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'pageNum'
,
totalCount
:
'count'
},
tableParams
:
{
tableParams
:
{
btnId
:
new
Date
().
getTime
()
+
parseInt
(
Math
.
random
()
*
1000
),
btnId
:
new
Date
().
getTime
()
+
parseInt
(
Math
.
random
()
*
1000
),
listName
:
'data'
,
listName
:
'data'
,
tableColumns
:
[
tableColumns
:
[
{
{
label
:
'客户
名称
'
,
label
:
'客户
姓名
'
,
prop
:
'customerName'
prop
:
'customerName'
// width: 160
// width: 160
},
},
...
@@ -252,7 +250,7 @@ export default {
...
@@ -252,7 +250,7 @@ export default {
// width: 160
// width: 160
},
},
{
{
label
:
'是否加
入
企微'
,
label
:
'是否加企微'
,
prop
:
'isJoin'
,
prop
:
'isJoin'
,
addHtml
:
'isJoin'
addHtml
:
'isJoin'
// width: 160
// width: 160
...
@@ -264,7 +262,7 @@ export default {
...
@@ -264,7 +262,7 @@ export default {
}
}
]
]
},
},
getListApi
:
getCustomersList
,
tableData
:
[]
,
merchantModel
:
1
,
merchantModel
:
1
,
flushTime
:
false
flushTime
:
false
// items
// items
...
@@ -285,7 +283,6 @@ export default {
...
@@ -285,7 +283,6 @@ export default {
this
.
$message
.
closeAll
()
this
.
$message
.
closeAll
()
},
},
mounted
()
{
mounted
()
{
// this.wxTips()
let
clientHeight
=
document
.
documentElement
.
clientHeight
let
clientHeight
=
document
.
documentElement
.
clientHeight
this
.
boxHeight
=
clientHeight
-
250
this
.
boxHeight
=
clientHeight
-
250
},
},
...
@@ -303,10 +300,10 @@ export default {
...
@@ -303,10 +300,10 @@ export default {
break
break
}
}
},
},
searchLabel
(
val
){
searchLabel
(
val
)
{
if
(
this
.
allLabeltags
.
indexOf
(
val
)
==
-
1
)
{
if
(
this
.
allLabeltags
.
indexOf
(
val
)
==
-
1
)
{
this
.
noRelatedLabel
=
true
this
.
noRelatedLabel
=
true
}
else
{
}
else
{
this
.
noRelatedLabel
=
false
this
.
noRelatedLabel
=
false
}
}
}
}
...
@@ -325,7 +322,21 @@ export default {
...
@@ -325,7 +322,21 @@ export default {
}
}
return
carVin
.
substring
(
carVin
.
length
-
6
)
return
carVin
.
substring
(
carVin
.
length
-
6
)
},
},
getCustomersListData
()
{
const
params
=
{
...
JSON
.
parse
(
JSON
.
stringify
(
this
.
allListParams
)),
pageSize
:
this
.
$refs
.
viewCustomers
.
page
.
pageSize
,
pageNum
:
this
.
$refs
.
viewCustomers
.
page
.
pageNum
}
console
.
log
(
this
.
$apis
.
tagsManage
)
getCustomersList
(
params
).
then
(
res
=>
{
this
.
tableData
=
res
.
data
this
.
tableTotal
=
res
.
count
if
(
res
.
data
.
length
==
0
)
{
this
.
$refs
.
viewCustomers
.
setTableHeightFun
()
}
})
},
//获取标签组
//获取标签组
getLabelList
()
{
getLabelList
()
{
let
params
=
{
let
params
=
{
...
@@ -334,28 +345,36 @@ export default {
...
@@ -334,28 +345,36 @@ export default {
'labelByGroupIdReq.labelGroupType'
:
this
.
groupType
'labelByGroupIdReq.labelGroupType'
:
this
.
groupType
}
}
getLabelList
(
params
).
then
(
res
=>
{
getLabelList
(
params
).
then
(
res
=>
{
console
.
log
(
this
.
$common
)
this
.
labelGroupName
=
res
.
groupName
this
.
labelGroupName
=
res
.
groupName
this
.
labelList
=
res
.
labelNameIds
this
.
labelList
=
res
.
labelNameIds
this
.
labelType
=
res
.
groupType
this
.
labelType
=
res
.
groupType
this
.
groupId
=
res
.
groupId
this
.
groupId
=
res
.
groupId
this
.
labelList
.
forEach
(
item
=>
{
this
.
labelList
.
forEach
(
item
=>
{
// this.allLabeltags.push(item.labelName)
// this.allLabeltags.push(item.labelName)
item
.
isHidden
=
true
item
.
isHidden
=
true
let
res
=
this
.
getListParams
(
item
.
labelId
,
item
.
labelName
)
let
res
=
this
.
getListParams
(
item
.
labelId
,
item
.
labelName
)
this
.
allListParams
.
tagLists
.
push
(
res
)
this
.
allListParams
.
tagLists
.
push
(
res
)
})
})
this
.
startParams
=
this
.
$common
.
utils
.
deepClone
(
this
.
allListParams
)
this
.
searchForm
=
{
this
.
searchForm
=
{
...
this
.
allListParams
...
this
.
allListParams
}
}
this
.
searchTable
()
this
.
getCustomersListData
()
})
})
},
},
seletLabelActive
(
id
,
arr
)
{
seletLabelActive
(
id
,
arr
)
{
if
(
id
==
this
.
checkedId
)
{
this
.
checkedId
=
''
this
.
tagLists
=
[]
this
.
allListParams
=
this
.
startParams
return
}
this
.
checkedId
=
id
this
.
checkedId
=
id
const
labelId
=
arr
.
labelId
const
labelId
=
arr
.
labelId
const
labelName
=
arr
.
labelName
const
labelName
=
arr
.
labelName
let
res
=
this
.
getListParams
(
labelId
,
labelName
)
let
res
=
this
.
getListParams
(
labelId
,
labelName
)
if
(
this
.
tagLists
.
length
>
0
)
{
if
(
this
.
tagLists
.
length
>
0
)
{
// this.checkedTag.shift()
// this.checkedTag.shift()
this
.
tagLists
.
shift
()
this
.
tagLists
.
shift
()
}
}
...
@@ -363,10 +382,10 @@ export default {
...
@@ -363,10 +382,10 @@ export default {
},
},
// 首次加载页面显示所有客户数据
// 首次加载页面显示所有客户数据
getAllClientList
(
allListParams
)
{
getAllClientList
(
allListParams
)
{
this
.
searchForm
=
{
this
.
searchForm
=
{
...
allListParams
...
allListParams
}
}
this
.
searchTable
()
this
.
getCustomersListData
()
this
.
tagLists
=
[]
this
.
tagLists
=
[]
},
},
// 根据标签获取客户列表
// 根据标签获取客户列表
...
@@ -375,12 +394,10 @@ export default {
...
@@ -375,12 +394,10 @@ export default {
if
(
!
this
.
tagLists
.
length
)
{
if
(
!
this
.
tagLists
.
length
)
{
this
.
getAllClientList
(
this
.
allListParams
)
this
.
getAllClientList
(
this
.
allListParams
)
}
else
{
}
else
{
this
.
searchForm
=
{
this
.
allListParams
=
{
pageSize
:
10
,
pageNum
:
1
,
tagLists
:
this
.
tagLists
tagLists
:
this
.
tagLists
}
}
this
.
searchTable
()
this
.
getCustomersListData
()
}
}
},
},
getListParams
(
id
,
name
)
{
getListParams
(
id
,
name
)
{
...
@@ -398,6 +415,7 @@ export default {
...
@@ -398,6 +415,7 @@ export default {
this
.
searchLabel
=
''
this
.
searchLabel
=
''
this
.
checkedId
=
''
this
.
checkedId
=
''
this
.
tagLists
=
[]
this
.
tagLists
=
[]
this
.
allListParams
=
this
.
startParams
},
},
filterNode
(
val
,
labelData
)
{
filterNode
(
val
,
labelData
)
{
if
(
!
val
)
return
true
if
(
!
val
)
return
true
...
@@ -419,28 +437,7 @@ export default {
...
@@ -419,28 +437,7 @@ export default {
goBack
()
{
goBack
()
{
this
.
$router
.
go
(
-
1
)
this
.
$router
.
go
(
-
1
)
},
},
// wxTips() {
// const menu = JSON.parse(sessionStorage['SCRM_BASE_MENULIST'])
// menu.forEach(item => {
// if (!item.children) {
// return
// }
// item.children.forEach(itm => {
// if (itm.path == '/enterpriseWechat/index') {
// getStatus({}).then(res => {
// if (res.status != 'SUCCESS') {
// const h = this.$createElement
// this.$message({
// showClose: true,
// duration: 0,
// message: h('p', null, [h('span', null, '此功能需完成【企业微信授权】后方可使用! '), h('span', { on: { click: this.jumpWx }, style: { marginRight: '150px', cursor: 'pointer', color: '#5850ff' } }, ['企业微信授权 ', h('i', { class: 'el-icon-d-arrow-right' }, '')])])
// })
// }
// })
// }
// })
// })
// },
setTableHeightEvent
()
{
setTableHeightEvent
()
{
this
.
$refs
.
viewCustomers
.
setTableHeightFun
()
this
.
$refs
.
viewCustomers
.
setTableHeightFun
()
},
},
...
@@ -477,16 +474,16 @@ export default {
...
@@ -477,16 +474,16 @@ export default {
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
'@/styles/variables.scss'
;
@import
'@/styles/variables.scss'
;
@import
'@/styles/resetelement.scss'
;
@import
'@/styles/resetelement.scss'
;
.noRelatedLabel
{
.noRelatedLabel
{
margin-top
:
59px
;
margin-top
:
59px
;
text-align
:
center
;
text-align
:
center
;
div
{
div
{
margin-top
:
12px
;
margin-top
:
12px
;
font-size
:
14px
;
font-size
:
14px
;
font-family
:
PingFangSC-Regular
,
PingFang
SC
;
font-family
:
PingFangSC-Regular
,
PingFang
SC
;
font-weight
:
400
;
font-weight
:
400
;
color
:
#000000
;
color
:
#000000
;
}
}
}
}
.active
{
.active
{
border
:
1px
solid
rgba
(
88
,
80
,
255
,
1
)
!important
;
border
:
1px
solid
rgba
(
88
,
80
,
255
,
1
)
!important
;
...
@@ -532,6 +529,7 @@ color: #000000;
...
@@ -532,6 +529,7 @@ color: #000000;
height
:
100%
;
height
:
100%
;
margin-right
:
0px
;
margin-right
:
0px
;
margin-top
:
0
!important
;
margin-top
:
0
!important
;
//
margin-bottom
:
0
!important
;
position
:
relative
;
position
:
relative
;
}
}
::v-deep
.el-dialog__wrapper
{
::v-deep
.el-dialog__wrapper
{
...
@@ -653,6 +651,7 @@ color: #000000;
...
@@ -653,6 +651,7 @@ color: #000000;
}
}
}
}
.labelDialog
{
.labelDialog
{
overflow
:
hidden
;
.labelCombination
{
.labelCombination
{
.iconLabels
{
.iconLabels
{
margin-top
:
20px
;
margin-top
:
20px
;
...
@@ -670,6 +669,7 @@ color: #000000;
...
@@ -670,6 +669,7 @@ color: #000000;
}
}
}
}
.label-panle
{
.label-panle
{
min-width
:
300px
;
height
:
calc
(
100%
-
200px
);
height
:
calc
(
100%
-
200px
);
overflow-y
:
auto
;
overflow-y
:
auto
;
}
}
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment