Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gs1
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
吴迪
gs1
Commits
d40257b3
Commit
d40257b3
authored
Sep 26, 2021
by
tang
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
d0a7bf69
4561627d
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
78 additions
and
74 deletions
+78
-74
App.vue
src/App.vue
+4
-2
logo.png
src/assets/image/head/logo.png
+0
-0
header.vue
src/components/layout/header.vue
+57
-64
main.vue
src/components/main.vue
+2
-2
main.js
src/main.js
+4
-1
index.vue
src/views/News/index.vue
+11
-5
No files found.
src/App.vue
View file @
d40257b3
<
template
>
<
template
>
<div
id=
"app"
>
<div
id=
"app"
class=
"container-fluid"
>
<router-view></router-view>
<router-view></router-view>
</div>
</div>
</
template
>
</
template
>
...
@@ -9,5 +9,7 @@
...
@@ -9,5 +9,7 @@
</
script
>
</
script
>
<
style
>
<
style
>
.container-fluid
{
padding
:
0
;
}
</
style
>
</
style
>
src/assets/image/head/logo.png
0 → 100644
View file @
d40257b3
6.83 KB
src/components/layout/header.vue
View file @
d40257b3
<
template
>
<
template
>
<header>
<header>
<div
class=
"header-user"
>
<div
class=
"logo"
></div>
<img
src=
"../../assets/image/login-bg.jpg"
alt=
""
/>
<nav
class=
"navbar navbar-expand-lg navbar-light bg-light"
>
<div>
<a
class=
"navbar-brand"
href=
"#"
>
Navbar
</a>
<p
class=
"user-name"
>
{{
userNameInfoStr
}}
</p>
<button
<p
class=
"user-role"
>
{{
userRoleInfoStr
}}
</p>
class=
"navbar-toggler"
</div>
type=
"button"
data-toggle=
"collapse"
data-target=
"#navbarSupportedContent"
aria-controls=
"navbarSupportedContent"
aria-expanded=
"false"
aria-label=
"Toggle navigation"
>
<span
class=
"navbar-toggler-icon"
></span>
</button>
<div
class=
"collapse navbar-collapse"
id=
"navbarSupportedContent"
>
<ul
class=
"navbar-nav mr-auto"
>
<li
class=
"nav-item active"
>
<a
class=
"nav-link"
href=
"#"
>
Home
<span
class=
"sr-only"
>
(current)
</span></a
>
</li>
<li
class=
"nav-item"
>
<a
class=
"nav-link"
href=
"#"
>
Link
</a>
</li>
<li
class=
"nav-item dropdown"
>
<a
class=
"nav-link dropdown-toggle"
href=
"#"
id=
"navbarDropdown"
role=
"button"
data-toggle=
"dropdown"
aria-expanded=
"false"
>
Dropdown
</a>
<div
class=
"dropdown-menu"
aria-labelledby=
"navbarDropdown"
>
<a
class=
"dropdown-item"
href=
"#"
>
Action
</a>
<a
class=
"dropdown-item"
href=
"#"
>
Another action
</a>
<div
class=
"dropdown-divider"
></div>
<a
class=
"dropdown-item"
href=
"#"
>
Something else here
</a>
</div>
</div>
<div
class=
"header-logout"
>
</li>
<span
@
click=
"handleLogout"
>
<li
class=
"nav-item"
>
<img
src=
"../../assets/image/icon-logout.png"
alt=
""
>
<a
<p>
退出
</p>
class=
"nav-link disabled"
</span>
href=
"#"
tabindex=
"-1"
aria-disabled=
"true"
>
Disabled
</a
>
</li>
</ul>
</div>
</div>
</nav>
<div
class=
"user"
></div>
</header>
</header>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
export
default
{
mapActions
,
mapGetters
}
from
"vuex"
export
default
{
data
()
{
data
()
{
return
{
return
{};
menu
:[]
}
},
computed
:{
...
mapGetters
(
"user"
,
[
"userName"
,
"userBlockName"
,
"userRoleName"
]),
userNameInfoStr
()
{
return
`你好,
${
this
.
userName
}
!`
},
userRoleInfoStr
()
{
let
str
=
""
if
(
this
.
userBlockName
)
{
str
+=
`
${
this
.
userBlockName
}
`
}
if
(
this
.
userRoleName
)
{
str
+=
`
${
this
.
userRoleName
}
`
}
return
str
}
},
methods
:
{
...
mapActions
(
"user"
,
[
"LogoutActionAction"
]),
handleLogout
(){
this
.
$confirm
(
"是否退出登录"
,
"提示"
,
{
type
:
"warning"
,
closeOnClickModal
:
false
,
cancelButtonClass
:
"cancel"
,
confirmButtonClass
:
"confirm"
,
}).
then
(()
=>
{
// 清除登录信息
this
.
LogoutActionAction
()
}).
catch
(()
=>
{})
},
},
};
},
mounted
()
{
},
created
(){
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
>
<
style
lang=
"scss"
>
...
...
src/components/main.vue
View file @
d40257b3
<
template
>
<
template
>
<el-container
class=
"layout"
>
<el-container>
<el-container>
<el-header
height=
"65px"
>
<el-container>
<el-header>
<Header></Header>
<Header></Header>
</el-header>
</el-header>
<el-main>
<el-main>
...
...
src/main.js
View file @
d40257b3
...
@@ -2,8 +2,9 @@ import Vue from 'vue'
...
@@ -2,8 +2,9 @@ import Vue from 'vue'
import
App
from
'./App.vue'
import
App
from
'./App.vue'
import
router
from
'./router/index'
import
router
from
'./router/index'
import
store
from
'./vuex/store'
import
store
from
'./vuex/store'
import
$
from
'jquery'
import
'bootstrap/dist/css/bootstrap.min.css'
import
'bootstrap/dist/css/bootstrap.min.css'
import
'bootstrap/dist/js/bootstrap.min'
import
'bootstrap/dist/js/bootstrap.min
.js
'
import
'./plugins/element.js'
import
'./plugins/element.js'
import
'./plugins/qrcode.js'
import
'./plugins/qrcode.js'
import
"./assets/css/main.scss"
import
"./assets/css/main.scss"
...
@@ -43,6 +44,7 @@ Vue.use(Clipboard)
...
@@ -43,6 +44,7 @@ Vue.use(Clipboard)
// Vuex
// Vuex
import
storage
from
"./utils/storage.js"
import
storage
from
"./utils/storage.js"
Vue
.
prototype
.
$storage
=
storage
Vue
.
prototype
.
$storage
=
storage
Vue
.
prototype
.
$
=
$
// ngprogress
// ngprogress
import
NProgress
from
"nprogress"
;
import
NProgress
from
"nprogress"
;
...
@@ -100,5 +102,6 @@ router.afterEach(() => {
...
@@ -100,5 +102,6 @@ router.afterEach(() => {
window
.
vm
=
new
Vue
({
window
.
vm
=
new
Vue
({
router
,
router
,
store
,
store
,
$
,
render
:
h
=>
h
(
App
)
render
:
h
=>
h
(
App
)
}).
$mount
(
'#app'
)
}).
$mount
(
'#app'
)
src/views/News/index.vue
View file @
d40257b3
<
template
>
<
template
>
<div></div>
<div>
</
template
>
</div>
</
template
>
<
script
>
<
script
>
</
script
>
export
default
{
data
()
{
return
{
<
style
lang=
"scss"
>
}
</
style
>
},
}
</
script
>
\ No newline at end of file
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