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
d012103a
Commit
d012103a
authored
Aug 14, 2024
by
裴文涛
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
14号解决Bug第一次
parent
eefb9eb1
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
88 additions
and
38 deletions
+88
-38
AnnualParamPage.vue
src/views/SchedulingPage/AnnualParamPage.vue
+71
-9
PhenomenonPage.vue
src/views/SchedulingPage/PhenomenonPage.vue
+2
-7
WeatherManagePage.vue
src/views/SchedulingPage/WeatherManagePage.vue
+4
-3
WindManagePage.vue
src/views/SchedulingPage/WindManagePage.vue
+8
-1
BindWindow.vue
src/views/SchedulingPage/weatherManageSub/BindWindow.vue
+3
-18
No files found.
src/views/SchedulingPage/AnnualParamPage.vue
View file @
d012103a
<
script
setup
>
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
{
computed
,
onBeforeMount
,
onMounted
,
reactive
,
ref
}
from
"vue"
;
import
{
getAnnualParam
,
alterAnnualParam
,
addAnnualParam
,
deleteAnnualParam
,
getOrganizationStructureInterface
}
from
'@/api/scheduling.js'
import
{
ElMessage
,
ElMessageBox
}
from
"element-plus"
;
import
{
vFloatNumber
}
from
"@/utils/directives.js"
;
...
...
@@ -38,6 +43,8 @@ const selectYearValue = computed(() => {
return
(
currentYear
.
value
-
1
)
+
"年-"
+
currentYear
.
value
+
"年"
}
})
const
organizationStructure
=
ref
([])
// 组织结构数据
const
supplyData
=
ref
([])
// 供热站数据
function
handleEdit
(
val
)
{
currentYear
.
value
=
new
Date
().
getFullYear
()
...
...
@@ -92,7 +99,13 @@ function handleSearch() {
data
.
value
=
dataBackup
.
value
.
filter
(
item
=>
item
.
year
.
includes
(
searchKey
.
value
))
}
}
// 处理查询
function
onSubmit
()
{
function
onReviseSubmit
()
{
if
(
reviseForm
.
value
.
hasOwnProperty
(
'supplyName'
)){
delete
reviseForm
.
value
.
supplyName
}
if
(
reviseForm
.
value
.
year
.
length
>
4
){
reviseForm
.
value
.
year
=
reviseForm
.
value
.
year
.
slice
(
6
,
10
)
}
alterAnnualParam
(
reviseForm
.
value
).
then
(
res
=>
{
if
(
res
.
success
)
{
getData
()
...
...
@@ -115,14 +128,13 @@ function onSubmit() {
})
}
// 提交修改
function
onAddSubmit
()
{
// 提交新增
addForm
.
value
.
year
=
addForm
.
value
.
year
.
slice
(
6
,
10
)
data
.
value
.
forEach
((
item
,
index
,
array
)
=>
{
if
(
item
.
energyType
===
addForm
.
energyType
&&
item
.
year
===
addForm
.
year
)
{
alert
(
"该类型年度已存在"
)
return
}
})
console
.
log
(
'>>>>>>>>=='
,
addForm
.
value
)
console
.
log
(
'========>>>>'
,
addForm
.
value
.
year
)
addAnnualParam
(
addForm
.
value
).
then
(
res
=>
{
if
(
res
.
success
)
{
getData
()
...
...
@@ -149,8 +161,9 @@ function handleClose() {
addWindowOpen
.
value
=
false
resetInput
()
}
// 关闭弹窗
on
Mounted
(()
=>
{
on
BeforeMount
(()
=>
{
getData
()
getOrganizationStructure
()
})
function
getData
()
{
...
...
@@ -206,7 +219,35 @@ function customSort(a, b) {
}
return
valA
-
valB
}
function
getSupply
()
{
supplyData
.
value
=
[]
organizationStructure
.
value
[
0
].
serviceCenterList
.
forEach
(
fir_item
=>
{
fir_item
.
supplyList
.
forEach
(
sec_item
=>
{
let
temp
=
{
supplyId
:
sec_item
.
supplyId
,
supplyName
:
sec_item
.
supplyName
,
}
supplyData
.
value
.
push
({...
temp
})
})
})
}
// 根据组织结构获取供热站数据
function
getOrganizationStructure
()
{
getOrganizationStructureInterface
().
then
(
res
=>
{
organizationStructure
.
value
=
res
.
data
getSupply
()
}).
catch
(
err
=>
{
ElMessage
.
error
(
'接口异常,获取数据失败.'
)
})
}
// 获取组织结构
function
showSupplyName
(
id
){
let
supplyName
=
""
supplyData
.
value
.
forEach
(
item
=>
{
if
(
item
.
supplyId
===
id
){
supplyName
=
item
.
supplyName
}
})
return
supplyName
}
</
script
>
<
template
>
...
...
@@ -227,6 +268,11 @@ function customSort(a, b) {
:header-cell-class-name="tableHeaderClass" :row-class-name="tableBodyClass" style="width: 100%">
<el-table-column
label=
"序号"
type=
"index"
align=
"center"
width=
"60"
/>
<el-table-column
label=
"节能类型"
sortable
:sort-method=
"customSort"
prop=
"energyType"
/>
<el-table-column
label=
"供热站名称"
>
<template
#
default=
"scope"
>
{{
showSupplyName
(
scope
.
row
.
supplyId
)
}}
</
template
>
</el-table-column>
<el-table-column
label=
"年度"
sortable
prop=
"year"
/>
<el-table-column
label=
"热指标(W/m²)"
prop=
"standard"
/>
<el-table-column
label=
"度日数标定值"
prop=
"degreeStandard"
/>
...
...
@@ -262,6 +308,14 @@ function customSort(a, b) {
</el-select>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"8"
col-label
>
供热站:
</el-col>
<el-col
:span=
"16"
col-value
>
<el-select
placeholder=
"请选择供热站"
size=
"small"
v-model=
"reviseForm.supplyId"
style=
"width: 370px"
>
<el-option
v-for=
"item in supplyData"
:key=
"item.supplyId"
:value=
"item.supplyId"
:label=
"item.supplyName"
/>
</el-select>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"8"
col-label
>
热指标(W/m²):
</el-col>
<el-col
:span=
"16"
col-value
>
...
...
@@ -295,7 +349,7 @@ function customSort(a, b) {
</
template
>
<
template
#
footer
>
<div
class=
"dialog-footer"
>
<el-button
type=
"primary"
@
click=
"onSubmit"
>
保存
</el-button>
<el-button
type=
"primary"
@
click=
"on
Revise
Submit"
>
保存
</el-button>
<el-button
type=
"primary"
@
click=
"handleClose"
>
关闭
</el-button>
</div>
</
template
>
...
...
@@ -318,6 +372,14 @@ function customSort(a, b) {
</el-select>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"8"
col-label
>
供热站:
</el-col>
<el-col
:span=
"16"
col-value
>
<el-select
placeholder=
"请选择供热站"
size=
"small"
v-model=
"addForm.supplyId"
style=
"width: 370px"
>
<el-option
v-for=
"item in supplyData"
:key=
"item.supplyId"
:value=
"item.supplyId"
:label=
"item.supplyName"
/>
</el-select>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"8"
col-label
>
热指标(W/m²):
</el-col>
<el-col
:span=
"16"
col-value
>
...
...
src/views/SchedulingPage/PhenomenonPage.vue
View file @
d012103a
...
...
@@ -156,7 +156,7 @@ function getData(){
})
}
function
customSort
(
a
,
b
){
return
a
.
phenomenonType
-
b
.
phenomenonType
return
b
.
phenomenonType
-
a
.
phenomenonType
}
</
script
>
<
template
>
...
...
@@ -178,6 +178,7 @@ function customSort(a,b){
stripe
border
style=
"width: 100%"
:default-sort=
"
{ prop: 'phenomenonName', order: 'descending' }"
:header-cell-class-name="tableHeaderClass"
:row-class-name="tableBodyClass">
<el-table-column
type=
"index"
label=
"序号"
align=
"center"
width=
"100"
/>
...
...
@@ -201,12 +202,6 @@ function customSort(a,b){
width=
"700px"
:before-close=
"handleClose"
>
<
template
#
default
>
<!--
<el-row
first
>
<el-col
:span=
"8"
col-label
class=
"energy-type-class"
>
名称:
</el-col>
<el-col
:span=
"16"
col-value
>
<el-input
placeholder=
""
size=
"small"
v-model=
"reviseForm.phenomenonName"
style=
"width: 370px"
/>
</el-col>
</el-row>
-->
<el-row>
<el-col
:span=
"8"
col-label
class=
"energy-type-class"
>
名称:
</el-col>
<el-col
:span=
"16"
col-value
>
...
...
src/views/SchedulingPage/WeatherManagePage.vue
View file @
d012103a
...
...
@@ -147,12 +147,12 @@ function handleAdd(val){
console
.
log
(
"新增数据"
,
val
)
alterWeatherMagData
(
val
).
then
(
res
=>
{
if
(
res
.
success
){
getData
()
addWindowOpen
.
value
=
false
ElMessage
({
message
:
'新增成功.'
,
message
:
res
.
message
,
type
:
'success'
,
})
getData
()
addWindowOpen
.
value
=
false
}
else
{
ElMessage
({
message
:
res
.
message
,
...
...
@@ -255,6 +255,7 @@ function resetSearch(){
border
style=
"width: 100%"
height=
"720px"
:default-sort=
"
{ prop: 'operateTime', order: 'descending' }"
:header-cell-class-name="tableHeaderClass"
:row-class-name="tableBodyClass">
<el-table-column
prop=
"allowPagingId"
label=
"编号"
align=
"center"
width=
"60"
/>
...
...
src/views/SchedulingPage/WindManagePage.vue
View file @
d012103a
...
...
@@ -144,7 +144,10 @@ function resetInput() {
windDesc
:
""
,
};
}
function
resetSearch
(){
searchKey
.
value
=
""
;
getData
()
}
function
customSort
(
a
,
b
)
{
return
a
.
windLevel
-
b
.
windLevel
;
}
...
...
@@ -176,6 +179,9 @@ function customSort(a, b) {
<el-button
type=
"primary"
@
click=
"add"
class=
"add-search-btn"
>
新增
</el-button
>
<el-button
type=
"primary"
@
click=
"resetSearch"
class=
"add-search-btn"
>
重置
</el-button
>
</div>
<div
class=
"table-wrapper"
>
<el-table
...
...
@@ -183,6 +189,7 @@ function customSort(a, b) {
stripe
border
style=
"width: 100%"
:default-sort=
"
{prop: 'windLevel', order: 'descending'}"
:header-cell-class-name="tableHeaderClass"
:row-class-name="tableBodyClass"
>
...
...
src/views/SchedulingPage/weatherManageSub/BindWindow.vue
View file @
d012103a
...
...
@@ -3,14 +3,11 @@ import {
ref
,
defineProps
,
defineEmits
,
watchEffect
,
watch
,
watchEffect
}
from
"vue"
;
import
{
getTransferInterface
,
getWeatherMagData
}
from
"@/api/scheduling.js"
import
{
ElLoading
}
from
'element-plus'
import
store
from
"@/store/index.js"
;
import
cloneDeep
from
'lodash/cloneDeep'
import
http
from
"@/api/http.js"
;
import
{
ElMessage
}
from
"element-plus"
;
const
props
=
defineProps
({
open
:
{
...
...
@@ -27,18 +24,7 @@ const props = defineProps({
type
:
Array
,
default
:
[],
required
:
true
},
transfer
:
{
type
:
Array
,
default
:
[],
required
:
true
},
allWeatherMagData
:
{
type
:
Array
,
default
:
[],
required
:
true
}
})
}})
const
emit
=
defineEmits
({
onCancel
:
null
,
onConfirm
:
({})
=>
{
...
...
@@ -50,7 +36,6 @@ const supplyData = ref([]) // 供热站数据
const
transferData
=
ref
([])
// 换热站数据
const
selectedTransfer
=
ref
([])
// 被本气象干预方案选中的换热站
let
optional
=
''
// 可以选换热站的供热站
let
isAlreadyBind
=
false
let
loadingInstance
=
null
const
inputStyle
=
{
color
:
'black'
,
...
...
@@ -152,7 +137,7 @@ function selectChange(val) {
* @param val
*/
function
checkboxChange
(
val
)
{
console
.
log
(
'checkboxChange====>>>===>>>'
,
val
)
//
console.log('checkboxChange====>>>===>>>', val)
}
</
script
>
<
template
>
...
...
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