Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
super-hive-web
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Container Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
SuperHive
front-end
super-hive-web
Commits
472dd37d
Commit
472dd37d
authored
Aug 18, 2020
by
wends
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add 方波
parent
c4cb43aa
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
6 deletions
+24
-6
ELine.vue
src/components/Charts/ELine.vue
+8
-1
index.vue
src/views/device-management/device-monitoring/index.vue
+11
-3
index.vue
src/views/device-management/history-data/index.vue
+4
-1
index.vue
src/views/equipment-management/device-instance/index.vue
+1
-1
No files found.
src/components/Charts/ELine.vue
View file @
472dd37d
...
@@ -49,6 +49,10 @@ export default {
...
@@ -49,6 +49,10 @@ export default {
format
:
{
format
:
{
type
:
String
,
type
:
String
,
default
:
'
HH:mm:ss
'
default
:
'
HH:mm:ss
'
},
step
:
{
type
:
Boolean
,
default
:
false
}
}
},
},
data
()
{
data
()
{
...
@@ -92,7 +96,9 @@ export default {
...
@@ -92,7 +96,9 @@ export default {
},
},
series
:
[{
series
:
[{
name
:
this
.
title
,
name
:
this
.
title
,
data
:
series
data
:
series
,
type
:
'
line
'
,
step
:
this
.
step
?
'
start
'
:
this
.
step
}]
}]
})
})
},
},
...
@@ -114,6 +120,7 @@ export default {
...
@@ -114,6 +120,7 @@ export default {
series
:
[{
series
:
[{
name
:
this
.
title
,
name
:
this
.
title
,
type
:
'
line
'
,
type
:
'
line
'
,
step
:
this
.
step
?
'
start
'
:
this
.
step
,
data
:
[]
data
:
[]
}]
}]
}
}
...
...
src/views/device-management/device-monitoring/index.vue
View file @
472dd37d
...
@@ -93,6 +93,7 @@
...
@@ -93,6 +93,7 @@
<e-line
<e-line
v-if=
"propertyList.length"
v-if=
"propertyList.length"
:id=
"'line-' + property.propertyCode"
:id=
"'line-' + property.propertyCode"
:step=
"property.propertyType === 4"
:title=
"property.propertyName"
:title=
"property.propertyName"
:line-data=
"property.data"
:line-data=
"property.data"
:description=
"property.propertyUnit"
:description=
"property.propertyUnit"
...
@@ -168,11 +169,12 @@ export default {
...
@@ -168,11 +169,12 @@ export default {
if
(
newVal
!==
null
)
{
if
(
newVal
!==
null
)
{
const
property
=
this
.
propertyList
.
find
(
v
=>
v
.
propertyCode
===
newVal
)
const
property
=
this
.
propertyList
.
find
(
v
=>
v
.
propertyCode
===
newVal
)
if
(
property
)
{
if
(
property
)
{
const
{
propertyCode
,
propertyName
,
propertyUnit
}
=
property
const
{
propertyCode
,
propertyName
,
property
Type
,
property
Unit
}
=
property
this
.
property
=
{
this
.
property
=
{
propertyCode
,
propertyCode
,
propertyName
,
propertyName
,
propertyUnit
,
propertyUnit
,
propertyType
,
data
:
[...
this
.
getChartData
(
this
.
activeProperty
)]
data
:
[...
this
.
getChartData
(
this
.
activeProperty
)]
}
}
}
}
...
@@ -230,6 +232,8 @@ export default {
...
@@ -230,6 +232,8 @@ export default {
this
.
activeProperty
=
this
.
propertyList
[
0
].
propertyCode
this
.
activeProperty
=
this
.
propertyList
[
0
].
propertyCode
}
}
this
.
getDeviceInstanceDetail
(
this
.
form
.
deviceInstance
)
this
.
getDeviceInstanceDetail
(
this
.
form
.
deviceInstance
)
const
{
dataMode
,
deviceInstance
}
=
this
.
form
this
.
getPropertyDetail
(
dataMode
,
deviceInstance
)
return
[{
return
[{
modelId
:
this
.
form
.
dataMode
,
modelId
:
this
.
form
.
dataMode
,
deviceId
:
this
.
form
.
deviceInstance
,
deviceId
:
this
.
form
.
deviceInstance
,
...
@@ -238,7 +242,9 @@ export default {
...
@@ -238,7 +242,9 @@ export default {
})
})
.
then
(
params
=>
getModelInstanceChart
(
params
))
.
then
(
params
=>
getModelInstanceChart
(
params
))
.
then
(
res
=>
{
.
then
(
res
=>
{
this
.
tableData
=
res
.
data
[
0
].
dataList
this
.
tableData
=
res
.
data
[
0
].
dataList
.
sort
((
a
,
b
)
=>
{
return
(
a
>
b
)
?
1
:
-
1
})
this
.
property
.
data
=
[...
this
.
getChartData
(
this
.
activeProperty
)]
this
.
property
.
data
=
[...
this
.
getChartData
(
this
.
activeProperty
)]
return
[{
return
[{
modelId
:
this
.
form
.
dataMode
,
modelId
:
this
.
form
.
dataMode
,
...
@@ -252,7 +258,9 @@ export default {
...
@@ -252,7 +258,9 @@ export default {
this
.
timer
=
setInterval
(
async
()
=>
{
this
.
timer
=
setInterval
(
async
()
=>
{
await
this
.
getPropertyDetail
(
dataMode
,
deviceInstance
)
await
this
.
getPropertyDetail
(
dataMode
,
deviceInstance
)
const
chartData
=
await
getModelInstanceChart
(
params
)
const
chartData
=
await
getModelInstanceChart
(
params
)
this
.
tableData
=
chartData
.
data
[
0
].
dataList
this
.
tableData
=
chartData
.
data
[
0
].
dataList
.
sort
((
a
,
b
)
=>
{
return
(
a
>
b
)
?
1
:
-
1
})
this
.
property
.
data
=
[...
this
.
getChartData
(
this
.
activeProperty
)]
this
.
property
.
data
=
[...
this
.
getChartData
(
this
.
activeProperty
)]
},
this
.
form
.
refresh
*
1000
)
},
this
.
form
.
refresh
*
1000
)
})
})
...
...
src/views/device-management/history-data/index.vue
View file @
472dd37d
...
@@ -63,6 +63,7 @@
...
@@ -63,6 +63,7 @@
v-if=
"propertyList.length"
v-if=
"propertyList.length"
:id=
"'line-' + property.propertyCode"
:id=
"'line-' + property.propertyCode"
:title=
"property.propertyName"
:title=
"property.propertyName"
:step=
"property.propertyType === 4"
:line-data=
"property.data"
:line-data=
"property.data"
:description=
"property.propertyUnit"
:description=
"property.propertyUnit"
:config=
"lineConfig"
:config=
"lineConfig"
...
@@ -155,6 +156,7 @@ export default {
...
@@ -155,6 +156,7 @@ export default {
property
:
{
property
:
{
propertyCode
:
null
,
propertyCode
:
null
,
propertyName
:
null
,
propertyName
:
null
,
propertyType
:
null
,
propertyUnit
:
null
,
propertyUnit
:
null
,
data
:
[]
data
:
[]
},
},
...
@@ -210,11 +212,12 @@ export default {
...
@@ -210,11 +212,12 @@ export default {
if
(
newVal
)
{
if
(
newVal
)
{
const
property
=
this
.
propertyList
.
find
(
v
=>
v
.
propertyCode
===
newVal
)
const
property
=
this
.
propertyList
.
find
(
v
=>
v
.
propertyCode
===
newVal
)
if
(
property
)
{
if
(
property
)
{
const
{
propertyCode
,
propertyName
,
propertyUnit
}
=
property
const
{
propertyCode
,
propertyName
,
property
Type
,
property
Unit
}
=
property
this
.
property
=
{
this
.
property
=
{
propertyCode
,
propertyCode
,
propertyName
,
propertyName
,
propertyUnit
,
propertyUnit
,
propertyType
,
data
:
[...
this
.
getChartData
(
this
.
activeProperty
)]
data
:
[...
this
.
getChartData
(
this
.
activeProperty
)]
}
}
}
}
...
...
src/views/equipment-management/device-instance/index.vue
View file @
472dd37d
...
@@ -102,7 +102,7 @@
...
@@ -102,7 +102,7 @@
<el-table-column
<el-table-column
prop=
"onlineUpdateTime"
prop=
"onlineUpdateTime"
label=
"在线状态更新时间"
label=
"在线状态更新时间"
min-width=
"15
0
px"
min-width=
"15
5
px"
:formatter=
"$moment"
:formatter=
"$moment"
/>
/>
...
...
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