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
a4e5892d
Commit
a4e5892d
authored
May 19, 2020
by
zhengke
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加页面
parent
a688eda4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
364 additions
and
23 deletions
+364
-23
common.css
src/assets/css/common.css
+3
-0
EmployeesList.vue
src/components/StoreDesign/EmployeesList.vue
+33
-23
special.vue
src/components/StoreDesign/special.vue
+322
-0
index.js
src/router/index.js
+6
-0
No files found.
src/assets/css/common.css
View file @
a4e5892d
...
...
@@ -40,6 +40,9 @@
.w200
{
width
:
200px
!important
;
}
.w150
{
width
:
150px
!important
;
}
.el-icon-search
{
cursor
:
pointer
;
}
...
...
src/components/StoreDesign/EmployeesList.vue
View file @
a4e5892d
...
...
@@ -16,7 +16,7 @@
</el-alert>
<div
class=
"searchInput"
>
<el-input
style=
"display:inline-block;width:225px;height:30px"
placeholder=
"请输入用户昵称"
v-model=
"msg.
NavIcon
Name"
size=
"small"
clearable
@
keyup
.
enter
.
native=
"msg.pageIndex=1,getList()"
>
v-model=
"msg.
Emp
Name"
size=
"small"
clearable
@
keyup
.
enter
.
native=
"msg.pageIndex=1,getList()"
>
</el-input>
<span
class=
"el-icon-search"
style=
"color:#979dad;font-size:14px;position:relative;top:1px"
@
click=
"msg.pageIndex=1,getList()"
>
</span>
...
...
@@ -33,9 +33,15 @@
</el-table-column>
<el-table-column
label=
"操作"
width=
"260"
>
<template
slot-scope=
"scope"
>
<img
@
click=
"EditRole(scope.row)"
src=
"../../assets/img/userman/edit.png"
alt=
""
>
<img
@
click=
"upPwddialog=true"
style=
"margin:0 10px;"
src=
"../../assets/img/userman/change.png"
alt=
""
>
<img
@
click=
"RemmoveRole(scope.row)"
src=
"../../assets/img/userman/del.png"
alt=
""
>
<el-tooltip
slot=
"label"
class=
"item"
effect=
"dark"
content=
"编辑"
placement=
"top"
>
<img
@
click=
"EditRole(scope.row)"
src=
"../../assets/img/userman/edit.png"
alt=
""
>
</el-tooltip>
<el-tooltip
slot=
"label"
class=
"item"
effect=
"dark"
content=
"修改密码"
placement=
"top"
>
<img
@
click=
"upPwddialog=true"
style=
"margin:0 10px;"
src=
"../../assets/img/userman/change.png"
alt=
""
>
</el-tooltip>
<el-tooltip
slot=
"label"
class=
"item"
effect=
"dark"
content=
"删除"
placement=
"top"
>
<img
@
click=
"RemmoveRole(scope.row)"
src=
"../../assets/img/userman/del.png"
alt=
""
>
</el-tooltip>
</
template
>
</el-table-column>
</el-table>
...
...
@@ -55,17 +61,17 @@
<el-input
v-model=
"addMsg.EmpAccount"
class=
"w400"
size=
"small"
maxlength=
"20"
/>
</el-form-item>
<el-form-item
label=
"密码"
prop=
"EmpPwd"
>
<el-input
type=
"
text
"
v-model=
"addMsg.EmpPwd"
size=
"small"
class=
"w400"
/>
<el-input
type=
"
password
"
v-model=
"addMsg.EmpPwd"
size=
"small"
class=
"w400"
/>
</el-form-item>
<el-form-item
label=
"昵称"
prop=
"EmpName"
>
<el-input
type=
"text"
v-model=
"addMsg.EmpName"
size=
"small"
class=
"w400"
/>
</el-form-item>
<el-form-item
label=
"角色"
>
<el-checkbox
:indeterminate=
"isIndeterminate"
v-model=
"checkAll"
@
change=
"handleCheckAllChange"
>
全选
<el-checkbox
v-model=
"checkAll"
@
change=
"handleCheckAllChange"
>
全选
</el-checkbox>
<div
style=
"margin: 15px 0;"
></div>
<el-checkbox-group
v-model=
"check
edCities
"
@
change=
"handleCheckedCitiesChange"
>
<el-checkbox
v-for=
"item in RoleList"
:label=
"item.Role
Name"
:key=
"item.RoleId
"
>
{{
item
.
RoleName
}}
<el-checkbox-group
v-model=
"check
Arr
"
@
change=
"handleCheckedCitiesChange"
>
<el-checkbox
v-for=
"item in RoleList"
:label=
"item.Role
Id"
:key=
"item.RoleName
"
>
{{
item
.
RoleName
}}
</el-checkbox>
</el-checkbox-group>
</el-form-item>
...
...
@@ -78,7 +84,7 @@
<el-dialog
title=
"提示"
:visible
.
sync=
"upPwddialog"
width=
"400px"
>
<el-form
label-width=
"0"
>
<p
style=
"padding:10px 0"
>
请输入新密码
</p>
<el-input
type=
"
text
"
v-model=
"pwdMsg.password"
></el-input>
<el-input
type=
"
password
"
v-model=
"pwdMsg.password"
></el-input>
</el-form>
<span
slot=
"footer"
class=
"dialog-footer"
>
<el-button
size=
"small"
@
click=
"upPwddialog = false"
>
取 消
</el-button>
...
...
@@ -94,13 +100,14 @@
loading
:
false
,
//修改密码弹窗
upPwddialog
:
false
,
checkAll
:
false
,
isIndeterminate
:
tru
e
,
checkedCities
:
[],
//全选
checkAll
:
fals
e
,
checkArr
:
[],
//选中数组
dataList
:
[],
msg
:
{
pageIndex
:
1
,
pageSize
:
15
,
EmpName
:
''
},
pwdMsg
:
{
password
:
''
...
...
@@ -146,7 +153,6 @@
this
.
apipost
(
"/api/Employee/GetEmployeePageList"
,
this
.
msg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
dataList
=
res
.
data
.
data
.
pageData
;
console
.
log
(
"this.datalist"
,
this
.
dataList
);
this
.
total
=
res
.
data
.
data
.
count
;
}
else
{
this
.
Info
(
res
.
data
.
message
);
...
...
@@ -165,8 +171,7 @@
},
//保存
saveMsg
()
{
// var ckedKeys = this.$refs.tree.getCheckedKeys();
// this.addMsg.RoleAuth = ckedKeys.join(',');
this
.
addMsg
.
RoleAuth
=
this
.
checkArr
.
join
(
','
);
this
.
apipost
(
"/api/Employee/SetEmployee"
,
this
.
addMsg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
getList
();
...
...
@@ -191,12 +196,15 @@
EmpId
:
item
.
EmpId
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
checkArr
=
[];
this
.
addMsg
=
res
.
data
.
data
;
this
.
empIsShowAdd
=
false
;
let
newArr
=
this
.
addMsg
.
RoleAuth
.
split
(
','
);
setTimeout
(()
=>
{
this
.
$refs
.
tree
.
setCheckedKeys
(
newArr
);
},
10
)
if
(
this
.
addMsg
.
RoleAuth
!=
''
){
this
.
checkArr
=
newArr
.
map
(
function
(
data
){
return
+
data
;
})
}
}
else
{
this
.
Info
(
res
.
data
.
message
);
}
...
...
@@ -217,17 +225,19 @@
})
})
},
//全选
handleCheckAllChange
(
val
)
{
this
.
checkedCities
=
val
?
this
.
RoleList
:
[];
this
.
isIndeterminate
=
false
;
this
.
checkArr
=
[];
if
(
val
)
{
this
.
RoleList
.
forEach
(
x
=>
{
this
.
checkArr
.
push
(
x
.
RoleId
);
});
}
},
handleCheckedCitiesChange
(
value
)
{
let
checkedCount
=
value
.
length
;
this
.
checkAll
=
checkedCount
===
this
.
RoleList
.
length
;
this
.
isIndeterminate
=
checkedCount
>
0
&&
checkedCount
<
this
.
RoleList
.
length
;
},
//点击复制
copyCode
()
{
var
copycode
=
document
.
getElementById
(
"my_Link"
).
innerHTML
;
var
input
=
document
.
createElement
(
"input"
);
// 直接构建input
...
...
src/components/StoreDesign/special.vue
0 → 100644
View file @
a4e5892d
<
template
>
<div
class=
"special"
>
<template
v-if=
"speciaIsShowAdd"
>
<div
class=
"head-title"
>
专题
<el-button
@
click=
"speciaIsShowAdd=false,clearInfo()"
style=
"float:right;margin-top: -5px;"
size=
"small"
type=
"primary"
>
新增
</el-button>
</div>
<div
class=
"content"
>
<div>
<el-select
size=
"small"
class=
"w150"
>
<el-option
label=
"全部专题"
:value=
"0"
></el-option>
</el-select>
<div
class=
"searchInput"
>
<el-input
style=
"display:inline-block;width:225px;height:30px"
placeholder=
"请输入搜索内容"
v-model=
"msg.NavIconName"
size=
"small"
clearable
@
keyup
.
enter
.
native=
"msg.pageIndex=1,getList()"
>
</el-input>
<span
class=
"el-icon-search"
style=
"color:#979dad;font-size:14px;position:relative;top:1px"
@
click=
"msg.pageIndex=1,getList()"
>
</span>
</div>
</div>
<el-table
:data=
"dataList"
v-loading=
"loading"
border
style=
"width: 100%;margin:20px 0"
>
<el-table-column
prop=
"ID"
label=
"ID"
width=
"100"
>
</el-table-column>
<el-table-column
prop=
"fenlei"
label=
"分类"
width=
"120"
>
</el-table-column>
<el-table-column
prop=
"zhuanti"
label=
"专题"
>
</el-table-column>
<el-table-column
prop=
"bujufangshi"
label=
"布局方式"
width=
"120"
>
</el-table-column>
<el-table-column
prop=
"shifoujingxuan"
label=
"是否精选"
width=
"100"
>
</el-table-column>
<el-table-column
prop=
"sort"
label=
"排序"
width=
"200"
>
</el-table-column>
<el-table-column
label=
"操作"
width=
"150"
>
<template
slot-scope=
"scope"
>
<img
@
click=
"EditRole(scope.row)"
src=
"../../assets/img/userman/edit.png"
alt=
""
>
<img
@
click=
"upPwddialog=true"
style=
"margin:0 10px;"
src=
"../../assets/img/userman/change.png"
alt=
""
>
<img
@
click=
"RemmoveRole(scope.row)"
src=
"../../assets/img/userman/del.png"
alt=
""
>
</
template
>
</el-table-column>
</el-table>
<el-pagination
style=
"text-align:right"
background
@
current-change=
"handleCurrentChange"
:page-size=
"msg.pageSize"
layout=
"prev, pager, next"
:total=
"total"
>
</el-pagination>
</div>
</template>
<
template
v-else
>
<div
class=
"head-title"
>
<span
@
click=
"speciaIsShowAdd=true"
style=
"color:rgb(64, 158, 255);cursor:pointer;"
>
专题
</span><span
style=
"margin:0 9px;color:#C0C4CC"
>
/
</span><span>
专题编辑
</span>
</div>
<div
class=
"content contentTwo"
>
<el-tabs
v-model=
"activeName"
>
<el-tab-pane
label=
"基础设置"
name=
"first"
>
<el-form
label-width=
"10rem"
>
<el-form-item
label=
"标题"
>
<el-input
type=
"text"
maxlength=
"100"
size=
"small"
></el-input>
</el-form-item>
<el-form-item
label=
"专题列表布局方式"
>
<el-radio-group
v-model=
"addMsg.flexType"
>
<el-radio
:label=
"1"
>
小图模式
</el-radio>
<el-radio
:label=
"2"
>
大图模式
</el-radio>
<el-radio
:label=
"3"
>
多图模式
</el-radio>
</el-radio-group>
<div
class=
"flexTypeList"
>
小图模式建议封面图片大小:268×202;大图模式建议封面图片大小:702×350;多图模式建议封面图片大小:268×202,最多上传3张图片
</div>
</el-form-item>
<el-form-item
label=
"封面图"
>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"建议尺寸: 268 * 202"
placement=
"top"
>
<el-button
size=
"mini"
@
click=
"choicImg=true"
>
选择图片
</el-button>
</el-tooltip>
<div
class=
"customize-share-title"
>
<div
class=
"zk_pic_box"
flex=
"main:center cross:center"
:style=
"
{backgroundImage:'url(' + getIconLink(addMsg.coverImg) + ')'}">
<i
v-if=
"addMsg.coverImg==''"
class=
"el-icon-picture-outline"
></i>
</div>
</div>
</el-form-item>
<el-form-item>
<span
slot=
"label"
>
摘要
</span>
<el-tooltip
slot=
"label"
class=
"item"
effect=
"dark"
content=
"专题内容的简介,用于列表上显示"
placement=
"top"
>
<i
class=
"el-icon-info"
></i>
</el-tooltip>
<el-input
type=
"textarea"
size=
"small"
v-model=
"addMsg.Abstract"
:rows=
"2"
></el-input>
</el-form-item>
<el-form-item
label=
"自定义分享标题"
>
<el-input
type=
"text"
size=
"small"
v-model=
"addMsg.CustomTitle"
></el-input>
</el-form-item>
<el-form-item
label=
"自定义分享图片"
>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"建议尺寸:420 * 336"
placement=
"top"
>
<el-button
size=
"mini"
@
click=
"choicImg=true"
>
选择图片
</el-button>
</el-tooltip>
<div
class=
"customize-share-title"
>
<div
class=
"zk_pic_box"
flex=
"main:center cross:center"
:style=
"
{backgroundImage:'url(' + getIconLink(addMsg.customImg) + ')'}">
<i
v-if=
"addMsg.customImg==''"
class=
"el-icon-picture-outline"
></i>
</div>
</div>
</el-form-item>
<el-form-item
label=
"是否精选"
>
<el-switch
v-model=
"addMsg.isJingxuan"
:active-value=
"1"
:inactive-value=
"0"
></el-switch>
</el-form-item>
<el-form-item
label=
"分类"
>
<el-select
v-model=
"addMsg.fenlei"
size=
"small"
>
<!--
<el-option
v-for=
"item in options"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
>
</el-option>
-->
</el-select>
</el-form-item>
<el-form-item>
<span
slot=
"label"
>
虚拟阅读量
</span>
<el-tooltip
slot=
"label"
class=
"item"
effect=
"dark"
content=
"手机端显示的阅读量=实际阅读量+虚拟阅读量"
placement=
"top"
>
<i
class=
"el-icon-info"
></i>
</el-tooltip>
<el-input
type=
"text"
size=
"small"
v-model=
"addMsg.yuedu"
></el-input>
</el-form-item>
<el-form-item
label=
"排序"
>
<el-input
type=
"text"
size=
"small"
v-model=
"addMsg.sort"
></el-input>
</el-form-item>
</el-form>
</el-tab-pane>
<el-tab-pane
label=
"详情设置"
name=
"second"
>
</el-tab-pane>
</el-tabs>
</div>
<el-button
size=
"small"
style=
"margin-top:20px;padding:9px 25px;"
type=
"primary"
@
click=
"submitform('addMsg')"
>
保存
</el-button>
</
template
>
</div>
</template>
<
script
>
export
default
{
data
()
{
return
{
loading
:
false
,
activeName
:
'first'
,
dataList
:
[{
ID
:
699
,
fenlei
:
'李四'
,
zhuanti
:
'ck'
,
bujufangshi
:
'2020-10-25'
,
shifoujingxuan
:
'是'
,
sort
:
1
}],
msg
:
{
pageIndex
:
1
,
pageSize
:
15
,
},
pwdMsg
:{
password
:
''
},
total
:
0
,
speciaIsShowAdd
:
true
,
addMsg
:
{
title
:
''
,
//标题
flexType
:
1
,
//专题列表布局方式
coverImg
:
''
,
//封面图
Abstract
:
''
,
//摘要
CustomTitle
:
''
,
//自定义分享标题
customImg
:
''
,
//自定义分享图片
isJingxuan
:
0
,
//是否精选
fenlei
:
0
,
//分类
yuedu
:
''
,
//虚拟阅读量
sort
:
''
//排序
},
rules
:
{
RoleName
:
[{
required
:
true
,
message
:
"请输入用户名"
,
trigger
:
"blur"
}],
},
};
},
created
()
{
},
methods
:
{
handleCurrentChange
(
val
)
{
this
.
msg
.
pageIndex
=
val
;
this
.
getList
();
},
getList
()
{
this
.
apipost
(
"/api/Employee/GetRolePageList"
,
this
.
msg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
dataList
=
res
.
data
.
data
.
pageData
;
this
.
total
=
res
.
data
.
data
.
count
;
}
else
{
this
.
Info
(
res
.
data
.
message
);
}
})
},
submitform
(
addMsg
)
{
//提交创建、修改表单
this
.
$refs
[
addMsg
].
validate
(
valid
=>
{
if
(
valid
)
{
this
.
saveMsg
();
}
else
{
return
false
;
}
});
},
//保存
saveMsg
()
{
var
ckedKeys
=
this
.
$refs
.
tree
.
getCheckedKeys
();
this
.
addMsg
.
RoleAuth
=
ckedKeys
.
join
(
','
);
this
.
apipost
(
"/api/Employee/SetRole"
,
this
.
addMsg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
getList
();
this
.
clearInfo
();
this
.
speciaIsShowAdd
=
true
;
}
else
{
this
.
Info
(
res
.
data
.
message
);
}
})
},
//清空
clearInfo
()
{
this
.
addMsg
.
RoleId
=
0
;
this
.
addMsg
.
RoleName
=
''
;
this
.
addMsg
.
RoleIntro
=
''
;
this
.
addMsg
.
RoleAuth
=
''
;
},
//修改
EditRole
(
item
)
{
this
.
apipost
(
"/api/Employee/GetRole"
,
{
RoleId
:
item
.
RoleId
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
addMsg
=
res
.
data
.
data
;
this
.
speciaIsShowAdd
=
false
;
let
newArr
=
this
.
addMsg
.
RoleAuth
.
split
(
','
);
setTimeout
(()
=>
{
this
.
$refs
.
tree
.
setCheckedKeys
(
newArr
);
},
10
)
}
else
{
this
.
Info
(
res
.
data
.
message
);
}
})
},
//删除
RemmoveRole
(
item
)
{
var
that
=
this
;
that
.
Confirm
(
"是否要删除?"
,
function
()
{
that
.
apipost
(
"/api/Employee/RemoveRole"
,
{
RoleId
:
item
.
RoleId
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
that
.
getList
();
}
else
{
that
.
Info
(
res
.
data
.
message
);
}
})
})
},
},
mounted
()
{
//this.getList();
}
};
</
script
>
<
style
>
.special
.content
.searchInput
{
border
:
1px
solid
#DCDFE6
;
border-radius
:
4px
;
}
.special
.content
.searchInput
.el-input__inner
{
border
:
none
;
outline
:
none
;
height
:
30px
;
line-height
:
30px
;
}
.special
.content
.searchInput
{
line-height
:
normal
;
display
:
inline-table
;
width
:
100%
;
border-collapse
:
separate
;
border-spacing
:
0
;
width
:
250px
;
margin-right
:
20px
;
}
.special
.content
{
background
:
#fff
;
margin-top
:
10px
;
padding
:
20px
;
box-sizing
:
border-box
;
}
.special
.contentTwo
{
min-width
:
1000px
;
padding
:
20px
;
padding-right
:
50%
;
}
.special
.el-alert__content
{
display
:
flex
;
align-items
:
center
;
}
.special
.el-alert
{
padding
:
0
0
5px
5px
;
}
.special
.el-alert__title
{
margin-top
:
5px
;
}
.special
.flexTypeList
{
color
:
rgb
(
99
,
108
,
114
);
font-size
:
12px
;
margin-top
:
-0.5rem
;
}
</
style
>
src/router/index.js
View file @
a4e5892d
...
...
@@ -328,6 +328,12 @@ export default new Router({
name
:
'ProjectClassific'
,
component
:
resolve
=>
require
([
'@/components/StoreDesign/ProjectClassific'
],
resolve
),
},
//店铺管理 内容管理 专题
{
path
:
'/special'
,
name
:
'special'
,
component
:
resolve
=>
require
([
'@/components/StoreDesign/special'
],
resolve
),
},
//店铺管理 内容管理 视频管理
{
path
:
'/videoManage'
,
...
...
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