Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-3
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
office
haoban-3
Commits
162e7f93
Commit
162e7f93
authored
Oct 12, 2021
by
crushh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update: 我的顾客全选
parent
fdc7fb6d
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
36 additions
and
18 deletions
+36
-18
myCustomerList.vue
src/views/apps/customerApp/myCustomerList.vue
+36
-18
No files found.
src/views/apps/customerApp/myCustomerList.vue
View file @
162e7f93
...
...
@@ -37,20 +37,20 @@
<el-button
type=
"primary"
@
click=
"toAssign"
>
批量分配会员
</el-button>
</div>
<div
class=
"table-body m-t-20"
>
<el-table
class=
"select-table"
ref=
"multipleTable"
v-loading=
"loading"
:data=
"tableData"
tooltip-effect=
"dark"
:style=
"
{ width: '100%' }" @selection-change="handleSelectionChange">
<el-table-column
type=
"selection"
width=
"45"
>
</el-table-column>
<
!--
<
el-table-column
width=
"25"
>
<template
#
header
>
<el-dropdown
style=
"line-height: 10px; padding: 0; margin-left: -15px; transform: translateY(4px); -webkit-transform: translateY(4px);"
@
command=
"handleCommand"
placement=
"bottom-start"
>
<el-table
class=
"select-table"
ref=
"multipleTable"
:key=
"tableRefresh"
v-loading=
"loading"
:data=
"tableData"
tooltip-effect=
"dark"
:style=
"
{ width: '100%' }" @selection-change="handleSelectionChange">
<el-table-column
type=
"selection"
width=
"45"
:class-name=
"selectRadio == 1 ? 'cell-disabled' : 'font-size-zero'"
>
</el-table-column>
<el-table-column
width=
"25"
>
<template
#
header
>
<el-dropdown
style=
"line-height: 10px; padding: 0; margin-left: -15px; transform: translateY(4px); -webkit-transform: translateY(4px);"
placement=
"bottom-start"
>
<span
class=
"el-dropdown-link"
><i
class=
"iconfont icongengduo"
></i>
</span>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-item
command=
"0"
><span
:style=
"
{ color: selectRadio == 0 ? '#2f54eb' : '#606266' }">选择当页
</span
></el-dropdown-item>
<el-dropdown-item
command=
"1"
><span
:style=
"
{ color: selectRadio == 1 ? '#2f54eb' : '#606266' }">选择全部
</span
></el-dropdown-item>
<el-dropdown-item
>
<el-checkbox
v-model=
"selectRadio"
:true-label=
"0"
:false-label=
"2"
@
change=
"handleCommand"
>
选择当页
</el-checkbox
></el-dropdown-item>
<el-dropdown-item
>
<el-checkbox
v-model=
"selectRadio"
:true-label=
"1"
:false-label=
"2"
@
change=
"handleCommand"
>
选择全部
</el-checkbox
></el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</
template
>
<
template
slot-scope=
"{ $index }"
><p
:key=
"$index"
></p></
template
>
</el-table-column>
-->
</el-table-column>
<el-table-column
label=
"会员姓名"
width=
"120"
show-overflow-tooltip
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
memberName
||
'--'
}}
</
template
>
</el-table-column>
...
...
@@ -85,7 +85,7 @@
</div>
</div>
</div>
<customer-assign
v-if=
"assignShow"
:brandId=
"brandId"
:clerkId=
"clerkId"
:searchParams=
"searchInput"
:editRow=
"editRow"
:chooseAll=
"selectRadio"
:departObj=
"storeObj"
:multipleData=
"multipleSelection"
@
closeText=
"closeText"
@
submitText=
"submitText"
></customer-assign>
<customer-assign
v-if=
"assignShow"
:brandId=
"brandId"
:clerkId=
"clerkId"
:searchParams=
"searchInput"
:editRow=
"editRow"
:chooseAll=
"selectRadio
== 2 ? 0 : selectRadio
"
:departObj=
"storeObj"
:multipleData=
"multipleSelection"
@
closeText=
"closeText"
@
submitText=
"submitText"
></customer-assign>
</div>
</template>
<
script
>
...
...
@@ -132,7 +132,7 @@ export default {
pageSize
:
20
,
total
:
0
,
loading
:
false
,
selectRadio
:
0
,
// 0:选择当页; 1:选择全部
selectRadio
:
2
,
// 0:选择当页; 1:选择全部; 2:都不选
multipleSelection
:
[],
assignShow
:
false
,
// 是否显示会员列表
...
...
@@ -140,7 +140,8 @@ export default {
storeObj
:
{},
gicDataCopy
:
[],
chainData
:
[],
navData
:
[]
navData
:
[],
tableRefresh
:
false
};
},
methods
:
{
...
...
@@ -227,7 +228,7 @@ export default {
closeText
()
{
const
that
=
this
;
that
.
assignShow
=
false
;
that
.
selectRadio
=
0
;
that
.
selectRadio
=
2
;
that
.
multipleSelection
=
[];
that
.
editRow
=
{};
that
.
$refs
.
multipleTable
.
clearSelection
();
...
...
@@ -237,7 +238,7 @@ export default {
*/
submitText
()
{
const
that
=
this
;
that
.
selectRadio
=
0
;
that
.
selectRadio
=
2
;
that
.
multipleSelection
=
[];
that
.
assignShow
=
false
;
that
.
$refs
.
multipleTable
.
clearSelection
();
...
...
@@ -280,7 +281,7 @@ export default {
getSelectData
(
obj
)
{
const
that
=
this
;
that
.
departObj
=
obj
;
that
.
selectRadio
=
0
;
that
.
selectRadio
=
2
;
that
.
showMember
=
false
;
that
.
storeObj
=
{};
// 判断是不是门店
...
...
@@ -296,12 +297,21 @@ export default {
*/
handleSelectionChange
(
val
)
{
this
.
multipleSelection
=
val
;
val
.
length
?
''
:
(
this
.
selectRadio
=
2
);
},
/**
* 显示选择本页/全部
*/
handleCommand
(
command
)
{
this
.
selectRadio
=
command
;
this
.
tableRefresh
=
!
this
.
tableRefresh
;
if
(
command
==
1
||
command
==
0
)
{
this
.
$nextTick
(()
=>
{
this
.
$refs
.
multipleTable
.
toggleAllSelection
();
});
}
else
if
(
command
==
2
)
{
this
.
$refs
.
multipleTable
.
clearSelection
();
}
},
/**
* 分配
...
...
@@ -318,7 +328,7 @@ export default {
}
that
.
editRow
=
row
;
// 如果选中一个分配,就要把批量已选的全部置空
that
.
selectRadio
=
0
;
that
.
selectRadio
=
2
;
that
.
multipleSelection
=
[];
that
.
$refs
.
multipleTable
.
clearSelection
();
that
.
assignShow
=
true
;
...
...
@@ -421,7 +431,7 @@ export default {
const
that
=
this
;
that
.
currentPage
=
1
;
that
.
pageSize
=
val
;
that
.
getTableList
();
that
.
getTableList
(
this
.
selectRadio
);
},
/**
...
...
@@ -431,7 +441,7 @@ export default {
handleCurrentChange
(
val
)
{
const
that
=
this
;
that
.
currentPage
=
val
;
that
.
getTableList
();
that
.
getTableList
(
this
.
selectRadio
);
},
/**
* 获取面包屑
...
...
@@ -487,7 +497,7 @@ export default {
/**
* 获取列表数据(只有门店才有)
*/
getTableList
()
{
getTableList
(
val
)
{
const
that
=
this
;
let
para
=
{
enterpriseId
:
that
.
brandId
,
...
...
@@ -502,8 +512,16 @@ export default {
.
then
(
res
=>
{
let
resData
=
res
.
data
;
if
(
resData
.
errorCode
==
1
)
{
this
.
tableRefresh
=
!
this
.
tableRefresh
;
that
.
tableData
=
resData
.
result
.
result
||
[];
that
.
total
=
resData
.
result
.
totalCount
;
if
(
val
==
1
)
{
this
.
$nextTick
(()
=>
{
this
.
$refs
.
multipleTable
.
toggleAllSelection
();
});
}
else
{
this
.
selectRadio
=
2
;
}
return
;
}
errMsg
.
errorMsg
(
resData
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment