Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
html
/
MeteorologicalBureau
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
d05d0d9f
authored
Jul 02, 2020
by
fengfan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
event
parent
62be592c
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
88 additions
and
118 deletions
+88
-118
ipadCtr/src/main.js
+2
-0
ipadCtr/src/pages/event.vue
+78
-116
ipadCtr/src/pages/industry.vue
+8
-2
No files found.
ipadCtr/src/main.js
View file @
d05d0d9f
...
...
@@ -17,3 +17,5 @@ new Vue({
components
:
{
App
},
template
:
'<App/>'
})
//http://123.56.149.208:8091/swagger-ui.html#!/3371921462228063709625968254542716922359/getEarlyWarnEquipmentTwoUsingGET
ipadCtr/src/pages/event.vue
View file @
d05d0d9f
<
template
>
<div
class=
"page"
>
<content-box
:btnbackshow=
"btnbackshow"
@
btnbackclick=
"backfn"
>
<div
class=
"content"
>
<div
class=
"subtitle"
>
{{
subtitle
.
name
||
'全国'
}}
:
</div>
<div
class=
"title"
>
当前事件 :
{{
eventList
[
activeIndex
].
name
}}
</div>
<div
class=
"subtitle"
>
历史事件 :
</div>
<div
id=
"scrollbox"
>
<vuescroll
:ops=
"ops"
>
<div
class=
"btn
"
:class=
"
{activearea:activearea.code == item.code
}"
v-for="(item,index) in btnl
ist"
class=
"item
"
:class=
"
{active:index===activeIndex
}"
v-for="(item,index) in eventL
ist"
:key="index"
@click="showC(item
)"
@click="go(index
)"
>
{{
item
.
name
}}
</div>
</vuescroll>
</div>
<page-title
v-if=
"activearea.code === subtitle.code || activearea.name=='全国'"
class=
"titlePosition"
:titledata=
"titledata"
:titleactive=
"titleactive"
@
titleclick=
"titleclickfn"
/>
</div>
</content-box>
</div>
</
template
>
<
script
>
import
{
send
}
from
"@/service/ctrapi"
;
import
contentBox
from
"../components/contentBox"
;
import
pageTitle
from
"../components/pageTitle"
;
import
vuescroll
from
"vuescroll"
;
export
default
{
components
:
{
contentBox
,
pageTitle
,
vuescroll
},
components
:
{
vuescroll
},
data
()
{
return
{
btnlist
:
[],
titledata
:
[
"24小时"
,
"近一周"
,
"近一月"
,
"近一年"
],
msgPathCfg
:{
root
:
'/预警监控'
,
list1
:
'/省级'
,
subtitle
:
'/时间范围'
,
},
titleactive
:
0
,
activearea
:
{},
subtitle
:
{},
btnbackshow
:
false
,
eventList
:
[{}],
activeIndex
:
0
,
ops
:
{
bar
:
{
background
:
"#41c9ff"
,
...
...
@@ -59,61 +38,16 @@ export default {
};
},
mounted
()
{
this
.
showP
();
},
methods
:
{
backfn
()
{
send
(
`
${
this
.
msgPathCfg
.
root
}
`
,
[]);
this
.
showP
();
},
showP
()
{
this
.
$axios
.
get
(
"http://123.56.149.208:8091/external/get/city/all"
)
.
get
(
`http://123.56.149.208:8091/external/get/all/event`
)
.
then
(
val
=>
{
this
.
btnlist
=
val
.
data
.
data
;
this
.
btnbackshow
=
false
;
this
.
titleactive
=
0
this
.
activearea
=
this
.
btnlist
[
0
];
this
.
subtitle
=
{};
this
.
eventList
=
val
.
data
.
data
;
});
},
showC
(
item
)
{
if
(
this
.
btnbackshow
)
{
this
.
activearea
=
item
;
send
(
`
${
this
.
msgPathCfg
.
root
}${
this
.
msgPathCfg
.
list1
}
/
${
this
.
subtitle
.
name
}
/H5/
${
this
.
activearea
.
name
}
`
,
[]
);
}
else
if
(
item
.
name
===
"全国"
)
{
this
.
activearea
=
item
;
send
(
`
${
this
.
msgPathCfg
.
root
}${
this
.
msgPathCfg
.
subtitle
}
/
${
this
.
titleactive
}
`
,
[]);
}
else
{
this
.
$axios
.
get
(
`http://123.56.149.208:8091/external/get/city/id/
${
item
.
code
}
`
)
.
then
(
val
=>
{
this
.
btnlist
=
val
.
data
.
data
;
this
.
btnbackshow
=
true
;
this
.
subtitle
=
item
;
this
.
activearea
=
item
;
send
(
`
${
this
.
msgPathCfg
.
root
}${
this
.
msgPathCfg
.
list1
}
/
${
this
.
subtitle
.
name
}${
this
.
msgPathCfg
.
subtitle
}
/
${
this
.
titleactive
}
`
,
[]
);
});
}
},
titleclickfn
(
i
)
{
this
.
titleactive
=
i
;
if
(
this
.
btnbackshow
&&
this
.
activearea
==
this
.
subtitle
)
{
send
(
`
${
this
.
msgPathCfg
.
root
}${
this
.
msgPathCfg
.
list1
}
/
${
this
.
subtitle
.
name
}${
this
.
msgPathCfg
.
subtitle
}
/
${
this
.
titleactive
}
`
,
[]
);
}
else
if
(
this
.
activearea
.
name
===
"全国"
)
{
send
(
`
${
this
.
msgPathCfg
.
root
}${
this
.
msgPathCfg
.
subtitle
}
/
${
this
.
titleactive
}
`
,
[]);
}
else
{
// send( `${this.msgPathCfg.root}${this.msgPathCfg.list1}/${this.subtitle.name}${this.msgPathCfg.subtitle}/${this.titleactive}`, []);
}
methods
:
{
go
(
index
){
this
.
activeIndex
=
index
send
(
`/事件监控/事件名称/
${
this
.
eventList
[
index
].
name
}
`
,[])
}
}
};
...
...
@@ -127,57 +61,85 @@ export default {
background-size
:
cover
;
margin-top
:
1.5rem
;
margin-left
:
2.2rem
;
}
.content
{
padding-top
:
1rem
;
padding-left
:
1rem
;
text-align
:
left
;
color
:
#fff
;
font-size
:
0.4rem
;
letter-spacing
:
0.04em
;
}
.title
{
position
:
relative
;
margin-left
:
2.9rem
;
padding-top
:
2.5rem
;
text-shadow
:
0.1rem
0rem
0.5rem
rgba
(
255
,
255
,
255
,
0.3
),
-0.1rem
0rem
0.5rem
rgba
(
255
,
255
,
255
,
0.3
),
0rem
0.1rem
0.5rem
rgba
(
255
,
255
,
255
,
0.3
),
0rem
-0.1rem
0.5rem
rgba
(
255
,
255
,
255
,
0.3
);
}
.title
::after
{
content
:
""
;
display
:
block
;
position
:
absolute
;
width
:
0.1rem
;
height
:
0.1rem
;
border-radius
:
50%
;
left
:
-0.3rem
;
background
:
#fff
;
z-index
:
1
;
bottom
:
0.1rem
;
}
.subtitle
{
width
:
15rem
;
border-bottom
:
1px
solid
rgba
(
255
,
255
,
255
,
0.3
);
margin-left
:
2.5rem
;
padding-top
:
0.5rem
;
padding-bottom
:
0.2rem
;
font-size
:
0.3rem
;
}
#scrollbox
{
width
:
15
.5
rem
;
height
:
9
rem
;
margin-left
:
1
rem
;
margin-top
:
0.
5
rem
;
width
:
15rem
;
height
:
8
rem
;
margin-left
:
2.5
rem
;
margin-top
:
0.
1
rem
;
}
.
btn
{
float
:
left
;
white-space
:
nowrap
;
.
item
{
color
:
#ced0d2
;
margin
:
0.2rem
0
0.2rem
0.5rem
;
font-size
:
0.3rem
;
color
:
#fff
;
text-align
:
center
;
line-height
:
0.81rem
;
padding
:
0
0.1rem
;
margin
:
0
0.45rem
0.74rem
0
;
min-width
:
2.59rem
;
height
:
0.81rem
;
background
:
url(../assets/img/btn-bg.png)
no-repeat
;
background-size
:
100%
100%
;
line-height
:
0.6rem
;
height
:
0.6rem
;
position
:
relative
;
}
.subtitle
{
margin
:
0.5rem
0
0.5rem
1rem
;
.item.active
{
color
:
#fff
;
font-size
:
0.4rem
;
text-shadow
:
0.1rem
0rem
0.5rem
rgba
(
255
,
255
,
255
,
0.3
),
-0.1rem
0rem
0.5rem
rgba
(
255
,
255
,
255
,
0.3
),
0rem
0.1rem
0.5rem
rgba
(
255
,
255
,
255
,
0.3
),
0rem
-0.1rem
0.5rem
rgba
(
255
,
255
,
255
,
0.3
);
}
.activearea
{
font-size
:
0.35rem
;
.item
::after
{
content
:
""
;
display
:
block
;
position
:
absolute
;
width
:
0.1rem
;
height
:
0.1rem
;
border-radius
:
50%
;
left
:
-0.4rem
;
top
:
0.25rem
;
background
:
rgba
(
255
,
255
,
255
,
0.3
);
z-index
:
1
;
}
.
activearea
::after
{
.
item
::before
{
content
:
""
;
display
:
block
;
position
:
absolute
;
left
:
0
;
right
:
0
;
top
:
0
;
bottom
:
-100%
;
background
:
url(../assets/img/btn-light.png)
no-repeat
;
background-size
:
100%
94%
;
width
:
1px
;
height
:
0.7rem
;
left
:
-0.36rem
;
top
:
0.35rem
;
background
:
rgba
(
255
,
255
,
255
,
0.3
)
;
z-index
:
1
;
}
>>>
div
.title
{
background
:
none
;
transform
:
translateY
(
-0.2rem
);
.item
:last-child::before
{
display
:
none
;
}
</
style
>
ipadCtr/src/pages/industry.vue
View file @
d05d0d9f
...
...
@@ -22,6 +22,7 @@
import
contentBox
from
"../components/contentBox"
;
import
pageTitle
from
"../components/pageTitle"
;
import
vuescroll
from
"vuescroll"
;
import
{
send
}
from
"@/service/ctrapi"
;
export
default
{
components
:
{
contentBox
,
pageTitle
,
vuescroll
},
data
()
{
...
...
@@ -51,7 +52,7 @@ export default {
},
showP
()
{
this
.
$axios
.
get
(
"http://123.56.149.208:8091/external/get/
all/bw
"
)
.
get
(
"http://123.56.149.208:8091/external/get/
city/all
"
)
.
then
(
val
=>
{
this
.
btnlist
=
val
.
data
.
data
;
this
.
activearea
=
this
.
btnlist
[
0
]
...
...
@@ -59,6 +60,11 @@ export default {
},
showC
(
item
)
{
this
.
activearea
=
item
if
(
item
.
name
===
'全国'
){
send
(
`/行业聚焦`
,
[]);
}
else
{
send
(
`/行业聚焦/省级/
${
item
.
name
}
`
,
[]);
}
},
titleclickfn
(
i
)
{
this
.
titleactive
=
i
;
...
...
@@ -77,7 +83,7 @@ export default {
margin-left
:
2.2rem
;
}
.content
{
padding-top
:
1
rem
;
padding-top
:
2
rem
;
padding-left
:
1rem
;
text-align
:
left
;
}
...
...
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