Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
micro-customization-system
/
micro-portal
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit e8efb59a
authored
Jun 04, 2021
by
冒粤蓉
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix
1 parent
68bd6679
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
42 additions
and
16 deletions
public/index.html
src/components/DesktopLeftSider/Sub/Menu.vue
src/components/DesktopLeftSider/Sub/NavInfoCard.vue
src/components/HomeContent/HomeContent.vue
src/components/HomeContent/Sub/LoginForm.vue
src/store/modules/menu.js
src/views/Login.vue
public/index.html
View file @
e8efb59
...
...
@@ -7,7 +7,7 @@
<link
rel=
"icon"
href=
"<%= BASE_URL %>favicon.ico"
>
<title>
<
%= htmlWebpackPlugin.options.title %>
</title>
</head>
<body>
<body
style=
"margin: 0;"
>
<noscript>
<strong>
We're sorry but
<
%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.
</strong>
</noscript>
...
...
src/components/DesktopLeftSider/Sub/Menu.vue
View file @
e8efb59
...
...
@@ -6,7 +6,7 @@
class=
"section"
v-for=
"(item, index) in menuList"
:key=
"item.origin.menuNo"
>
<input
type=
"radio"
name=
"accordion-radio"
:id=
"'section-'+index"
:checked=
"item.showSubList"
@
click=
"titleClick(item)"
/>
<input
type=
"radio"
name=
"accordion-radio"
:id=
"'section-'+index"
:checked=
"item.showSubList"
@
click=
"titleClick(item
, index
)"
/>
<label
:for=
"'section-'+index"
>
<span>
{{
item
.
origin
.
menuName
}}
</span>
<!-- :class="
{'rotate-deg': item.showSubList}" -->
...
...
@@ -97,11 +97,13 @@ export default {
});
// 点击主菜单标题
const
titleClick
=
(
item
)
=>
{
state
.
menuList
.
forEach
(
i
=>
{
i
.
showSubList
=
false
;
const
titleClick
=
(
item
,
idx
)
=>
{
state
.
menuList
.
forEach
((
i
,
index
)
=>
{
if
(
idx
!==
index
)
{
i
.
showSubList
=
false
;
}
})
item
.
showSubList
=
true
;
item
.
showSubList
=
!
item
.
showSubList
;
};
// 高亮被选中的子集标题
...
...
src/components/DesktopLeftSider/Sub/NavInfoCard.vue
View file @
e8efb59
...
...
@@ -142,6 +142,7 @@ export default {
visibility
:
hidden
;
-webkit-transition
:
all
400ms
cubic-bezier
(
0.34
,
1.25
,
0.3
,
1
);
transition
:
all
400ms
cubic-bezier
(
0.34
,
1.25
,
0.3
,
1
);
font-size
:
16px
!important
;
.arrow-icon
{
height
:
21px
;
...
...
src/components/HomeContent/HomeContent.vue
View file @
e8efb59
...
...
@@ -22,12 +22,16 @@ export default {
.home-content-wrapper
{
position
:
absolute
;
z-index
:
1
;
top
:
139px
;
left
:
0
;
background-image
:
url(../../assets/images/car-bg.png)
;
background-size
:
100%
;
background-repeat
:
no-repeat
;
background-position
:
center
;
width
:
100%
;
height
:
calc
(
100%
-
278px
);
margin-top
:
139px
;
background
:
url(../../assets/images/car-bg.png)
no-repeat
center
;
background-size
:
cover
;
padding
:
20px
200px
;
overflow
:
hidden
;
height
:
calc
(
100%
-
268px
);
min-width
:
1000px
;
min-height
:
650px
;
}
</
style
>
\ No newline at end of file
src/components/HomeContent/Sub/LoginForm.vue
View file @
e8efb59
...
...
@@ -41,7 +41,7 @@
<img
class=
"captcha-img"
:src=
"`data:image/jpeg;base64,$
{captchaUrl}`" alt="验证码" />
</div>
</a-form-item>
-->
<el-form-item
class=
"login-button-wrapper"
@
click
=
"handleSubmit"
>
<el-form-item
class=
"login-button-wrapper"
@
keyup
.
enter=
"handleSubmit"
@
click
.
native
.
prevent
=
"handleSubmit"
>
<el-button
class=
"login-button"
type=
"primary"
...
...
@@ -65,7 +65,7 @@ import LoginService from '@/services/Login';
// import { UserOutlined, LockOutlined } from '@ant-design/icons-vue';
import
{
reactive
,
toRefs
,
getCurrentInstance
,
computed
}
from
'vue'
;
import
{
reactive
,
toRefs
,
getCurrentInstance
,
computed
,
onBeforeMount
}
from
'vue'
;
import
{
useStore
}
from
'vuex'
;
import
{
useRouter
}
from
'vue-router'
;
...
...
@@ -94,6 +94,14 @@ export default {
const
{
ctx
:
_this
}
=
getCurrentInstance
()
const
loginService
=
new
LoginService
();
onBeforeMount
(()
=>
{
document
.
onkeydown
=
e
=>
{
if
(
e
.
keyCode
===
13
)
{
handleSubmit
()
}
}
})
const
validatePass
=
(
rule
,
value
,
callback
)
=>
{
if
(
value
===
''
)
{
callback
(
new
Error
(
'请输入密码'
));
...
...
@@ -203,7 +211,7 @@ export default {
.login-content
{
display
:
flex
;
justify-content
:
space-between
;
width
:
100
%
;
width
:
95
%
;
height
:
420px
;
}
...
...
src/store/modules/menu.js
View file @
e8efb59
...
...
@@ -16,6 +16,16 @@ try {
}
const
checkRepeatedData
=
(
data
,
type
)
=>
{
let
arr
=
[];
data
.
forEach
(
item
=>
{
if
(
arr
.
indexOf
(
item
[
type
])
<
0
)
{
arr
.
push
(
item
);
}
});
return
arr
;
}
export
default
{
namespaced
:
true
,
state
,
...
...
@@ -31,7 +41,7 @@ export default {
// 设置面包屑
SET_BREAD_CRUMB
(
state
,
data
)
{
if
(
!
init
)
{
state
.
curBreadCrumb
=
data
;
state
.
curBreadCrumb
=
checkRepeatedData
(
data
,
'name'
)
;
localStorage
.
setItem
(
'breadcrumb'
,
JSON
.
stringify
(
data
));
}
init
=
false
;
...
...
src/views/Login.vue
View file @
e8efb59
...
...
@@ -35,5 +35,6 @@ export default {
left
:
0
;
width
:
100%
;
min-width
:
1190px
;
overflow-y
:
scroll
;
}
</
style
>
\ No newline at end of file
Write
Preview
Markdown
is supported
Attach a file
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 post a comment