Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
Y
ybf
Project
Project
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
xulili
ybf
Commits
c0c3ef7d
Commit
c0c3ef7d
authored
Feb 04, 2020
by
Z
Browse files
Options
Browse Files
Download
Plain Diff
Z: Dot: next bar and keywords.
parents
9ba083f2
c966cd7d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
190 additions
and
99 deletions
+190
-99
mail.js
ybf_admin/src/api/in/mail.js
+26
-1
move.vue
ybf_admin/src/pages/in/contact/components/move.vue
+14
-2
mail.vue
ybf_admin/src/pages/in/contact/mail.vue
+150
-96
No files found.
ybf_admin/src/api/in/mail.js
View file @
c0c3ef7d
...
@@ -17,8 +17,15 @@ export function getNoGroupMember(data) {
...
@@ -17,8 +17,15 @@ export function getNoGroupMember(data) {
method
:
'get'
,
method
:
'get'
,
params
:
data
params
:
data
})
})
}
// 获取柜组用户
export
function
getGroupById
(
data
)
{
return
request
({
url
:
'/admin/auth/addressbook/getUserByShopId'
,
method
:
'get'
,
params
:
data
})
}
}
// 根据部门id获取人员
// 根据部门id获取人员
export
function
getMemberById
(
data
)
{
export
function
getMemberById
(
data
)
{
return
request
({
return
request
({
...
@@ -65,4 +72,22 @@ export function getHistoryList(data) {
...
@@ -65,4 +72,22 @@ export function getHistoryList(data) {
method
:
'put'
,
method
:
'put'
,
data
data
})
})
}
// 移动人员
export
function
moveMember
(
data
)
{
return
request
({
url
:
'admin/auth/addressbook/updateStallClerkByUserId'
,
method
:
'put'
,
params
:
data
})
}
// 模糊查询
export
function
search
(
data
)
{
return
request
({
url
:
'/admin/auth/addressbook/getUserByKeyWords'
,
method
:
'get'
,
params
:
data
})
}
}
\ No newline at end of file
ybf_admin/src/pages/in/contact/components/move.vue
View file @
c0c3ef7d
...
@@ -77,7 +77,7 @@
...
@@ -77,7 +77,7 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
getGroup
}
from
"@/api/in/mail"
;
import
{
getGroup
,
moveMember
}
from
"@/api/in/mail"
;
import
{
log
}
from
"util"
;
import
{
log
}
from
"util"
;
export
default
{
export
default
{
...
@@ -85,6 +85,10 @@ export default {
...
@@ -85,6 +85,10 @@ export default {
moveDialog
:
{
moveDialog
:
{
type
:
Boolean
,
type
:
Boolean
,
default
:
false
default
:
false
},
idList
:
{
type
:
Array
,
default
:
()
=>
[]
}
}
},
},
data
()
{
data
()
{
...
@@ -105,7 +109,15 @@ export default {
...
@@ -105,7 +109,15 @@ export default {
this
.
$emit
(
"handleCancel"
);
this
.
$emit
(
"handleCancel"
);
},
},
handleFinish
()
{
handleFinish
()
{
this
.
$emit
(
"handleFinish"
,
false
);
let
groupId
=
this
.
$refs
.
tree
.
getCheckedKeys
()[
0
]
let
data
=
{
stallIds
:
groupId
,
userIds
:
this
.
idList
+
','
}
moveMember
(
data
).
then
(
res
=>
{
this
.
$emit
(
"handleFinish"
,
false
);
})
},
},
/* handleChange() {},
/* handleChange() {},
handleClose() {
handleClose() {
...
...
ybf_admin/src/pages/in/contact/mail.vue
View file @
c0c3ef7d
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<span
class=
"number"
>
{{
allNumber
}}
</span>
<span
class=
"number"
>
{{
allNumber
}}
</span>
</div>
</div>
</div>
</div>
<div
class=
"ty"
style=
"margin:15px 0;"
@
click=
"getNoGroupMember(1)"
>
<div
class=
"ty"
style=
"margin:15px 0;"
@
click=
"getNoGroupMember(1
,1
)"
>
<div>
<div>
<span>
未分组
</span>
<span>
未分组
</span>
<span
class=
"number"
>
{{
wNumber
}}
</span>
<span
class=
"number"
>
{{
wNumber
}}
</span>
...
@@ -18,29 +18,26 @@
...
@@ -18,29 +18,26 @@
</div>
</div>
<div
class=
"tree"
>
<div
class=
"tree"
>
<el-tree
<el-tree
class=
"trees"
:props=
"orgData"
:props=
"orgData"
:data=
"data1"
:data=
"data1"
node-key=
"id"
node-key=
"id"
:expand-on-click-node=
"false"
expand-on-click-node
@
node-click=
"handleTreeClick"
@
node-click=
"handleTreeClick"
>
>
<span
class=
"custom-tree-node"
slot-scope=
"
{ node, data }">
<!--
<span
class=
"custom-tree-node"
slot-scope=
"
{ node, data }">
<span>
{{
node
.
label
}}
</span>
<span>
{{
node
.
label
}}
</span>
</span>
</span>
-->
</el-tree>
</el-tree>
</div>
</div>
</div>
</div>
</div>
</div>
<!--
<div
class=
"end"
>
<span
class=
"add-r"
@
click=
"addStore"
>
添加门店/专柜
</span>
</div>
-->
</div>
</div>
<div
class=
"right"
>
<div
class=
"right"
>
<!--
<div
class=
"right-c"
>
-->
<div
class=
"top"
><span>
{{
title
}}
</span>
共(
<span>
{{
totalNumber
}}
</span>
)人
</div>
<div
class=
"top"
>
三号柜组(共18人)
</div>
<div
class=
"searchs"
>
<div
class=
"searchs"
>
<div
class=
"buttons"
>
<div
class=
"buttons"
>
<el-button
class=
"button buttondark"
size=
"small"
@
click=
"handleMove"
<el-button
class=
"button buttondark"
size=
"small"
@
click=
"handleMove"
:disabled=
"idList.length>0? false:true "
>
移动
</el-button
>
移动
</el-button
>
>
<el-button
<el-button
...
@@ -60,12 +57,12 @@
...
@@ -60,12 +57,12 @@
<el-form-item
label=
"关键词"
>
<el-form-item
label=
"关键词"
>
<el-input
<el-input
size=
"small"
size=
"small"
v-model=
"formData.keys"
v-model=
"formData.key
word
s"
style=
"width:160px"
style=
"width:160px"
placeholder=
"请输入关键词"
placeholder=
"请输入关键词"
/>
/>
</el-form-item>
</el-form-item>
<el-button
class=
"button buttondark"
size=
"small"
>
搜索
</el-button>
<el-button
class=
"button buttondark"
size=
"small"
@
click=
"handleSearch"
>
搜索
</el-button>
</el-form>
</el-form>
</div>
</div>
<el-table
<el-table
...
@@ -76,6 +73,7 @@
...
@@ -76,6 +73,7 @@
tooltip-effect=
"dark"
tooltip-effect=
"dark"
style=
"width: 100%"
style=
"width: 100%"
height=
"calc(100% - 140px)"
height=
"calc(100% - 140px)"
@
selection-change=
"handleMemberChange"
>
>
<el-table-column
type=
"selection"
width=
"60"
></el-table-column>
<el-table-column
type=
"selection"
width=
"60"
></el-table-column>
<el-table-column
<el-table-column
...
@@ -93,11 +91,7 @@
...
@@ -93,11 +91,7 @@
label=
"部门"
label=
"部门"
align=
"center"
align=
"center"
></el-table-column>
></el-table-column>
<el-table-column
<el-table-column
prop=
"role"
label=
"角色"
align=
"center"
>
prop=
"role"
label=
"角色"
align=
"center"
>
<template
slot-scope=
"scope"
>
<template
slot-scope=
"scope"
>
<span
v-if=
"scope.row.managerType == 0"
>
店员
</span>
<span
v-if=
"scope.row.managerType == 0"
>
店员
</span>
<span
v-if=
"scope.row.managerType == 1"
>
店长
</span>
<span
v-if=
"scope.row.managerType == 1"
>
店长
</span>
...
@@ -132,23 +126,22 @@
...
@@ -132,23 +126,22 @@
:moveDialog=
"moveDialogShow"
:moveDialog=
"moveDialogShow"
@
handleCancel=
"moveDialogShow = false"
@
handleCancel=
"moveDialogShow = false"
@
handleFinish=
"removeFinish"
@
handleFinish=
"removeFinish"
:idList=
"idList"
></move-dialog>
></move-dialog>
<!-- <el-dialog title="提示" v-if="nameDialog" :visible.sync="nameDialog" width="30%" >
<div class="changeName">
<span style="margin:0 10px;">门店名称:</span>
<el-input v-model="store.name" placeholder="请输入名称"></el-input>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="nameDialog = false">取 消</el-button>
<el-button type="primary" @click="handleNameChange">确 定</el-button>
</span>
</el-dialog> -->
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
MoveDialog
from
"./components/move"
;
import
MoveDialog
from
"./components/move"
;
import
{
getOrgTree
,
getAllMemberList
,
getNoGroupMember
,
getMemberById
,
storeNameChange
}
from
"@/api/in/mail"
;
import
{
getOrgTree
,
getAllMemberList
,
getNoGroupMember
,
getMemberById
,
storeNameChange
,
getGroupById
,
search
}
from
"@/api/in/mail"
;
export
default
{
export
default
{
data
()
{
data
()
{
const
data1
=
[
const
data1
=
[
...
@@ -535,8 +528,7 @@ export default {
...
@@ -535,8 +528,7 @@ export default {
tableData
:
[],
tableData
:
[],
isShow
:
false
,
isShow
:
false
,
formData
:
{
formData
:
{
status
:
""
,
keywords
:
""
keys
:
""
},
},
statusList
:
[],
statusList
:
[],
page
:
{
page
:
{
...
@@ -556,62 +548,68 @@ export default {
...
@@ -556,62 +548,68 @@ export default {
id
:
"id"
id
:
"id"
},
},
type
:
1
,
type
:
1
,
store
:
{
idList
:
[],
name
:
""
,
storeId
:
""
,
id
:
""
groupId
:
""
,
}
counterId
:
0
,
title
:
"全部"
,
totalNumber
:
""
};
};
},
},
components
:
{
components
:
{
MoveDialog
,
MoveDialog
},
},
created
()
{
created
()
{
this
.
getOrgTree
();
this
.
getOrgTree
();
this
.
getMailList
(
1
);
this
.
getMailList
(
1
,
1
);
},
},
methods
:
{
methods
:
{
getOrgTree
()
{
getOrgTree
()
{
getOrgTree
().
then
(
res
=>
{
getOrgTree
().
then
(
res
=>
{
let
data
=
res
.
data
let
data
=
res
.
data
;
this
.
allNumber
=
data
[
'用户的总数'
]
this
.
allNumber
=
data
[
"用户的总数"
];
this
.
wNumber
=
data
[
'未分组用户的总数'
]
this
.
wNumber
=
data
[
"未分组用户的总数"
];
this
.
data1
=
data
[
'所有的柜组'
]
this
.
data1
=
data
[
"所有的柜组"
];
})
})
;
},
},
handleTreeClick
(
data
)
{
handleTreeClick
(
data
)
{
/* switch (data.id) {
this
.
title
=
data
.
name
case 1:
if
(
data
.
shopId
)
{
this.list1.main4 = this.list1.main6;
this
.
groupId
=
data
.
shopId
break;
case 5:
this.list1.main4 = this.list1.main1;
break;
case 6:
this.list1.main4 = this.list1.main2;
break;
case 7:
this.list1.main4 = this.list1.main3;
break;
case 2:
this.list1.main4 = this.list1.main5;
break;
default:
this.list1.main4 = this.list1.main3;
break;
} */
let
params
=
{
pageNum
:
1
,
stallId
:
data
.
id
}
}
getMemberById
(
params
).
then
(
res
=>
{
if
(
data
.
type
){
this
.
tableData
=
res
.
data
.
list
this
.
storeId
=
data
.
id
this
.
page
.
total
=
Number
(
res
.
data
.
total
)
this
.
getStoreMember
(
1
,
1
)
})
}
else
{
this
.
groupId
=
data
.
id
this
.
getGroupMember
(
1
,
1
)
}
},
getGroupMember
(
page
,
ctPage
)
{
this
.
page
.
currentPage
=
ctPage
this
.
type
=
3
let
params
=
{
pageNum
:
page
,
shopId
:
this
.
groupId
};
getGroupById
(
params
).
then
(
res
=>
{
this
.
tableData
=
res
.
data
.
list
;
this
.
page
.
total
=
this
.
totalNumber
=
Number
(
res
.
data
.
total
);
});
},
},
listPick
()
{},
getStoreMember
(
page
,
ctPage
)
{
testButtonClick
()
{},
this
.
page
.
currentPage
=
ctPage
pagesSizeChange
()
{},
this
.
type
=
4
pagesNowPageChange
()
{},
let
params
=
{
pageNum
:
page
,
stallId
:
this
.
storeId
};
getMemberById
(
params
).
then
(
res
=>
{
this
.
tableData
=
res
.
data
.
list
;
this
.
page
.
total
=
Number
(
res
.
data
.
total
);
this
.
totalNumber
=
Number
(
res
.
data
.
total
)
});
},
synchronismMember
()
{
synchronismMember
()
{
this
.
isShow
=
true
;
this
.
isShow
=
true
;
this
.
$emit
(
"isShow"
,
this
.
isShow
);
this
.
$emit
(
"isShow"
,
this
.
isShow
);
...
@@ -620,46 +618,102 @@ export default {
...
@@ -620,46 +618,102 @@ export default {
this
.
moveDialogShow
=
true
;
this
.
moveDialogShow
=
true
;
},
},
removeFinish
()
{
removeFinish
()
{
this
.
moveDialogShow
=
false
;
this
.
handleTypeChange
(
1
,
1
)
this
.
moveDialogShow
=
false
;
},
},
handleCurrentChange
(
val
)
{
handleCurrentChange
(
val
)
{
console
.
log
(
val
,
"每页"
);
let
ctPage
=
val
this
.
handleTypeChange
(
val
,
ctPage
)
},
},
/* addCounter() {
getMailList
(
page
,
ctPage
)
{
this.$refs.addCounter.counterDialog = true;
this
.
title
=
"全部"
}, */
this
.
type
=
1
;
/* addStore() {
this
.
page
.
currentPage
=
ctPage
this.$refs.addStore.addStoreDialog = true;
}, */
getMailList
(
page
)
{
this
.
type
=
1
let
params
=
{
let
params
=
{
pageNum
:
page
pageNum
:
page
}
}
;
getAllMemberList
(
params
).
then
(
res
=>
{
getAllMemberList
(
params
).
then
(
res
=>
{
console
.
log
(
res
,
"res"
);
console
.
log
(
res
,
"res"
);
this
.
tableData
=
res
.
data
.
list
this
.
tableData
=
res
.
data
.
list
;
this
.
page
.
total
=
Number
(
res
.
data
.
total
)
this
.
page
.
total
=
this
.
totalNumber
=
this
.
allNumber
=
Number
(
res
.
data
.
total
);
})
})
;
},
},
handleShopowner
()
{},
handleShopowner
()
{},
getNoGroupMember
(
page
)
{
getNoGroupMember
(
page
,
ctPage
)
{
this
.
type
=
2
this
.
title
=
"未分组"
this
.
page
.
currentPage
=
ctPage
this
.
type
=
2
;
let
params
=
{
let
params
=
{
pageNum
:
page
pageNum
:
page
}
}
;
getNoGroupMember
(
params
).
then
(
res
=>
{
getNoGroupMember
(
params
).
then
(
res
=>
{
this
.
tableData
=
res
.
data
.
list
this
.
tableData
=
res
.
data
.
list
;
this
.
page
.
total
=
Number
(
res
.
data
.
total
)
this
.
page
.
total
=
this
.
totalNumber
=
this
.
wNumber
=
Number
(
res
.
data
.
total
);
})
});
},
handleMemberChange
(
val
)
{
console
.
log
(
val
,
"val"
);
let
ids
=
[]
val
.
map
(
function
(
item
)
{
ids
.
push
(
item
.
id
)
});
this
.
idList
=
ids
console
.
log
(
this
.
idList
,
","
);
},
handleTypeChange
(
val
,
ctPage
)
{
if
(
this
.
type
==
1
)
{
this
.
getMailList
(
val
,
ctPage
)
}
else
if
(
this
.
type
==
2
)
{
this
.
getNoGroupMember
(
val
,
ctPage
)
}
else
if
(
this
.
type
==
3
)
{
this
.
getGroupMember
(
val
,
ctPage
)
}
else
{
this
.
getStoreMember
(
val
,
ctPage
)
}
},
handleSearch
()
{
switch
(
this
.
type
)
{
case
1
:
this
.
counterId
=
0
;
break
case
2
:
this
.
counterId
=
-
1
;
break
case
3
:
this
.
counterId
=
this
.
groupId
;
break
}
let
params
=
{
keyWords
:
this
.
formData
.
keywords
,
stallId
:
this
.
counterId
}
search
(
params
).
then
(
res
=>
{
console
.
log
(
res
,
"搜索结果"
);
let
array
=
[]
array
.
push
(
res
.
data
.
userInfo
)
console
.
log
(
array
,
"???"
);
this
.
tableData
=
array
;
this
.
page
.
total
=
1
})
}
}
}
}
};
};
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.trees
>>>
.el-tree-node__content
{
padding
:
10px
;
border-bottom
:
1px
solid
#fff
;
}
.trees
>>>
.el-tree-node__children
.el-tree-node__content
{
background-color
:
#dadad97
a
;
}
.btn
>>>
.el-button
+
.el-button
{
.btn
>>>
.el-button
+
.el-button
{
margin-left
:
5px
;
margin-left
:
5px
;
}
}
...
...
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