Commit 90ce2f96 authored by jiaxu.yan's avatar jiaxu.yan

feat: 参数设置限制输入数字

parent accff522
*{
box-sizing:border-box;
-moz-box-sizing:border-box; /* Firefox */
-webkit-box-sizing:border-box; /* Safari */
* {
box-sizing: border-box;
-moz-box-sizing: border-box; /* Firefox */
-webkit-box-sizing: border-box; /* Safari */
}
.el-pager li{
.el-pager li {
font-weight: 100;
margin-right: 9px;
border: 1px solid #eee;
border-radius: 3px;
min-width: 28px;
}
.el-pager li.active,.el-pager li:hover{
.el-pager li.active,
.el-pager li:hover {
background: #ed4014;
color: white;
}
.el-pagination__editor.el-input .el-input__inner{
.el-pagination__editor.el-input .el-input__inner {
height: 23px;
}
.animated {
-webkit-animation-duration: 0.5s;
animation-duration: 0.5s;
-webkit-animation-fill-mode: both;
animation-fill-mode: both;
}
}
@media (print), (prefers-reduced-motion) {
@media (print), (prefers-reduced-motion) {
.animated {
-webkit-animation: unset !important;
animation: unset !important;
-webkit-transition: none !important;
transition: none !important;
}
}
}
@-webkit-keyframes fadeInDown {
@-webkit-keyframes fadeInDown {
from {
opacity: 1;
-webkit-transform: translate3d(0, -100%, 0);
......@@ -47,9 +47,9 @@
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
}
}
@keyframes fadeInDown {
@keyframes fadeInDown {
from {
opacity: 0;
-webkit-transform: translate3d(0, -100%, 0);
......@@ -61,15 +61,15 @@
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
}
}
.fadeInDown {
.fadeInDown {
-webkit-animation-name: fadeInDown;
animation-name: fadeInDown;
}
.ivu-message{
}
.ivu-message {
z-index: 999999999 !important;
}
.ivu-form-item-content{
}
.ivu-form-item-content {
text-align: left;
}
\ No newline at end of file
}
<template>
<div class="contentBlock">
<div class="contentBlockInn">
<el-card class="card-contianer">
<table cellpadding="0" cellspacing="1" style="background-color: #99bbe8">
<table
cellpadding="0"
cellspacing="1"
style="background-color: #99bbe8"
>
<tr>
<th style="width: 25%">电调阈开启度</th>
<td style="width: 60%; margin:0; padding: 0">
<td style="width: 60%; margin: 0; padding: 0">
<table cellpadding="0" cellspacing="0">
<tr>
<td style="text-align: left">
<el-input style="width: 80%" v-model="formDatas.openingOfElectricValve">
<el-input-number
:controls="false"
style="width: 80%;text-align: left;"
v-model="formDatas.openingOfElectricValve"
>
<template #append>
<div style="width: 40px">%
</div>
<div style="width: 40px">%</div>
</template>
</el-input>
</el-input-number>
</td>
</tr>
</table>
......@@ -30,36 +36,38 @@
{{ option }}
</el-checkbox>
</el-checkbox-group> -->
<el-checkbox-group v-model="form.type" style="width: 60%;">
<el-checkbox v-for="(option, index) in formDatas.transferIds" :label="option">
<el-checkbox-group v-model="form.type" style="width: 60%">
<el-checkbox
v-for="(option, index) in formDatas.transferIds"
:label="option"
>
{{ option }}
</el-checkbox>
</el-checkbox-group>
</td>
</tr>
<tr>
<th style="width: 25%">锅炉出水温度增加</th>
<td style="width: 60%; margin: 0; padding: 0">
<table cellpadding="0" cellspacing="0">
<tr>
<td style="text-align: left">
<el-input style="width: 80%" v-model="formDatas.boilerOutletWaterTemperature">
<el-input-number
:controls="false"
style="width: 80%"
v-model="formDatas.boilerOutletWaterTemperature"
>
<template #append>
<div style="width: 40px;">
</div>
<div style="width: 40px"></div>
</template>
</el-input>
</el-input-number>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<th style="width: 25%">电调阈开启度保持时间</th>
<td style="width: 60%; margin: 0; padding: 0">
......@@ -67,13 +75,15 @@
<tr>
<td style="text-align: left">
<el-form>
<el-input style="width: 80%" v-model="formDatas.holdingTime">
<el-input-number
:controls="false"
style="width: 80%"
v-model="formDatas.holdingTime"
>
<template #append>
<div style="width: 40px">
分钟
</div>
<div style="width: 40px">分钟</div>
</template>
</el-input>
</el-input-number>
</el-form>
</td>
</tr>
......@@ -81,20 +91,21 @@
</td>
</tr>
<tr>
<th style="width: 25%">锅炉房供水总管流量上限值</th>
<td style="width: 60%; margin: 0; padding: 0">
<table cellpadding="0" cellspacing="0">
<tr>
<td style="text-align: left">
<el-input style="width: 80%" v-model="formDatas.upperLlimitMainFlow">
<el-input-number
:controls="false"
style="width: 80%"
v-model="formDatas.upperLlimitMainFlow"
>
<template #append>
<div style="width: 40px;">
m3/h
</div>
<div style="width: 40px">m3/h</div>
</template>
</el-input>
</el-input-number>
</td>
</tr>
</table>
......@@ -107,13 +118,15 @@
<table cellpadding="0" cellspacing="0">
<tr>
<td style="text-align: left">
<el-input style="width: 80%" v-model="formDatas.lowerLlimitMainFlow">
<el-input-number
:controls="false"
style="width: 80%"
v-model="formDatas.lowerLlimitMainFlow"
>
<template #append>
<div style="width: 40px">
m3/h
</div>
<div style="width: 40px">m3/h</div>
</template>
</el-input>
</el-input-number>
</td>
</tr>
</table>
......@@ -125,38 +138,40 @@
<table cellpadding="0" cellspacing="0">
<tr>
<td style="text-align: left">
<el-input style="width: 80%" v-model="formDatas.maxTargetTemperature">
<el-input-number
:controls="false"
style="width: 80%"
v-model="formDatas.maxTargetTemperature"
>
<template #append>
<div style="width: 40px;">
</div>
<div style="width: 40px"></div>
</template>
</el-input>
</el-input-number>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<th style="width: 25%">总管流量上下限范围内持续时间</th>
<td style="width: 60%; margin: 0; padding: 0">
<table cellpadding="0" cellspacing="0">
<tr>
<td style="text-align: left">
<el-input style="width: 80%" v-model="formDatas.bestHoldingTime">
<el-input-number
:controls="false"
style="width: 80%;"
v-model="formDatas.bestHoldingTime"
>
<template #append>
<div style="width: 40px">
分钟
</div>
<div style="width: 40px">分钟</div>
</template>
</el-input>
</el-input-number>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<th></th>
......@@ -164,7 +179,9 @@
<div>
<div class="btngrounp">
<el-button type="primary" @click="onSave">保存</el-button>
<el-button type="primary" style="margin: 0 0 0 5px">关闭</el-button>
<el-button type="primary" style="margin: 0 0 0 5px"
>关闭</el-button
>
</div>
</div>
</th>
......@@ -173,56 +190,58 @@
</el-card>
</div>
</div>
</template>
<script setup>
import { ref, reactive, onMounted, onUnmounted, onBeforeMount } from "vue";
import { postConfigBoilerUpdate } from '@/api/scheduling.js'
import http from '../../api/http';
import { postConfigBoilerUpdate } from "@/api/scheduling.js";
import http from "../../api/http";
import { ElMessage } from "element-plus";
const options = reactive(['瑞景园低区', '瑞景园高区', '翰锦园', '圣美园低区', '圣美园高区', '社区服务中心', '风雅园', '风雅园_幼儿园', '枫润园低区', '枫润园高区']);
const options = reactive([
"瑞景园低区",
"瑞景园高区",
"翰锦园",
"圣美园低区",
"圣美园高区",
"社区服务中心",
"风雅园",
"风雅园_幼儿园",
"枫润园低区",
"枫润园高区",
]);
const form = ref({
types: []
})
types: [],
});
const formDatas = ref([
{
"updateNullFields": "",
"configId": "",
"openingOfElectricValve": "",
"boilerOutletWaterTemperature": "",
"holdingTime": "",
"upperLlimitMainFlow": "",
"lowerLlimitMainFlow": "",
"maxTargetTemperature": "",
"bestHoldingTime": "",
"transferIds": ""
}
])
updateNullFields: "",
configId: "",
openingOfElectricValve: "",
boilerOutletWaterTemperature: "",
holdingTime: "",
upperLlimitMainFlow: "",
lowerLlimitMainFlow: "",
maxTargetTemperature: "",
bestHoldingTime: "",
transferIds: "",
},
]);
const getListData = () => {
http.get("/api/configboiler/getData").then((result) => {
formDatas.value = result.data;
formDatas.value.updateNullFields=""
})
}
formDatas.value.updateNullFields = "";
});
};
const onSave = async () => {
const result = await postConfigBoilerUpdate({...formDatas.value})
if(result.success) {
ElMessage.success('修改成功')
const result = await postConfigBoilerUpdate({ ...formDatas.value });
if (result.success) {
ElMessage.success("修改成功");
}
}
};
onMounted(() => {
getListData()
})
getListData();
});
</script>
<style lang="less" scoped>
.contentBlock {
......@@ -237,6 +256,9 @@ onMounted(() => {
table {
width: 100%;
.el-input__inner {
text-align: left !important;
}
}
table,
......@@ -266,8 +288,6 @@ table td {
.btngrounp {
width: 300px;
}
.gc td {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment