Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
h5
/
glsk-data-view-scene
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
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 993ef5c7
authored
Jan 26, 2024
by
前端
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
增加顶部参数
1 parent
79662a93
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
55 additions
and
5 deletions
src/components/Head.vue
src/components/Head.vue
View file @
993ef5c
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
<!-- 标题 开始 -->
<!-- 标题 开始 -->
<div
class=
"title_box"
>
<div
class=
"title_box"
>
<span
class=
"title"
>
广联数科运营看板
</span>
<span
class=
"title"
>
{{
title
}}
</span>
</div>
</div>
<!-- 标题 end -->
<!-- 标题 end -->
...
@@ -16,8 +16,8 @@
...
@@ -16,8 +16,8 @@
<div
class=
"right_box"
>
<div
class=
"right_box"
>
<!-- 日期、时间 开始 -->
<!-- 日期、时间 开始 -->
<div
class=
"time_box"
>
<div
class=
"time_box"
>
<span
class=
"date"
>
11月30日 周一
</span>
<span
class=
"date"
>
{{
month
}}
月
{{
day
}}
日
{{
week
}}
</span>
<span
class=
"time"
>
21:00:03
</span>
<span
class=
"time"
>
{{
time
}}
</span>
</div>
</div>
<!-- 日期、时间 end -->
<!-- 日期、时间 end -->
...
@@ -31,10 +31,60 @@
...
@@ -31,10 +31,60 @@
<
script
>
<
script
>
export
default
{
export
default
{
name
:
'TopHead'
,
name
:
'TopHead'
,
props
:
{
title
:
{
type
:
String
,
default
:
'广联数科运营看板'
}
},
data
()
{
data
()
{
return
{}
return
{
month
:
''
,
day
:
''
,
week
:
''
,
time
:
''
,
timeInterval
:
''
}
},
mounted
()
{
let
weekList
=
{
1
:
'周一'
,
2
:
'周二'
,
3
:
'周三'
,
4
:
'周四'
,
5
:
'周五'
,
6
:
'周六'
,
7
:
'周日'
}
let
m
=
new
Date
()
this
.
month
=
m
.
getMonth
()
+
1
this
.
day
=
m
.
getDate
()
this
.
week
=
weekList
[
m
.
getDay
()]
this
.
initTime
();
},
},
methods
:
{}
methods
:
{
// 定时获取时间
initTime
()
{
let
_this
=
this
if
(
this
.
timeInterval
)
{
clearInterval
(
this
.
timeInterval
)
}
_this
.
timeInterval
=
setInterval
(
function
()
{
_this
.
time
=
_this
.
getTime
()
},
1000
)
},
// 获取时间
getTime
()
{
let
time
=
''
let
o
=
new
Date
()
let
h
=
o
.
getHours
()
let
m
=
o
.
getMinutes
()
let
s
=
o
.
getSeconds
()
time
=
`
${
h
<
10
?
'0'
+
h
:
h
}
:
${
m
<
10
?
'0'
+
m
:
m
}
:
${
s
<
10
?
'0'
+
s
:
s
}
`
return
time
}
}
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
...
...
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