Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
ElectricitySheep
Project
Project
Details
Activity
Releases
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
黄媛媛
ElectricitySheep
Commits
6b2534f3
Commit
6b2534f3
authored
Oct 27, 2021
by
zhengke
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
4d9b654b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
45 additions
and
42 deletions
+45
-42
memberGroup.vue
src/components/UserMan/memberGroup.vue
+45
-42
No files found.
src/components/UserMan/memberGroup.vue
View file @
6b2534f3
...
...
@@ -8,9 +8,9 @@
</div>
<div
class=
"content"
>
<div
style=
"display: flex; align-items: center; flex-wrap: wrap"
>
<div
class=
"searchInput"
style=
"width:
15
0px"
>
<div
class=
"searchInput"
style=
"width:
21
0px"
>
<el-input
@
keyup
.
enter
.
native=
"(msg.pageIndex = 1), getList()"
@
clear=
"(msg.pageIndex = 1), getList()"
style=
"display: inline-block; width: 1
25
px; height: 30px"
placeholder=
"请输入昵称"
v-model=
"msg.GroupName"
style=
"display: inline-block; width: 1
80
px; height: 30px"
placeholder=
"请输入昵称"
v-model=
"msg.GroupName"
size=
"small"
clearable
>
</el-input>
<span
@
click=
"(msg.pageIndex = 1), getList()"
class=
"el-icon-search"
...
...
@@ -25,7 +25,7 @@
<el-table-column
prop=
"GroupName"
label=
"分组名称"
width=
"200"
>
</el-table-column>
<el-table-column
prop=
"LookGroupIds"
label=
"可查看分组"
width=
"300"
>
</el-table-column>
<el-table-column
prop=
"CreateDate"
width=
"200"
label=
"加入时间"
></el-table-column>
<el-table-column
prop=
"address"
label=
"操作"
fixed=
"right"
>
<el-table-column
prop=
"address"
label=
"操作"
fixed=
"right"
>
<template
slot-scope=
"scope"
>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"编辑"
placement=
"top"
>
<img
@
click=
"EditGroup(scope.row)"
style=
"width: 32px; height: 32px"
...
...
@@ -34,7 +34,7 @@
<el-tooltip
class=
"item"
effect=
"dark"
content=
"删除"
placement=
"top"
>
<img
@
click=
"DeleteGroup(scope.row)"
style=
"width: 32px; height: 32px"
src=
"../../assets/img/userman/
QRcode
.png"
alt=
""
/>
src=
"../../assets/img/userman/
del
.png"
alt=
""
/>
</el-tooltip>
</
template
>
</el-table-column>
...
...
@@ -44,14 +44,14 @@
</el-pagination>
</div>
<!-- 新增修改用户分组 -->
<el-dialog
title=
"修改星星数
"
:visible
.
sync=
"IsShowGroup"
width=
"600px"
:close-on-click-modal=
"false"
>
<el-dialog
:title=
"commonTitle
"
:visible
.
sync=
"IsShowGroup"
width=
"600px"
:close-on-click-modal=
"false"
>
<div>
<el-form
:model=
"addMsg"
ref=
"addMsg"
label-width=
"150px"
>
<el-form-item
label=
"分组名称"
>
<el-input
v-model=
"addMsg.GroupName"
placeholder=
"请输入分组名称"
></el-input>
<el-input
v-model=
"addMsg.GroupName"
class=
"w300"
placeholder=
"请输入分组名称"
></el-input>
</el-form-item>
<el-form-item
label=
"可查看分组"
>
<el-select
v-model=
"addMsg.GroupIdList"
>
<el-select
v-model=
"addMsg.GroupIdList"
multiple
class=
"w300"
>
<el-option
v-for=
"item in groupArray"
:key=
"item.GroupId"
:label=
"item.GroupName"
:value=
"item.GroupId"
>
</el-option>
</el-select>
...
...
@@ -60,7 +60,7 @@
</div>
<span
slot=
"footer"
class=
"dialog-footer"
>
<el-button
size=
"small"
@
click=
"IsShowGroup = false"
>
关 闭
</el-button>
<el-button
size=
"small"
type=
"primary"
@
click=
"SaveGroup()"
>
修 改
</el-button>
<el-button
size=
"small"
type=
"primary"
@
click=
"SaveGroup()"
>
确 定
</el-button>
</span>
</el-dialog>
</div>
...
...
@@ -78,6 +78,7 @@
loading
:
false
,
tableData
:
[],
total
:
0
,
commonTitle
:
'新增分组'
,
msg
:
{
pageIndex
:
1
,
pageSize
:
15
,
...
...
@@ -86,7 +87,6 @@
addMsg
:
{
GroupId
:
0
,
GroupName
:
""
,
//分组名称
LookGroupIds
:
""
,
GroupIdList
:
[],
IsSpecial
:
0
,
},
...
...
@@ -100,13 +100,30 @@
methods
:
{
//新增修改用户分组
EditGroup
(
obj
)
{
if
(
obj
)
{
this
.
commonTitle
=
'修改分组'
this
.
addMsg
.
GroupId
=
obj
.
GroupId
;
this
.
addMsg
.
GroupName
=
obj
.
GroupName
;
this
.
addMsg
.
GroupIdList
=
obj
.
GroupIdList
;
}
else
{
this
.
addMsg
.
GroupId
=
0
;
this
.
addMsg
.
GroupName
=
''
;
this
.
addMsg
.
GroupIdList
=
[];
this
.
addMsg
.
IsSpecial
=
0
;
this
.
commonTitle
=
'新增分组'
}
console
.
log
(
obj
,
'数据'
);
this
.
IsShowGroup
=
true
;
},
//保存用户分组信息
SaveGroup
()
{
this
.
apipost
(
"/api/User/SetMemberGroup"
,
this
.
addMsg
,
res
=>
{
console
.
log
(
res
);
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
Success
(
res
.
data
.
message
);
this
.
getList
();
this
.
IsShowGroup
=
false
;
}
});
},
//获取用户分组信息
...
...
@@ -120,11 +137,16 @@
},
//删除分组
DeleteGroup
(
item
)
{
this
.
apipost
(
"/api/User/DeleteMemberGroup"
,
{
GroupId
:
item
.
GroupId
},
res
=>
{
console
.
log
(
res
);
let
that
=
this
;
that
.
Confirm
(
"是否确定删除?"
,
function
()
{
that
.
apipost
(
"/api/User/DeleteMemberGroup"
,
{
GroupId
:
item
.
GroupId
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
){
that
.
Success
(
res
.
data
.
message
);
that
.
getList
();
}
});
});
},
getList
()
{
...
...
@@ -145,13 +167,10 @@
},
//获取分组下来列表
getgroupList
()
{
this
.
apipost
(
"/api/User/GetMemberGroupList"
,
{
},
res
=>
{
console
.
log
(
res
);
this
.
groupArray
=
res
.
data
.
data
;
this
.
apipost
(
"/api/User/GetMemberGroupList"
,
{},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
groupArray
=
res
.
data
.
data
;
}
});
}
},
...
...
@@ -162,26 +181,6 @@
</
script
>
<
style
>
.memberGroup
.remark_name
{
color
:
#888888
;
font-size
:
12px
;
margin-left
:
10px
;
float
:
right
;
}
.memberGroup
.app-image
{
background-position
:
center
center
;
width
:
50px
;
height
:
50px
;
border-radius
:
0%
;
float
:
left
;
margin-right
:
8px
;
}
.memberGroup
.blue
{
color
:
#409eff
;
}
.memberGroup
.content
.searchInput
{
border
:
1px
solid
#dcdfe6
;
border-radius
:
4px
;
...
...
@@ -212,4 +211,8 @@
box-sizing
:
border-box
;
}
.memberGroup
.w300
{
width
:
300px
!important
;
}
</
style
>
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