Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
O
on-site-service-admin-view
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
external
on-site-service-admin-view
Commits
1e942d1e
Commit
1e942d1e
authored
Aug 01, 2022
by
shangtx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 按钮权限控制
parent
3c075144
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
34 additions
and
41 deletions
+34
-41
sysRole.js
src/api/system/sysRole.js
+0
-1
sysUserApi.js
src/api/system/sysUserApi.js
+0
-1
GlobalLayout.vue
src/components/page/GlobalLayout.vue
+5
-3
BannerEdit.vue
src/views/banner/BannerEdit.vue
+1
-1
BannerList.vue
src/views/banner/BannerList.vue
+2
-1
HomeNotice.vue
src/views/notice/HomeNotice.vue
+3
-2
NoticeDetail.vue
src/views/notice/NoticeDetail.vue
+5
-16
OrderDetail.vue
src/views/order/OrderDetail.vue
+6
-5
CategoryEdit.vue
src/views/serv/CategoryEdit.vue
+1
-1
ServiceList.vue
src/views/serv/ServiceList.vue
+1
-1
SubClassEdit.vue
src/views/serv/SubClassEdit.vue
+1
-1
ServiceWorkerEdit.vue
src/views/serviceWorker/ServiceWorkerEdit.vue
+1
-1
ServiceWorkerList.vue
src/views/serviceWorker/ServiceWorkerList.vue
+3
-2
SysRoleList.vue
src/views/system/role/SysRoleList.vue
+1
-1
SysUserList.vue
src/views/system/user/SysUserList.vue
+2
-2
UserList.vue
src/views/user/UserList.vue
+2
-2
No files found.
src/api/system/sysRole.js
View file @
1e942d1e
...
...
@@ -14,7 +14,6 @@ export function getPage(parameter) {
url
:
api
.
getPage
,
method
:
'post'
,
data
:
parameter
,
useFullLoading
:
true
})
}
...
...
src/api/system/sysUserApi.js
View file @
1e942d1e
...
...
@@ -18,7 +18,6 @@ export function getPage(parameter) {
url
:
api
.
getPage
,
method
:
'post'
,
data
:
parameter
,
useFullLoading
:
true
})
}
...
...
src/components/page/GlobalLayout.vue
View file @
1e942d1e
...
...
@@ -126,9 +126,10 @@ export default {
}
},
created
()
{
this
.
menus
=
this
.
filterHidenRouter
(
this
.
mainMenu
.
find
((
item
)
=>
item
.
path
===
'/'
).
children
)
const
root
=
this
.
mainMenu
.
find
((
item
)
=>
item
.
path
===
'/'
)
this
.
menus
=
this
.
filterHidenRouter
(
root
.
children
)
console
.
info
(
'main menu'
,
this
.
mainMenu
,
this
.
menus
)
console
.
info
(
'root'
,
root
)
},
methods
:
{
...
mapActions
([
'setSidebar'
]),
...
...
@@ -143,6 +144,7 @@ export default {
}
},
filterHidenRouter
(
routes
,
init
=
[])
{
for
(
let
i
=
0
;
i
<
routes
.
length
;
i
++
)
{
let
item
=
routes
[
i
]
if
(
item
.
hidden
==
true
)
{
...
...
src/views/banner/BannerEdit.vue
View file @
1e942d1e
...
...
@@ -43,7 +43,7 @@
<div
class=
"drawer-form-bottom-toolbar"
>
<a-button
:style=
"
{ marginRight: '8px' }" @click="close"> 取消
</a-button>
<a-button
type=
"primary"
@
click=
"submit"
>
保存
</a-button>
<a-button
type=
"primary"
v-if=
"hasPerm('SYS02102.EDIT')"
@
click=
"submit"
>
保存
</a-button>
</div>
</a-drawer>
</
template
>
...
...
src/views/banner/BannerList.vue
View file @
1e942d1e
...
...
@@ -7,12 +7,13 @@
un-checked-children=
"禁用"
:loading=
"loadingKeys.includes(record.id)"
@
click=
"enableChange(record, index)"
v-if=
"hasPerm('SYS02102.ENABLE')"
/>
</
template
>
<
template
#
action=
"{ record }"
>
<a-space>
<a
@
click=
"edit(record.id)"
>
编辑
</a>
<a
style=
"color: red"
@
click=
"deleteRow(record.id)"
>
删除
</a>
<a
style=
"color: red"
v-if=
"hasPerm('SYS02102.DELETE')"
@
click=
"deleteRow(record.id)"
>
删除
</a>
</a-space>
</
template
>
<
template
#
free
>
...
...
src/views/notice/HomeNotice.vue
View file @
1e942d1e
...
...
@@ -8,7 +8,7 @@
>
发布
</a>
<a
v-if=
"record.releaseStatus == 2"
@
click=
"revoke(record)"
>
撤销
</a>
<a
v-if=
"
hasPerm('SYS02103.PUBLISH') &&
record.releaseStatus == 2"
@
click=
"revoke(record)"
>
撤销
</a>
<a
@
click=
"detail(record.id)"
>
详情
</a>
<a
style=
"color: red"
...
...
@@ -78,7 +78,8 @@ export default {
toolbar
:
[
{
text
:
'新建'
,
handler
:
'add'
handler
:
'add'
,
bizCode
:
'SYS02103.EDIT'
}
]
}
...
...
src/views/notice/NoticeDetail.vue
View file @
1e942d1e
<
template
>
<a-drawer
:width=
"500"
:visible=
"visible"
title=
"
服务类别
"
@
close=
"close"
>
<a-drawer
:width=
"500"
:visible=
"visible"
title=
"
首页通知
"
@
close=
"close"
>
<a-form
:form=
"form"
layout=
"vertical"
>
<a-form-item
label=
"名称"
>
<a-input
v-decorator=
"[
'title',
{
rules: [{ required: true }]
}
]"
/>
<a-input
v-decorator=
"['title']"
/>
</a-form-item>
<a-form-item
label=
"内容(18字)"
>
<a-input
...
...
@@ -17,12 +10,8 @@
'content',
{
rules: [
{
required: true
},
{
max: 18
}
{ required: true, message: '请填写内容' },
{ max: 18, message: '为了显示效果内容应少于18字' }
]
}
]"
...
...
@@ -34,7 +23,7 @@
</a-form>
<div
class=
"drawer-form-bottom-toolbar"
>
<a-button
:style=
"
{ marginRight: '8px' }" @click="close"> 取消
</a-button>
<a-button
type=
"primary"
@
click=
"submit"
>
保存
</a-button>
<a-button
v-if=
"hasPerm('SYS02103.EDIT')"
type=
"primary"
@
click=
"submit"
>
保存
</a-button>
</div>
</a-drawer>
</
template
>
...
...
src/views/order/OrderDetail.vue
View file @
1e942d1e
...
...
@@ -81,6 +81,7 @@
@
click=
"sendPrice"
type=
"primary"
v-if=
"
hasPerm('SYS02201.SEND') &&
!past &&
(order.orderStatus == STATUS.RESERVE ||
order.orderStatus == STATUS.VALUATION)
...
...
@@ -90,32 +91,32 @@
</a-button>
<a-button
@
click=
"sendValuator"
v-if=
"!past && order.orderStatus == STATUS.RESERVE"
v-if=
"
hasPerm('SYS02201.VALUATOR') &&
!past && order.orderStatus == STATUS.RESERVE"
>
现场估价
</a-button>
<a-button
@
click=
"reSendValuator"
v-if=
"order.orderStatus == STATUS.VALUATION"
v-if=
"
hasPerm('SYS02201.VALUATOR') && !past &&
order.orderStatus == STATUS.VALUATION"
>
重新指派估价员
</a-button>
<a-button
v-if=
"!past && order.orderStatus == STATUS.PAY"
v-if=
"
hasPerm('SYS02201.WORKER') &&
!past && order.orderStatus == STATUS.PAY"
type=
"primary"
@
click=
"dispatch"
>
派单
</a-button>
<a-button
v-if=
"!past && order.orderStatus == STATUS.DISPATCH"
v-if=
"
hasPerm('SYS02201.WORKER') &&
!past && order.orderStatus == STATUS.DISPATCH"
@
click=
"reDispatch"
>
重新派单
</a-button>
<a-button
@
click=
"finish"
v-if=
"past && order.orderStatus == STATUS.DISPATCH"
v-if=
"
hasPerm('SYS02201.FINISH') &&
past && order.orderStatus == STATUS.DISPATCH"
type=
"primary"
>
完成
...
...
src/views/serv/CategoryEdit.vue
View file @
1e942d1e
...
...
@@ -12,7 +12,7 @@
</a-form-item>
</a-form>
<div
class=
"drawer-form-bottom-toolbar"
>
<a-button
:style=
"
{ marginRight: '8px' }" @click="close"> 取消
</a-button>
<a-button
:style=
"
{ marginRight: '8px' }"
v-if="hasPerm('SYS0210101.CATEGORY')"
@click="close"> 取消
</a-button>
<a-button
type=
"primary"
@
click=
"submit"
>
保存
</a-button>
</div>
</a-drawer>
...
...
src/views/serv/ServiceList.vue
View file @
1e942d1e
...
...
@@ -13,7 +13,7 @@
</template>
<
template
#
enable=
"{ record, index }"
>
<a-switch
v-if=
"record.type == 2"
v-if=
"
hasPerm('SYS0210101.ENABLE') &&
record.type == 2"
:checked=
"record.enabled"
checked-children=
"启用"
un-checked-children=
"禁用"
...
...
src/views/serv/SubClassEdit.vue
View file @
1e942d1e
...
...
@@ -52,7 +52,7 @@
</a-form>
<div
class=
"drawer-form-bottom-toolbar"
>
<a-button
:style=
"
{ marginRight: '8px' }" @click="close"> 取消
</a-button>
<a-button
type=
"primary"
@
click=
"submit"
>
保存
</a-button>
<a-button
type=
"primary"
v-if=
"hasPerm('SYS0210101.EDIT')"
@
click=
"submit"
>
保存
</a-button>
</div>
</a-drawer>
</
template
>
...
...
src/views/serviceWorker/ServiceWorkerEdit.vue
View file @
1e942d1e
...
...
@@ -15,7 +15,7 @@
</a-form>
<div
class=
"drawer-form-bottom-toolbar"
>
<a-button
:style=
"
{ marginRight: '8px' }" @click="close"> 取消
</a-button>
<a-button
type=
"primary"
@
click=
"submit"
>
保存
</a-button>
<a-button
type=
"primary"
@
click=
"submit"
v-if=
"hasPerm('SYS0200201.EDIT')"
>
保存
</a-button>
</div>
</a-drawer>
</
template
>
...
...
src/views/serviceWorker/ServiceWorkerList.vue
View file @
1e942d1e
...
...
@@ -3,7 +3,7 @@
<template
#
action=
"
{ record }">
<a-space>
<a
@
click=
"edit(record.id)"
>
编辑
</a>
<a
style=
"color: red"
@
click=
"deleteRow(record.id)"
>
删除
</a>
<a
v-if=
"hasPerm('SYS0200201.DELETE')"
style=
"color: red"
@
click=
"deleteRow(record.id)"
>
删除
</a>
</a-space>
</
template
>
<
template
#
free
>
...
...
@@ -53,7 +53,8 @@ export default {
toolbar
:
[
{
text
:
'新增'
,
handler
:
'add'
handler
:
'add'
,
bizCode
:
'SYS0200201.EDIT'
}
]
}
...
...
src/views/system/role/SysRoleList.vue
View file @
1e942d1e
...
...
@@ -78,7 +78,7 @@
checkedChildren=
"启用"
unCheckedChildren=
"禁用"
@
click=
"setStatus(record)"
:checked=
"record.
available
"
:checked=
"record.
isEnabled
"
:key=
"record.id"
/>
</span>
</a-table>
...
...
src/views/system/user/SysUserList.vue
View file @
1e942d1e
<
template
>
<table-template
:soul=
"this"
>
<template
#
tags=
"
{ record }">
<template
#
tags=
"
{ record
, index
}">
<a-switch
:disabled=
"record.id == 1"
checkedChildren=
"启用"
unCheckedChildren=
"禁用"
@
click=
"setStatus(record)"
:checked=
"
record.available
"
:checked=
"
dataSource[index].isEnabled
"
/>
</
template
>
<
template
#
action=
"{ record }"
>
...
...
src/views/user/UserList.vue
View file @
1e942d1e
...
...
@@ -6,8 +6,8 @@
<
template
#
userType=
"{ record }"
>
<span
>
{{
record
.
roleTypeValue
}}
<a-dropdown
:trigger=
"['click']"
>
<a><a-icon
type=
"edit"
@
click=
"(e) => e.preventDefault()"
/></a>
<a-dropdown
:trigger=
"['click']"
v-if=
"hasPerm"
>
<a><a-icon
type=
"edit"
@
click=
"(e) => e.preventDefault(
'SYS0200101.EDIT'
)"
/></a>
<a-menu
slot=
"overlay"
@
click=
"(
{ key }) => edit(key, record)">
<a-menu-item
key=
"0"
>
修改为 普通用户
</a-menu-item>
<a-menu-item
key=
"1"
>
修改为 客服
</a-menu-item>
...
...
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