Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
T
towerFront
Project
Project
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
WitCloud
towerFront
Commits
8238acd4
Commit
8238acd4
authored
Jan 31, 2019
by
van.chen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
加入震动值
parent
eec5c67b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
9 deletions
+22
-9
advanced.component.html
src/app/routes/pro/profile/advanced/advanced.component.html
+9
-0
advanced.component.less
src/app/routes/pro/profile/advanced/advanced.component.less
+5
-5
advanced.component.ts
src/app/routes/pro/profile/advanced/advanced.component.ts
+7
-3
environment.ts
src/environments/environment.ts
+1
-1
No files found.
src/app/routes/pro/profile/advanced/advanced.component.html
View file @
8238acd4
...
...
@@ -27,6 +27,13 @@
<div
[
class
]="!
base
.
locker
||
base
.
locker
!==
'
1
.
0
'
?
'
rightLabel
danger
'
:
'
rightLabel
success
'"
>
{{base.locker === '1.0' ? '正常-关' : '异常-开'}}
</div>
</div>
<div
class=
"rightLine per50"
>
<img
class=
"rightIcon"
[
src
]="!
base
.
tiltWarn
?
'../../../../../
assets
/
img
/
13
.
png
'
:
'../../../../../
assets
/
img
/
12
.
png
'"
>
<span
class=
"descLabel"
>
震动值
</span>
<div
[
class
]="!
base
.
tiltWarn
?
'
rightLabel
danger
'
:
'
rightLabel
success
'"
>
{{base.light}}(°)
</div>
</div>
</div>
</div>
<nz-card
[
nzBordered
]="
false
"
>
...
...
@@ -36,11 +43,13 @@
<div
class=
"echartsPart"
echarts
[
options
]="
weektilt
"
></div>
<div
class=
"echartsPart"
echarts
[
options
]="
weektemp
"
></div>
<div
class=
"echartsPart"
echarts
[
options
]="
weekhumid
"
></div>
<div
class=
"echartsPart"
echarts
[
options
]="
weeklight
"
></div>
</nz-tab>
<nz-tab
nzTitle=
"一月内"
>
<div
class=
"echartsPart"
echarts
[
options
]="
monthtilt
"
></div>
<div
class=
"echartsPart"
echarts
[
options
]="
monthtemp
"
></div>
<div
class=
"echartsPart"
echarts
[
options
]="
monthhumid
"
></div>
<div
class=
"echartsPart"
echarts
[
options
]="
monthlight
"
></div>
</nz-tab>
</nz-tabset>
</nz-card-tab>
...
...
src/app/routes/pro/profile/advanced/advanced.component.less
View file @
8238acd4
...
...
@@ -35,7 +35,7 @@
}
.leftPart {
padding: 30px 20px;
line-height:
4
0px;
line-height:
5
0px;
z-index: 5;
display: inline-block;
font-size: 17px;
...
...
@@ -53,14 +53,14 @@
}
.oneIcon{
display: inline-block;
height:
4
0px;
width:
4
0px;
height:
5
0px;
width:
5
0px;
text-align: center;
margin: 0 10px;
}
.oneLabel {
display: inline-block;
width: calc(35% - 3
0
px);
width: calc(35% - 3
5
px);
}
.oneLine {
@media screen and (min-width: @screen-md) {
...
...
@@ -69,7 +69,7 @@
}
.oneValue {
display: inline-block;
width: calc(64% - 3
0
px);
width: calc(64% - 3
5
px);
}
.rightPart {
z-index: 5;
...
...
src/app/routes/pro/profile/advanced/advanced.component.ts
View file @
8238acd4
...
...
@@ -21,10 +21,13 @@ export class ProProfileAdvancedComponent implements OnInit {
monthtemp
:
{};
monthhumid
:
{};
monthtilt
:
{};
weeklight
:
{};
monthlight
:
{};
trans
=
{
temp
:
'温度数据'
,
humid
:
'湿度数据'
,
tilt
:
'倾斜数据'
,
light
:
'震动数据'
,
month
:
'近一月'
,
week
:
'近一周'
,
};
...
...
@@ -117,6 +120,7 @@ export class ProProfileAdvancedComponent implements OnInit {
if
(
res
&&
res
.
towerNo
)
{
this
.
base
=
res
;
this
.
base
.
tiltWarn
=
(
res
.
tilt
&&
Number
(
res
.
tilt
)
<
20
&&
Number
(
res
.
tilt
)
>
-
20
)
||
res
.
tilt
===
'N/A'
?
true
:
false
;
this
.
base
.
lightWarn
=
(
res
.
tilt
&&
Number
(
res
.
tilt
)
<
20
&&
Number
(
res
.
tilt
)
>
-
20
)
||
res
.
tilt
===
'N/A'
?
true
:
false
;
}
else
{
this
.
message
.
error
(
res
.
message
);
}
...
...
@@ -126,7 +130,7 @@ export class ProProfileAdvancedComponent implements OnInit {
getWeekCharts
()
{
this
.
isLoading
=
true
;
const
param
=
[
'tilt'
,
'temp'
,
'humid'
];
const
param
=
[
'tilt'
,
'temp'
,
'humid'
,
'light'
];
param
.
map
((
item
,
index
)
=>
{
this
.
getChart
(
item
,
'week'
,
index
);
});
...
...
@@ -134,7 +138,7 @@ export class ProProfileAdvancedComponent implements OnInit {
getMonthCharts
()
{
this
.
isLoading
=
true
;
const
param
=
[
'tilt'
,
'temp'
,
'humid'
];
const
param
=
[
'tilt'
,
'temp'
,
'humid'
,
'light'
];
param
.
map
((
item
,
index
)
=>
{
this
.
getChart
(
item
,
'month'
,
index
);
});
...
...
@@ -170,7 +174,7 @@ export class ProProfileAdvancedComponent implements OnInit {
}
});
}
if
(
index
===
2
)
{
if
(
index
===
3
)
{
this
.
isLoading
=
false
;
}
});
...
...
src/environments/environment.ts
View file @
8238acd4
...
...
@@ -7,7 +7,7 @@ export const environment = {
production
:
false
,
useHash
:
true
,
hmr
:
false
,
baseUrl
:
'http://192.168.1.
13
:8092'
baseUrl
:
'http://192.168.1.
52
:8092'
};
/*
...
...
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