Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
web-project
Project
Project
Details
Activity
Releases
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
海康威视
web-project
Commits
6dac013d
Commit
6dac013d
authored
Aug 08, 2024
by
xuke
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
ssh://gitlab.91isoft.com:10022/hikvision/web-project
parents
2b6dd655
02157317
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
146 additions
and
54 deletions
+146
-54
AnnualParamPage.vue
src/views/SchedulingPage/AnnualParamPage.vue
+27
-1
PhenomenonPage.vue
src/views/SchedulingPage/PhenomenonPage.vue
+29
-2
WeatherManagePage.vue
src/views/SchedulingPage/WeatherManagePage.vue
+28
-12
WindManagePage.vue
src/views/SchedulingPage/WindManagePage.vue
+28
-2
AddWindow.vue
src/views/SchedulingPage/weatherManageSub/AddWindow.vue
+21
-34
BindWindow.vue
src/views/SchedulingPage/weatherManageSub/BindWindow.vue
+7
-2
ReviseWindow.vue
src/views/SchedulingPage/weatherManageSub/ReviseWindow.vue
+6
-1
No files found.
src/views/SchedulingPage/AnnualParamPage.vue
View file @
6dac013d
...
...
@@ -2,7 +2,7 @@
import
{
computed
,
onMounted
,
reactive
,
ref
}
from
"vue"
;
import
{
zhCn
}
from
"element-plus/es/locale/index"
;
import
{
getAnnualParam
,
alterAnnualParam
,
addAnnualParam
,
deleteAnnualParam
}
from
'@/api/scheduling.js'
import
{
ElMessageBox
}
from
"element-plus"
;
import
{
ElMessage
,
ElMessage
Box
}
from
"element-plus"
;
const
data
=
ref
()
const
dataBackup
=
ref
([])
...
...
@@ -56,9 +56,17 @@ function handleDelete(val) {
deleteAnnualParam
(
val
.
paramId
).
then
(
res
=>
{
if
(
res
.
success
)
{
getData
()
ElMessage
({
message
:
'删除成功.'
,
type
:
'success'
,
})
}
})
}).
catch
(
err
=>
{
ElMessage
({
message
:
'删除失败.'
,
type
:
'error'
,
})
})
}
// 处理删除
function
handleAdd
()
{
...
...
@@ -78,7 +86,16 @@ function onSubmit() {
if
(
res
.
success
)
{
getData
()
handleClose
()
ElMessage
({
message
:
'修改成功.'
,
type
:
'success'
,
})
}
}).
catch
(
err
=>
{
ElMessage
({
message
:
'修改失败.'
,
type
:
'error'
,
})
})
}
// 提交修改
function
onAddSubmit
()
{
// 提交新增
...
...
@@ -91,6 +108,15 @@ function onAddSubmit() { // 提交新增
addAnnualParam
(
addForm
.
value
).
then
(
res
=>
{
getData
()
handleClose
()
ElMessage
({
message
:
'新增成功.'
,
type
:
'success'
,
})
}).
catch
(
err
=>
{
ElMessage
({
message
:
'新增失败.'
,
type
:
'error'
,
})
})
}
// 提交新增
function
handleClose
()
{
...
...
src/views/SchedulingPage/PhenomenonPage.vue
View file @
6dac013d
<
script
setup
>
import
{
onMounted
,
ref
}
from
"vue"
;
import
{
ElMessageBox
}
from
"element-plus"
;
import
{
ElMessage
,
ElMessage
Box
}
from
"element-plus"
;
import
{
getPhenomenon
,
addPhenomenon
,
alterPhenomenon
,
deletePhenomenon
}
from
"@/api/scheduling.js"
const
data
=
ref
()
...
...
@@ -44,8 +44,17 @@ function omit(val){
).
then
(()
=>
{
deletePhenomenon
(
id
).
then
(
res
=>
{
getData
()
ElMessage
({
message
:
'删除成功.'
,
type
:
'success'
,
})
})
}).
catch
(
err
=>
{})
}).
catch
(
err
=>
{
ElMessage
({
message
:
'删除失败.'
,
type
:
'error'
,
})
})
}
// 删除按钮单击事件
function
handleClose
(){
reviseWindowOpen
.
value
=
false
...
...
@@ -56,12 +65,30 @@ function onReviseSubmit(){
alterPhenomenon
(
reviseForm
.
value
).
then
(
res
=>
{
getData
()
reviseWindowOpen
.
value
=
false
ElMessage
({
message
:
'修改成功.'
,
type
:
'success'
,
})
}).
catch
(
err
=>
{
ElMessage
({
message
:
'修改失败.'
,
type
:
'error'
,
})
})
}
// 修改表单提交
function
onAddSubmit
(){
addPhenomenon
(
addForm
.
value
).
then
(
res
=>
{
handleClose
()
getData
()
ElMessage
({
message
:
'新增成功.'
,
type
:
'success'
,
})
}).
catch
(
err
=>
{
ElMessage
({
message
:
'新增失败.'
,
type
:
'error'
,
})
})
}
// 新增表单提交
function
resetInput
(){
...
...
src/views/SchedulingPage/WeatherManagePage.vue
View file @
6dac013d
...
...
@@ -4,35 +4,43 @@ import ReviseWindow from "./weatherManageSub/ReviseWindow.vue";
import
BindWindow
from
"./weatherManageSub/BindWindow.vue"
;
import
{
getWeatherMagData
,
alterWeatherMagData
,
getTransfer
}
from
'@/api/scheduling.js'
import
AddWindow
from
"./weatherManageSub/AddWindow.vue"
;
import
{
ElMessage
}
from
"element-plus"
;
const
data
=
ref
()
const
reviseWindowOpen
=
ref
(
false
)
// 修改按钮弹窗状态
const
bindWindowOpen
=
ref
(
false
)
// 绑定按钮弹窗状态
const
addWindowOpen
=
ref
(
false
)
// 新增按钮弹窗状态
const
dependentSub
=
ref
({})
// 修改和绑定弹窗数据依赖
const
tableHeaderClass
=
data
=>
{
// 表头样式
return
'table-header-class'
}
const
tableBodyClass
=
data
=>
{
// 表体样式
return
'table-body-class'
}
const
revise
=
(
row
)
=>
{
// 修改按钮单击事件
dependentSub
.
value
=
row
reviseWindowOpen
.
value
=
true
}
const
bind
=
(
row
)
=>
{
// 绑定按钮单击事件
// getTransfer(id).then(res=>{
// // console.log(res)
// })
dependentSub
.
value
=
row
bindWindowOpen
.
value
=
true
}
const
confirmRevise
=
val
=>
{
// 修改弹窗确认按钮事件
alterWeatherMagData
(
val
).
then
(
res
=>
{
getData
()
reviseWindowOpen
.
value
=
false
})
console
.
log
(
'修改数据'
,
val
)
// alterWeatherMagData(val).then(res=>{
// getData()
// reviseWindowOpen.value = false
// ElMessage({
// message: '修改成功.',
// type: 'success',
// })
// }).catch(err=>{
// ElMessage({
// message: '修改失败.',
// type: 'error',
// })
// })
}
const
confirmBind
=
val
=>
{
bindWindowOpen
.
value
=
false
...
...
@@ -43,15 +51,26 @@ onMounted(() => {
function
getData
()
{
getWeatherMagData
().
then
(
res
=>
{
data
.
value
=
res
.
data
console
.
log
(
"所有数据"
,
data
.
value
)
})
}
function
handleAddWinOpenClose
(){
addWindowOpen
.
value
=
false
}
function
handleAdd
(
val
){
console
.
log
(
"新增数据"
,
val
)
alterWeatherMagData
(
val
).
then
(
res
=>
{
getData
()
addWindowOpen
.
value
=
false
ElMessage
({
message
:
'新增成功.'
,
type
:
'success'
,
})
}).
catch
(
err
=>
{
ElMessage
({
message
:
'新增失败.'
,
type
:
'error'
,
})
})
}
// 新增数据提交
</
script
>
...
...
@@ -88,13 +107,10 @@ function handleAdd(val){
<el-table-column
prop=
"diffPercentage"
label=
"自动偏差百分比"
width=
"170"
/>
<el-table-column
prop=
"timeoutMin"
label=
"验证时间"
width=
"100"
/>
<el-table-column
prop=
"tempRegulation"
label=
"调节温度"
width=
"100"
/>
<el-table-column
prop=
"sort"
label=
"排序"
width=
"60"
/>
<el-table-column
prop=
"sort"
sortable
label=
"排序"
width=
"60"
/>
<el-table-column
label=
"操作"
width=
"200"
>
<template
#
default=
"scope"
>
<div
class=
"table-operate-column"
>
<!--
<el-link
:underline=
"false"
@
click=
"revise(scope.row)"
type=
"primary"
>
修改
</el-link>
-->
<!--
<el-link
:underline=
"false"
@
click=
"bind(scope.row)"
type=
"primary"
>
绑定换热站
</el-link>
-->
<!--
<el-link
:underline=
"false"
type=
"primary"
>
详情
</el-link>
-->
<el-button
link
@
click=
"revise(scope.row)"
type=
"primary"
>
修改
</el-button>
<el-button
link
@
click=
"bind(scope.row)"
type=
"primary"
>
绑定换热站
</el-button>
<el-button
link
type=
"primary"
>
详情
</el-button>
...
...
src/views/SchedulingPage/WindManagePage.vue
View file @
6dac013d
<
script
setup
>
import
{
onMounted
,
ref
,
watch
,
watchEffect
}
from
"vue"
;
import
{
ElMessageBox
}
from
"element-plus"
;
import
{
ElMessage
,
ElMessage
Box
}
from
"element-plus"
;
import
{
getWind
,
deleteWind
,
alterWind
,
addWind
}
from
"@/api/scheduling.js"
const
data
=
ref
()
...
...
@@ -37,8 +37,16 @@ function omit(val) {
).
then
(()
=>
{
deleteWind
(
id
).
then
(
res
=>
{
getData
()
ElMessage
({
message
:
'删除成功.'
,
type
:
'success'
,
})
})
}).
catch
(
err
=>
{
ElMessage
({
message
:
'删除失败.'
,
type
:
'error'
,
})
})
}
// 删除按钮单击事件
function
search
()
{
...
...
@@ -57,13 +65,31 @@ function onReviseSubmit() {
alterWind
(
reviseForm
.
value
).
then
(
res
=>
{
getData
()
handleClose
()
ElMessage
({
message
:
'修改成功.'
,
type
:
'success'
,
})
}).
catch
(
err
=>
{
ElMessage
({
message
:
'修改失败.'
,
type
:
'error'
,
})
})
}
// 修改表单提交
function
onAddSubmit
()
{
addWind
(
addForm
.
value
).
then
(
res
=>
{
getData
()
handleClose
()
})
ElMessage
({
message
:
'新增成功.'
,
type
:
'success'
,
})
}).
catch
(
err
=>
[
ElMessage
({
message
:
'新增失败.'
,
type
:
'error'
,
})
])
}
// 新增表单提交
onMounted
(()
=>
{
...
...
src/views/SchedulingPage/weatherManageSub/AddWindow.vue
View file @
6dac013d
...
...
@@ -31,45 +31,13 @@ const inputStyle = {
height
:
'24px'
}
function
handleClose
()
{
addData
.
value
=
{
customizeName
:
''
,
// 自定义名称
isFixed
:
false
,
// 干预模式:true 固定模式,false 气象仪模式
temperature
:
''
,
// 温度
wind
:
''
,
// 风速
illumination
:
''
,
// 光照
sort
:
''
,
// 排序
isAuto
:
false
,
// 是否自动模式
diffPercentage
:
''
,
// 自动偏差百分比
timeoutMin
:
''
,
// 自动验证循环时间
tempRegulation
:
''
,
// 自动调节温度
operateTime
:
""
,
// 操作时间
description
:
null
,
// 排序字段,全为Null
updateNullField
:
""
,
// 无用,但不为空
isActive
:
false
,
// 是否启用
supplyId
:
''
,
// 供热站编号
}
resetInput
()
emit
(
'onCancel'
)
}
function
handleConfirm
()
{
addData
.
value
.
operateTime
=
getCurrentDateTime
()
emit
(
'onConfirm'
,
addData
.
value
)
addData
.
value
=
{
customizeName
:
''
,
// 自定义名称
isFixed
:
false
,
// 干预模式:true 固定模式,false 气象仪模式
temperature
:
''
,
// 温度
wind
:
''
,
// 风速
illumination
:
''
,
// 光照
sort
:
''
,
// 排序
isAuto
:
false
,
// 是否自动模式
diffPercentage
:
''
,
// 自动偏差百分比
timeoutMin
:
''
,
// 自动验证循环时间
tempRegulation
:
''
,
// 自动调节温度
operateTime
:
""
,
// 操作时间
description
:
null
,
// 排序字段,全为Null
updateNullField
:
""
,
// 无用,但不为空
isActive
:
false
,
// 是否启用
supplyId
:
''
,
// 供热站编号
}
resetInput
()
}
function
getCurrentDateTime
()
{
const
now
=
new
Date
();
...
...
@@ -82,6 +50,25 @@ function getCurrentDateTime() {
return
`
${
year
}
-
${
month
}
-
${
day
}
${
hours
}
:
${
minutes
}
:
${
seconds
}
`
;
}
// 生成时间
function
resetInput
(){
addData
.
value
=
{
transfers
:[],
// 换热站
customizeName
:
''
,
// 自定义名称
diffPercentage
:
''
,
// 自动偏差百分比
illumination
:
''
,
// 光照
isAuto
:
false
,
// 是否自动模式
isFixed
:
false
,
// 干预模式:true 固定模式,false 气象仪模式
operateTime
:
""
,
// 操作时间
sort
:
''
,
// 排序
tempRegulation
:
''
,
// 自动调节温度
temperature
:
''
,
// 温度
timeoutMin
:
''
,
// 自动验证循环时间
wind
:
''
,
// 风速
description
:
null
,
// 排序字段,全为Null
updateNullFields
:
""
,
// 无用,但不为空
isActive
:
false
,
// 是否启用
}
}
</
script
>
<
template
>
...
...
src/views/SchedulingPage/weatherManageSub/BindWindow.vue
View file @
6dac013d
<
script
setup
>
import
{
ref
,
defineProps
,
defineEmits
,
watchEffect
}
from
"vue"
;
import
{
ref
,
defineProps
,
defineEmits
,
watchEffect
,
onMounted
}
from
"vue"
;
import
http
from
"@/api/http.js"
;
import
store
from
"@/store/index.js"
;
const
props
=
defineProps
({
open
:
{
...
...
@@ -52,7 +54,10 @@ const heatExchangeList = ref([
'开元里'
,
'振业里'
])
// 换热站列表
onMounted
(()
=>
{
// let result = store.getters.getEnterprise()
// console.log("绑定窗口挂载",result)
})
const
onSubmit
=
()
=>
{
emit
(
'onConfirm'
,
bindData
)
}
// 点击保存按钮
...
...
src/views/SchedulingPage/weatherManageSub/ReviseWindow.vue
View file @
6dac013d
...
...
@@ -39,6 +39,10 @@ const switchingisAuto = computed({
}
}
})
// 可写计算属性,手动、自动模式切换
function
onOpen
(){
console
.
log
(
'props.data数据'
,
props
.
data
)
console
.
log
(
'修改弹窗接收到的数据'
,
reviseData
.
value
)
}
</
script
>
<
template
>
...
...
@@ -46,7 +50,8 @@ const switchingisAuto = computed({
v-model=
"props.open"
width=
"1000px"
title=
"自定义修改"
@
close=
"emit('onCancel')"
>
@
close=
"emit('onCancel')"
@
open=
"onOpen"
>
<template
#
default
>
<div
class=
"dialog-content"
>
<el-row
style=
"border-top: #a6c3e9 1px solid"
>
...
...
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