Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
Starter Web Vue
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
product
kim3-web-vue
Starter Web Vue
Commits
9ab11144
Commit
9ab11144
authored
Jul 22, 2021
by
shuiluo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 优化部分样式,角色管理国际化完成
parent
f8667214
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
25 deletions
+29
-25
src/local/system.js
src/local/system.js
+6
-0
src/pages/frame/components/header/LayoutTopHeader.vue
src/pages/frame/components/header/LayoutTopHeader.vue
+2
-6
src/pages/frame/layouts/AdminLayout.vue
src/pages/frame/layouts/AdminLayout.vue
+1
-1
src/pages/system/role/RoleManagement.vue
src/pages/system/role/RoleManagement.vue
+3
-3
src/pages/system/role/form.vue
src/pages/system/role/form.vue
+17
-15
No files found.
src/local/system.js
View file @
9ab11144
...
...
@@ -20,4 +20,10 @@ export default {
'
menu.menuUrlRequired
'
:
[
'
请输入Url
'
,
'
URL Is Required
'
],
'
menu.menuTypeNameZhRequired
'
:
[
'
请输入中文名称
'
,
'
@:menu.chineseName Is Required
'
],
'
menu.menuTypeNameEnRequired
'
:
[
'
请输入英文名称
'
,
'
@:menu.englishName Is Required
'
],
'
role.roleName
'
:
[
'
角色名称
'
,
'
Role Name
'
],
'
role.roleCode
'
:
[
'
角色编码
'
,
'
Role Code
'
],
'
role.roleRemark
'
:
[
'
角色说明
'
,
'
Remark
'
],
'
role.roleNameInput
'
:
[
'
请输入 @:role.roleName
'
,
'
Please Input @:role.roleName
'
],
'
role.roleCodeInput
'
:
[
'
请输入 @:role.roleCode
'
,
'
Please Input @:role.roleCode
'
],
'
role.menuPermissions
'
:
[
'
菜单权限
'
,
'
Menu Permissions
'
],
};
src/pages/frame/components/header/LayoutTopHeader.vue
View file @
9ab11144
...
...
@@ -100,12 +100,8 @@ export default {
}
}
.admin-header-wide {
padding-left: 24px;
&.head.fixed {
max-width: 1400px;
margin: auto;
padding-left: 0;
}
padding: 0 24px;
&.side {
padding-right: 12px;
}
...
...
src/pages/frame/layouts/AdminLayout.vue
View file @
9ab11144
...
...
@@ -50,7 +50,7 @@ import LayoutTopHeader from '../components/header/LayoutTopHeader.vue';
import
Drawer
from
'
@/components/tool/Drawer.vue
'
;
import
SideMenu
from
'
@/components/menu/SideMenu.vue
'
;
import
Setting
from
'
../components/setting/Setting.vue
'
;
import
{
mapState
,
mapMutations
,
mapGetters
}
from
'
vuex
'
;
import
{
mapState
,
mapMutations
}
from
'
vuex
'
;
import
{
convertListToTree
,
getUserInfo
}
from
'
@/utils
'
;
// const minHeight = window.innerHeight - 64 - 122
...
...
src/pages/system/role/RoleManagement.vue
View file @
9ab11144
...
...
@@ -3,9 +3,9 @@
<template
#drawer
="
drawer
"
>
<Form
v-bind=
"drawer"
/>
</
template
>
<a-table-column
title=
"角色名称
"
data-index=
"roleName"
/>
<a-table-column
title=
"角色编码
"
data-index=
"roleCode"
/>
<a-table-column
title=
"角色说明
"
data-index=
"remark"
/>
<a-table-column
:title=
"$t('role.roleName')
"
data-index=
"roleName"
/>
<a-table-column
:title=
"$t('role.roleCode')
"
data-index=
"roleCode"
/>
<a-table-column
:title=
"$t('role.roleRemark')
"
data-index=
"remark"
/>
</Table>
</template>
...
...
src/pages/system/role/form.vue
View file @
9ab11144
<
template
>
<Wraper
:hidden=
"hidden"
:refresh=
"refresh"
:onOk=
"sumit"
>
<a-form-model
layout=
"vertical"
:model=
"form"
:rules=
"rules"
ref=
"
DrawerF
orm"
>
<a-form-model-item
label=
"角色名称
"
>
<a-input
v-model=
"form.roleName"
:
disabled=
"isView
"
/>
<Wraper
:hidden=
"hidden"
:refresh=
"refresh"
:onOk=
"su
b
mit"
>
<a-form-model
layout=
"vertical"
:model=
"form"
:rules=
"rules"
ref=
"
f
orm"
>
<a-form-model-item
:label=
"$t('role.roleName')"
prop=
"roleName
"
>
<a-input
v-model=
"form.roleName"
:
placeholder=
"$t('input.placeholder')
"
/>
</a-form-model-item>
<a-form-model-item
label=
"角色编码
"
>
<a-input
v-model=
"form.roleCode"
:
disabled=
"isView
"
/>
<a-form-model-item
:label=
"$t('role.roleCode')"
prop=
"roleCode
"
>
<a-input
v-model=
"form.roleCode"
:
placeholder=
"$t('input.placeholder')
"
/>
</a-form-model-item>
<a-form-model-item
label=
"角色说明
"
prop=
"remark"
>
<a-input
v-model=
"form.remark"
:
disabled=
"isView
"
/>
<a-form-model-item
:label=
"$t('role.roleRemark')
"
prop=
"remark"
>
<a-input
v-model=
"form.remark"
:
placeholder=
"$t('input.placeholder')
"
/>
</a-form-model-item>
<a-form-model-item
label=
"菜单权限
"
>
<a-form-model-item
:label=
"$t('role.menuPermissions')
"
>
<MenuTree
v-model=
"checkedKeys"
:defaultCheckedKeys=
"defaultCheckedKeys"
showMenu
ref=
"menuTree"
:disabled=
"isView"
/>
</a-form-model-item>
</a-form-model>
...
...
@@ -27,16 +26,18 @@
<
script
>
import
MenuTree
from
'
@/components/menu_tree/index.vue
'
;
import
{
addRoleApi
,
getRoleApi
,
updateRoleApi
}
from
'
@/api
'
;
import
FormMixin
from
'
@/components/FormMixin
'
;
import
{
WraperMixins
}
from
'
@/components/table
'
;
export
default
{
mixins
:
[
FormMixin
,
WraperMixins
],
mixins
:
[
WraperMixins
],
components
:
{
MenuTree
},
data
()
{
return
{
form
:
{},
rules
:
{},
rules
:
{
roleName
:
[{
required
:
true
,
message
:
this
.
$t
(
'
role.roleNameInput
'
)
}],
roleCode
:
[{
required
:
true
,
message
:
this
.
$t
(
'
role.roleCodeInput
'
)
}],
},
checkedKeys
:
[],
defaultCheckedKeys
:
[],
};
...
...
@@ -49,11 +50,12 @@ export default {
mounted
()
{
if
(
this
.
type
)
{
this
.
getData
(
this
.
row
.
ro
w
Id
);
this
.
getData
(
this
.
row
.
ro
le
Id
);
}
},
methods
:
{
submit
()
{
async
submit
()
{
await
this
.
$refs
.
form
.
validate
();
const
query
=
{
...
this
.
form
,
authorityList
:
this
.
$refs
[
'
menuTree
'
].
get
().
map
((
i
)
=>
({
...
...
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