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
76205dae
Commit
76205dae
authored
Aug 10, 2024
by
裴文涛
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
删除接口调整
parent
f9b76a0e
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
41 additions
and
29 deletions
+41
-29
scheduling.js
src/api/scheduling.js
+3
-3
AnnualParamPage.vue
src/views/SchedulingPage/AnnualParamPage.vue
+17
-9
PhenomenonPage.vue
src/views/SchedulingPage/PhenomenonPage.vue
+10
-8
WindManagePage.vue
src/views/SchedulingPage/WindManagePage.vue
+11
-9
No files found.
src/api/scheduling.js
View file @
76205dae
...
@@ -100,7 +100,7 @@ export const addAnnualParam = params => { // 新增年度参数
...
@@ -100,7 +100,7 @@ export const addAnnualParam = params => { // 新增年度参数
export
const
deleteAnnualParam
=
params
=>
{
// 删除年度参数
export
const
deleteAnnualParam
=
params
=>
{
// 删除年度参数
// console.log("地址:",`/api/Scheduling/BizHeatSet/Delete?Id=${params}`)
// console.log("地址:",`/api/Scheduling/BizHeatSet/Delete?Id=${params}`)
return
http
.
post
(
`/api/Scheduling/BizHeatSet/Delete
?Id=
${
params
}
`
)
return
http
.
post
(
`/api/Scheduling/BizHeatSet/Delete
`
,
params
)
}
}
export
const
getPhenomenon
=
()
=>
{
// 获取数据列表————天气工况
export
const
getPhenomenon
=
()
=>
{
// 获取数据列表————天气工况
...
@@ -115,7 +115,7 @@ export const alterPhenomenon = params => { // 修改数据————天气工
...
@@ -115,7 +115,7 @@ export const alterPhenomenon = params => { // 修改数据————天气工
}
}
export
const
deletePhenomenon
=
params
=>
{
// 删除数据————天气工况
export
const
deletePhenomenon
=
params
=>
{
// 删除数据————天气工况
return
http
.
post
(
`/api/Scheduling/WeatherCondition/Delete
?Id=
${
params
}
`
)
return
http
.
post
(
`/api/Scheduling/WeatherCondition/Delete
`
,
params
)
}
}
export
const
getWind
=
()
=>
{
// 获取数据列表————风力配置
export
const
getWind
=
()
=>
{
// 获取数据列表————风力配置
...
@@ -131,5 +131,5 @@ export const alterWind = params => { // 修改数据————风力配置
...
@@ -131,5 +131,5 @@ export const alterWind = params => { // 修改数据————风力配置
}
}
export
const
deleteWind
=
params
=>
{
// 删除数据————风力配置
export
const
deleteWind
=
params
=>
{
// 删除数据————风力配置
return
http
.
post
(
`/api/Scheduling/WindConfiguration/Delete
?Id=
${
params
}
`
)
return
http
.
post
(
`/api/Scheduling/WindConfiguration/Delete
`
,
params
)
}
}
src/views/SchedulingPage/AnnualParamPage.vue
View file @
76205dae
...
@@ -54,7 +54,10 @@ function handleDelete(val) {
...
@@ -54,7 +54,10 @@ function handleDelete(val) {
type
:
'warning'
type
:
'warning'
}
}
).
then
(()
=>
{
).
then
(()
=>
{
deleteAnnualParam
(
val
.
paramId
).
then
(
res
=>
{
let
param
=
{
id
:
val
.
paramId
}
deleteAnnualParam
(
param
).
then
(
res
=>
{
if
(
res
.
success
)
{
if
(
res
.
success
)
{
getData
()
getData
()
ElMessage
({
ElMessage
({
...
@@ -62,12 +65,12 @@ function handleDelete(val) {
...
@@ -62,12 +65,12 @@ function handleDelete(val) {
type
:
'success'
,
type
:
'success'
,
})
})
}
}
})
})
.
catch
(
err
=>
{
}).
catch
(
err
=>
{
ElMessage
(
{
ElMessage
({
message
:
'删除失败.'
,
message
:
'删除失败.
'
,
type
:
'error
'
,
type
:
'error'
,
})
})
})
})
})
}
// 处理删除
}
// 处理删除
function
handleAdd
()
{
function
handleAdd
()
{
...
@@ -147,6 +150,10 @@ function resetInput() {
...
@@ -147,6 +150,10 @@ function resetInput() {
backWaterTemperature
:
''
backWaterTemperature
:
''
}
}
}
}
function
energyTypeSort
(){
return
[
'一步节能'
,
'二步节能'
,
'三步节能'
,
'四步节能'
,
'非节能'
]
}
// 节能类型排序自定义方法
</
script
>
</
script
>
<
template
>
<
template
>
...
@@ -166,12 +173,13 @@ function resetInput() {
...
@@ -166,12 +173,13 @@ function resetInput() {
:data=
"data"
:data=
"data"
border
border
stripe
stripe
:default-sort=
"
{prop: 'year', order: 'descending'}"
:header-cell-class-name="tableHeaderClass"
:header-cell-class-name="tableHeaderClass"
:row-class-name="tableBodyClass"
:row-class-name="tableBodyClass"
style="width: 100%">
style="width: 100%">
<el-table-column
label=
"序号"
type=
"index"
align=
"center"
width=
"60"
/>
<el-table-column
label=
"序号"
type=
"index"
align=
"center"
width=
"60"
/>
<el-table-column
label=
"节能类型"
prop=
"energyType"
/>
<el-table-column
label=
"节能类型"
sortable
:sort-method=
"energyTypeSort"
prop=
"energyType"
/>
<el-table-column
label=
"年度"
prop=
"year"
/>
<el-table-column
label=
"年度"
sortable
prop=
"year"
/>
<el-table-column
label=
"热指标(W/m²)"
prop=
"standard"
/>
<el-table-column
label=
"热指标(W/m²)"
prop=
"standard"
/>
<el-table-column
label=
"度日数标定值"
prop=
"degreeStandard"
/>
<el-table-column
label=
"度日数标定值"
prop=
"degreeStandard"
/>
<el-table-column
label=
"室内温度(℃)"
prop=
"indoorTemperature"
/>
<el-table-column
label=
"室内温度(℃)"
prop=
"indoorTemperature"
/>
...
...
src/views/SchedulingPage/PhenomenonPage.vue
View file @
76205dae
...
@@ -33,7 +33,9 @@ function search(){
...
@@ -33,7 +33,9 @@ function search(){
}
}
}
}
function
omit
(
val
){
function
omit
(
val
){
let
id
=
val
.
phenomenonId
let
param
=
{
id
:
val
.
phenomenonId
}
ElMessageBox
.
confirm
(
ElMessageBox
.
confirm
(
'点击确定后,该条数据将删除,是否继续?'
,
'点击确定后,该条数据将删除,是否继续?'
,
'Warning'
,
'Warning'
,
...
@@ -43,18 +45,18 @@ function omit(val){
...
@@ -43,18 +45,18 @@ function omit(val){
type
:
'warning'
type
:
'warning'
}
}
).
then
(()
=>
{
).
then
(()
=>
{
deletePhenomenon
(
id
).
then
(
res
=>
{
deletePhenomenon
(
param
).
then
(
res
=>
{
getData
()
getData
()
ElMessage
({
ElMessage
({
message
:
'删除成功.'
,
message
:
'删除成功.'
,
type
:
'success'
,
type
:
'success'
,
})
})
})
})
.
catch
(
err
=>
{
}).
catch
(
err
=>
{
ElMessage
(
{
ElMessage
({
message
:
'删除失败.'
,
message
:
'删除失败.
'
,
type
:
'error
'
,
type
:
'error'
,
})
})
})
})
})
}
// 删除按钮单击事件
}
// 删除按钮单击事件
function
handleClose
(){
function
handleClose
(){
...
...
src/views/SchedulingPage/WindManagePage.vue
View file @
76205dae
...
@@ -30,27 +30,29 @@ function revise(val) {
...
@@ -30,27 +30,29 @@ function revise(val) {
reviseWindowOpen
.
value
=
true
;
reviseWindowOpen
.
value
=
true
;
}
// 修改按钮单击事件
}
// 修改按钮单击事件
function
omit
(
val
)
{
function
omit
(
val
)
{
let
id
=
val
.
windId
;
let
param
=
{
id
:
val
.
windId
,
}
ElMessageBox
.
confirm
(
"点击确定后,该条数据将删除,是否继续?"
,
"Warning"
,
{
ElMessageBox
.
confirm
(
"点击确定后,该条数据将删除,是否继续?"
,
"Warning"
,
{
confirmButtonText
:
"确定"
,
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
cancelButtonText
:
"取消"
,
type
:
"warning"
,
type
:
"warning"
,
})
})
.
then
(()
=>
{
.
then
(()
=>
{
deleteWind
(
id
).
then
((
res
)
=>
{
deleteWind
(
param
).
then
((
res
)
=>
{
getData
();
getData
();
ElMessage
({
ElMessage
({
message
:
"删除成功."
,
message
:
"删除成功."
,
type
:
"success"
,
type
:
"success"
,
});
});
});
}).
catch
((
err
)
=>
{
ElMessage
({
message
:
"删除失败."
,
type
:
"error"
,
});
});
})
})
.
catch
((
err
)
=>
{
ElMessage
({
message
:
"删除失败."
,
type
:
"error"
,
});
});
}
// 删除按钮单击事件
}
// 删除按钮单击事件
function
search
()
{
function
search
()
{
if
(
!
searchKey
.
value
)
{
if
(
!
searchKey
.
value
)
{
...
...
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