Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yindong-tongbai-automation
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lichunliang
yindong-tongbai-automation
Commits
a9402174
Commit
a9402174
authored
Apr 02, 2025
by
forevertyler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:水位历史、报警
parent
06eb3b15
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
221 additions
and
39 deletions
+221
-39
waterLevelAlarm.js
src/api/tyler/waterLevelAlarm.js
+19
-0
waterLevelHis.js
src/api/tyler/waterLevelHis.js
+19
-0
index.vue
src/views/drainage/drainageDev/index.vue
+1
-1
index.vue
src/views/drainage/waterLevelAlarm/index.vue
+59
-38
index.vue
src/views/drainage/waterLevelHis/index.vue
+120
-0
index.vue
src/views/drainage/waterPumpSwitchHis/index.vue
+3
-0
No files found.
src/api/tyler/waterLevelAlarm.js
0 → 100644
View file @
a9402174
import
request
from
'
@/utils/request
'
// 查询水泵历史信息列表
export
function
listSumpAlarmHistory
(
query
)
{
return
request
({
url
:
'
/business/sump/alarm/history/list
'
,
method
:
'
get
'
,
params
:
query
})
}
// 查询水泵历史信息所有列表
export
function
listAllSumpHistory
(
query
)
{
return
request
({
url
:
'
/business/pump/history/listAll
'
,
method
:
'
get
'
,
params
:
query
})
}
\ No newline at end of file
src/api/tyler/waterLevelHis.js
0 → 100644
View file @
a9402174
import
request
from
'
@/utils/request
'
// 查询水泵历史信息列表
export
function
listSumpHistory
(
query
)
{
return
request
({
url
:
'
/business/sump/history/list
'
,
method
:
'
get
'
,
params
:
query
})
}
// 查询水泵历史信息所有列表
export
function
listAllSumpHistory
(
query
)
{
return
request
({
url
:
'
/business/pump/history/listAll
'
,
method
:
'
get
'
,
params
:
query
})
}
\ No newline at end of file
src/views/drainage/drainageDev/index.vue
View file @
a9402174
...
...
@@ -110,7 +110,7 @@
<el-input
v-model=
"form.deviceName"
placeholder=
"请输入设备名称"
/>
</el-form-item>
<el-form-item
label=
"设备编号"
prop=
"deviceId"
>
<el-input
v-model=
"form.deviceId"
placeholder=
"请输入设备编号"
/>
<el-input
:disabled=
"disabledType"
v-model=
"form.deviceId"
placeholder=
"请输入设备编号"
/>
</el-form-item>
<el-form-item
label=
"设备安装位置"
prop=
"installationLocation"
>
...
...
src/views/drainage/water
PumpHis copy
/index.vue
→
src/views/drainage/water
LevelAlarm
/index.vue
View file @
a9402174
<
template
>
<div
class=
"app-container"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"68px"
>
<el-form-item
label=
""
prop=
"
p
umpName"
>
<el-select
v-model=
"queryParams.
pumpName"
placeholder=
"水泵
名称"
clearable
>
<el-form-item
label=
""
prop=
"
s
umpName"
>
<el-select
v-model=
"queryParams.
sumpName"
placeholder=
"设备
名称"
clearable
>
<el-option
v-for=
"dict in devList"
:key=
"dict.name"
...
...
@@ -20,19 +20,30 @@
</el-form-item>
</el-form>
<el-table
v-loading=
"loading"
:data=
"historyList"
@
selection-change=
"handleSelectionChange"
>
<el-table-column
label=
"水泵名称"
align=
"center"
prop=
"pumpName"
/>
<el-table-column
label=
"水泵编号"
align=
"center"
prop=
"pumpId"
/>
<el-table-column
label=
"电机电流"
align=
"center"
prop=
"motorCurrent"
/>
<el-table-column
label=
"电机轴承温度"
align=
"center"
prop=
"motorBearingTemp"
/>
<el-table-column
label=
"水泵轴承温度"
align=
"center"
prop=
"pumpBearingTemp"
/>
<el-table-column
label=
"水泵流量"
align=
"center"
prop=
"pumpFlow"
/>
<el-table-column
label=
"排水管路压力"
align=
"center"
prop=
"drainagePressure"
/>
<el-table-column
label=
"监测时间"
align=
"center"
prop=
"monitoringTime"
width=
"180"
>
<el-table-column
label=
"设备名称"
align=
"center"
prop=
"sumpName"
/>
<el-table-column
label=
"设备编号"
align=
"center"
prop=
"sumpId"
/>
<el-table-column
label=
"设备安装位置"
align=
"center"
prop=
"installationLocation"
/>
<el-table-column
label=
"液位高度(m)"
align=
"center"
prop=
"heghtThreshold"
/>
<el-table-column
label=
"报警时间"
align=
"center"
prop=
"alarmTime"
width=
"180"
>
<template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
alarmTime
)
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"状态"
align=
"center"
class-name=
"small-padding fixed-width"
>
<
template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
monitoringTime
)
}}
</span>
<el-button
type=
"primary"
@
click=
"handleUpdate(scope.row)"
v-if=
"scope.row.status==1"
>
处置
</el-button>
<span
v-else
>
已处置
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"解除报警时间"
align=
"center"
prop=
"delAlarmTime"
width=
"180"
>
<
template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
delAlarmTime
)
}}
</span>
</
template
>
</el-table-column>
</el-table>
...
...
@@ -44,12 +55,27 @@
:limit.sync=
"queryParams.pageSize"
@
pagination=
"getList"
/>
<!-- 添加或修改排水设备信息对话框 -->
<el-dialog
:title=
"title"
:visible.sync=
"open"
width=
"700px"
append-to-body
>
<el-form
ref=
"form"
:model=
"form"
:rules=
"rules"
label-width=
"140px"
>
<el-form-item
label=
"解除原因"
prop=
"delAlarmResion"
>
<el-input
type=
"textarea"
v-model=
"form.delAlarmResion"
placeholder=
"请输入解除原因"
/>
</el-form-item>
<el-form-item
label=
"解除报警时长(h)"
prop=
"time"
>
<el-input
v-model=
"form.time"
placeholder=
"请输入解除报警时长(h)"
/>
</el-form-item>
</el-form>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
@
click=
"cancel"
>
取 消
</el-button>
</div>
</el-dialog>
</div>
</template>
<
script
>
import
{
getHistory
,
listHistory
}
from
"
@/api/tyler/waterPumpHis
"
;
import
{
listSumpAlarmHistory
,
updateWarterPumpAlarmHis
}
from
"
@/api/tyler/waterLevelAlarm
"
;
import
{
draDeviceName
}
from
"
@/api/tyler/common
"
;
export
default
{
...
...
@@ -70,7 +96,7 @@
showSearch
:
true
,
// 总条数
total
:
0
,
//
水泵
历史信息表格数据
//
设备
历史信息表格数据
historyList
:
[],
// 弹出层标题
title
:
""
,
...
...
@@ -80,8 +106,8 @@
queryParams
:
{
pageNum
:
1
,
pageSize
:
10
,
p
umpId
:
null
,
p
umpName
:
null
,
s
umpId
:
null
,
s
umpName
:
null
,
motorCurrent
:
null
,
motorBearingTemp
:
null
,
pumpBearingTemp
:
null
,
...
...
@@ -99,16 +125,16 @@
};
},
created
()
{
draDeviceName
({
typeId
:
1
}).
then
(
res
=>
{
draDeviceName
({
typeId
:
2
}).
then
(
res
=>
{
this
.
devList
=
res
.
data
;
})
this
.
getList
();
},
methods
:
{
/** 查询
水泵
历史信息列表 */
/** 查询
设备
历史信息列表 */
getList
()
{
this
.
loading
=
true
;
listHistory
(
this
.
addDateRange
(
this
.
queryParams
,
this
.
dateRange
)).
then
(
response
=>
{
list
SumpAlarm
History
(
this
.
addDateRange
(
this
.
queryParams
,
this
.
dateRange
)).
then
(
response
=>
{
this
.
historyList
=
response
.
rows
;
this
.
total
=
response
.
total
;
this
.
loading
=
false
;
...
...
@@ -123,14 +149,8 @@
reset
()
{
this
.
form
=
{
id
:
null
,
pumpId
:
null
,
pumpName
:
null
,
motorCurrent
:
null
,
motorBearingTemp
:
null
,
pumpBearingTemp
:
null
,
pumpFlow
:
null
,
drainagePressure
:
null
,
monitoringTime
:
null
delAlarmResion
:
null
,
time
:
null
,
};
this
.
resetForm
(
"
form
"
);
},
...
...
@@ -155,24 +175,25 @@
handleAdd
()
{
this
.
reset
();
this
.
open
=
true
;
this
.
title
=
"
添加
水泵
历史信息
"
;
this
.
title
=
"
添加
设备
历史信息
"
;
},
/** 修改按钮操作 */
handleUpdate
(
row
)
{
this
.
reset
();
const
id
=
row
.
id
||
this
.
ids
getHistory
(
id
).
then
(
response
=>
{
this
.
form
=
response
.
data
;
this
.
open
=
true
;
this
.
title
=
"
修改水泵历史信息
"
;
});
this
.
form
.
id
=
row
.
id
;
this
.
open
=
true
;
// getHistory(id).then(response => {
// this.form = response.data;
// this.open = true;
// this.title = "修改设备历史信息";
// });
},
/** 提交按钮 */
submitForm
()
{
this
.
$refs
[
"
form
"
].
validate
(
valid
=>
{
if
(
valid
)
{
if
(
this
.
form
.
id
!=
null
)
{
update
History
(
this
.
form
).
then
(
response
=>
{
update
WarterPumpAlarmHis
(
this
.
form
).
then
(
response
=>
{
this
.
$modal
.
msgSuccess
(
"
修改成功
"
);
this
.
open
=
false
;
this
.
getList
();
...
...
@@ -190,7 +211,7 @@
/** 删除按钮操作 */
handleDelete
(
row
)
{
const
ids
=
row
.
id
||
this
.
ids
;
this
.
$modal
.
confirm
(
'
是否确认删除
水泵
历史信息编号为"
'
+
ids
+
'
"的数据项?
'
).
then
(
function
()
{
this
.
$modal
.
confirm
(
'
是否确认删除
设备
历史信息编号为"
'
+
ids
+
'
"的数据项?
'
).
then
(
function
()
{
return
delHistory
(
ids
);
}).
then
(()
=>
{
this
.
getList
();
...
...
src/views/drainage/waterLevelHis/index.vue
0 → 100644
View file @
a9402174
<
template
>
<div
class=
"app-container"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"68px"
>
<el-form-item
label=
""
prop=
"sumpName"
>
<el-select
v-model=
"queryParams.sumpName"
placeholder=
"设备名称"
clearable
>
<el-option
v-for=
"dict in devList"
:key=
"dict.value"
:label=
"dict.name"
:value=
"dict.name"
/>
</el-select>
</el-form-item>
<el-form-item
label=
""
>
<el-date-picker
v-model=
"dateRange"
style=
"width: 240px"
value-format=
"yyyy-MM-dd"
type=
"daterange"
range-separator=
"-"
start-placeholder=
"开始日期"
end-placeholder=
"结束日期"
></el-date-picker>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
icon=
"el-icon-search"
size=
"mini"
@
click=
"handleQuery"
>
搜索
</el-button>
<el-button
icon=
"el-icon-refresh"
size=
"mini"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form>
<el-table
v-loading=
"loading"
:data=
"historyList"
>
<el-table-column
label=
"设备名称"
align=
"center"
prop=
"sumpName"
/>
<el-table-column
label=
"设备编号"
align=
"center"
prop=
"sumpId"
/>
<el-table-column
label=
"设备安装位置"
align=
"center"
prop=
"installationLocation"
/>
<el-table-column
label=
"液位高度(m)"
align=
"center"
prop=
"heghtThreshold"
/>
<el-table-column
label=
"监测时间"
align=
"center"
prop=
"time"
width=
"180"
>
<template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
time
)
}}
</span>
</
template
>
</el-table-column>
</el-table>
<pagination
v-show=
"total>0"
:total=
"total"
:page.sync=
"queryParams.pageNum"
:limit.sync=
"queryParams.pageSize"
@
pagination=
"getList"
/>
</div>
</template>
<
script
>
import
{
getHistory
,
listSumpHistory
}
from
"
@/api/tyler/waterLevelHis
"
;
import
{
draDeviceName
}
from
"
@/api/tyler/common
"
;
export
default
{
name
:
"
History
"
,
data
()
{
return
{
// 根路径
baseURL
:
process
.
env
.
VUE_APP_BASE_API
,
// 遮罩层
loading
:
true
,
// 选中数组
ids
:
[],
// 非单个禁用
single
:
true
,
// 非多个禁用
multiple
:
true
,
// 显示搜索条件
showSearch
:
true
,
// 总条数
total
:
0
,
// 设备历史信息表格数据
historyList
:
[],
// 弹出层标题
title
:
""
,
// 是否显示弹出层
open
:
false
,
// 查询参数
queryParams
:
{
pageNum
:
1
,
pageSize
:
10
,
sumpName
:
null
,
},
// 表单参数
form
:
{},
// 表单校验
rules
:
{},
// 日期范围
dateRange
:
[],
devList
:
[],
};
},
created
()
{
draDeviceName
({
typeId
:
2
}).
then
(
res
=>
{
this
.
devList
=
res
.
data
;
})
this
.
getList
();
},
methods
:
{
/** 查询设备历史信息列表 */
getList
()
{
this
.
loading
=
true
;
listSumpHistory
(
this
.
addDateRange
(
this
.
queryParams
,
this
.
dateRange
)).
then
(
response
=>
{
this
.
historyList
=
response
.
rows
;
this
.
total
=
response
.
total
;
this
.
loading
=
false
;
});
},
/** 搜索按钮操作 */
handleQuery
()
{
this
.
queryParams
.
pageNum
=
1
;
this
.
getList
();
},
/** 重置按钮操作 */
resetQuery
()
{
this
.
dateRange
=
[]
this
.
resetForm
(
"
queryForm
"
);
this
.
handleQuery
();
},
}
};
</
script
>
src/views/drainage/waterPumpSwitchHis/index.vue
View file @
a9402174
<
template
>
<div
class=
"app-container"
>
暂无
</div>
</
template
>
\ 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