Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
ant-design-pro-vue
Overview
Overview
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
tianzhuanghu
ant-design-pro-vue
Commits
90675607
Commit
90675607
authored
Nov 24, 2018
by
sendya
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: display problem in mobile mode
parent
2ddf9e9d
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
24 additions
and
11 deletions
+24
-11
App.vue
src/App.vue
+3
-3
GlobalLayout.vue
src/components/page/GlobalLayout.vue
+14
-1
router.config.js
src/config/router.config.js
+1
-1
TableInnerEditList.vue
src/views/list/TableInnerEditList.vue
+3
-3
UserList.vue
src/views/list/UserList.vue
+2
-2
Login.vue
src/views/user/Login.vue
+1
-1
No files found.
src/App.vue
View file @
90675607
...
@@ -21,16 +21,16 @@
...
@@ -21,16 +21,16 @@
// tablet
// tablet
if
(
deviceType
===
0
)
{
if
(
deviceType
===
0
)
{
that
.
$store
.
commit
(
'TOGGLE_DEVICE'
,
'tablet'
)
that
.
$store
.
commit
(
'TOGGLE_DEVICE'
,
'tablet'
)
that
.
$store
.
commit
(
'CLOSE_SIDEBAR'
,
false
)
that
.
$store
.
dispatch
(
'setSidebar'
,
false
)
}
}
// mobile
// mobile
else
if
(
deviceType
===
1
)
{
else
if
(
deviceType
===
1
)
{
that
.
$store
.
commit
(
'TOGGLE_DEVICE'
,
'mobile'
)
that
.
$store
.
commit
(
'TOGGLE_DEVICE'
,
'mobile'
)
that
.
$store
.
commit
(
'CLOSE_SIDEBAR'
,
false
)
that
.
$store
.
dispatch
(
'setSidebar'
,
false
)
}
}
else
{
else
{
that
.
$store
.
commit
(
'TOGGLE_DEVICE'
,
'desktop'
)
that
.
$store
.
commit
(
'TOGGLE_DEVICE'
,
'desktop'
)
that
.
$store
.
commit
(
'SET_SIDEBAR_TYPE'
,
true
)
that
.
$store
.
dispatch
(
'setSidebar'
,
true
)
}
}
})
})
...
...
src/components/page/GlobalLayout.vue
View file @
90675607
...
@@ -102,6 +102,12 @@
...
@@ -102,6 +102,12 @@
device
:
state
=>
state
.
app
.
device
,
device
:
state
=>
state
.
app
.
device
,
})
})
},
},
watch
:
{
sidebarOpened
(
val
)
{
console
.
log
(
'watch'
,
val
)
this
.
collapsed
=
!
val
},
},
created
()
{
created
()
{
this
.
menus
=
this
.
mainMenu
.
find
((
item
)
=>
item
.
path
===
'/'
).
children
this
.
menus
=
this
.
mainMenu
.
find
((
item
)
=>
item
.
path
===
'/'
).
children
},
},
...
@@ -144,10 +150,17 @@
...
@@ -144,10 +150,17 @@
}
}
}
}
/**
* ant-table-wrapper
* 覆盖的表格手机模式样式,如果想修改在手机上表格最低宽度,可以在这里改动
*/
.ant-table-wrapper
{
.ant-table-wrapper
{
.ant-table-
body
{
.ant-table-
content
{
overflow-y
:
auto
;
overflow-y
:
auto
;
}
}
.ant-table-body
{
min-width
:
800px
;
}
}
}
.sidemenu
{
.sidemenu
{
.ant-header-fixedHeader
{
.ant-header-fixedHeader
{
...
...
src/config/router.config.js
View file @
90675607
...
@@ -13,7 +13,7 @@ export const asyncRouterMap = [
...
@@ -13,7 +13,7 @@ export const asyncRouterMap = [
{
{
path
:
'/dashboard'
,
path
:
'/dashboard'
,
name
:
'dashboard'
,
name
:
'dashboard'
,
redirect
:
'/dashboard/
analysis
'
,
redirect
:
'/dashboard/
workplace
'
,
component
:
RouteView
,
component
:
RouteView
,
meta
:
{
title
:
'仪表盘'
,
icon
:
'dashboard'
,
permission
:
[
'dashboard'
]
},
meta
:
{
title
:
'仪表盘'
,
icon
:
'dashboard'
,
permission
:
[
'dashboard'
]
},
children
:
[
children
:
[
...
...
src/views/list/TableInnerEditList.vue
View file @
90675607
...
@@ -153,21 +153,21 @@
...
@@ -153,21 +153,21 @@
{
{
title
:
'状态'
,
title
:
'状态'
,
dataIndex
:
'status'
,
dataIndex
:
'status'
,
width
:
'1
20px'
,
width
:
'1
00px'
,
needTotal
:
true
,
needTotal
:
true
,
scopedSlots
:
{
customRender
:
'status'
},
scopedSlots
:
{
customRender
:
'status'
},
},
},
{
{
title
:
'更新时间'
,
title
:
'更新时间'
,
dataIndex
:
'updatedAt'
,
dataIndex
:
'updatedAt'
,
width
:
'1
80px'
,
width
:
'1
50px'
,
sorter
:
true
,
sorter
:
true
,
scopedSlots
:
{
customRender
:
'updatedAt'
},
scopedSlots
:
{
customRender
:
'updatedAt'
},
},
},
{
{
table
:
'操作'
,
table
:
'操作'
,
dataIndex
:
'action'
,
dataIndex
:
'action'
,
width
:
'1
50px'
,
width
:
'1
20px'
,
scopedSlots
:
{
customRender
:
'action'
},
scopedSlots
:
{
customRender
:
'action'
},
}
}
],
],
...
...
src/views/list/UserList.vue
View file @
90675607
...
@@ -40,10 +40,10 @@
...
@@ -40,10 +40,10 @@
:gutter=
"24"
:gutter=
"24"
:style=
"
{ marginBottom: '12px' }">
:style=
"
{ marginBottom: '12px' }">
<a-col
:span=
"12"
v-for=
"(role, index) in record.permissions"
:key=
"index"
:style=
"
{ marginBottom: '12px' }">
<a-col
:span=
"12"
v-for=
"(role, index) in record.permissions"
:key=
"index"
:style=
"
{ marginBottom: '12px' }">
<a-col
:
span=
"
4"
>
<a-col
:
lg=
"4"
:md=
"2
4"
>
<span>
{{
role
.
permissionName
}}
:
</span>
<span>
{{
role
.
permissionName
}}
:
</span>
</a-col>
</a-col>
<a-col
:
span=
"20
"
v-if=
"role.actionEntitySet.length > 0"
>
<a-col
:
lg=
"20"
:md=
"24
"
v-if=
"role.actionEntitySet.length > 0"
>
<a-tag
color=
"cyan"
v-for=
"(action, k) in role.actionEntitySet"
:key=
"k"
>
{{
action
.
describe
}}
</a-tag>
<a-tag
color=
"cyan"
v-for=
"(action, k) in role.actionEntitySet"
:key=
"k"
>
{{
action
.
describe
}}
</a-tag>
</a-col>
</a-col>
<a-col
:span=
"20"
v-else
>
-
</a-col>
<a-col
:span=
"20"
v-else
>
-
</a-col>
...
...
src/views/user/Login.vue
View file @
90675607
...
@@ -110,7 +110,7 @@
...
@@ -110,7 +110,7 @@
loginBtn
:
false
,
loginBtn
:
false
,
// login type: 0 email, 1 username, 2 telephone
// login type: 0 email, 1 username, 2 telephone
loginType
:
0
,
loginType
:
0
,
requiredTwoStepCaptcha
:
tru
e
,
requiredTwoStepCaptcha
:
fals
e
,
stepCaptchaVisible
:
false
,
stepCaptchaVisible
:
false
,
form
:
null
,
form
:
null
,
state
:
{
state
:
{
...
...
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