二级评估bug修改

This commit is contained in:
sjl
2025-09-03 18:26:19 +08:00
parent 65f645eaaf
commit 8b20307a14
6 changed files with 43 additions and 12 deletions

View File

@@ -117,8 +117,8 @@
<el-input-number
v-else-if="item.field == 'powerFactor'"
v-model="form[item.field]"
:min="0"
:max="1"
:min="0.1"
:max="0.9"
:step="0.1"
:precision="1"
placeholder="请输入功率因数"
@@ -134,8 +134,9 @@
item.field == 's'||
item.field == 'transhighCapacity'||
item.field == 'transImpedance'||
item.field == 'nonlinearloadPower'
item.field == 'nonlinearloadPower' ||
item.field == 'inpactloadNum' ||
item.field =='isolationtransImpedance'
"
style="width: 100%"
v-model="form[item.field]"

View File

@@ -141,6 +141,8 @@
v-model.trim="form.powersupplyCapacity"
show-word-limit
placeholder="请输入值"
min="1"
max="9999"
></el-input-number>
</el-form-item>
<el-form-item label="最小短路容量(MVA)" prop="minshortcircuitCapacity">
@@ -149,6 +151,8 @@
v-model.trim="form.minshortcircuitCapacity"
show-word-limit
placeholder="请输入值"
min="1"
max="9999"
></el-input-number>
</el-form-item>
<el-form-item label="PCC点名称" prop="lineId">
@@ -317,7 +321,7 @@ const onsubmit = () => {
if (valid2) {
if(form.value.assessId){
userEdit(form.value).then((res: any) => {
form.value.assessId = res.data
//form.value.assessId = res.data
ElMessage({
type: 'success',
message: '编辑成功!'

View File

@@ -46,7 +46,7 @@
v-for="item in voltageleveloption"
:key="item.id"
:label="item.name"
:value="item.name"
:value="item.id"
></el-option>
</el-select>
</el-form-item>
@@ -65,7 +65,7 @@
v-for="item in voltageleveloption"
:key="item.id"
:label="item.name"
:value="item.name"
:value="item.id"
></el-option>
</el-select>
</el-form-item>
@@ -245,7 +245,7 @@ watch(
(newQuery) => {
tableStore.index()
},
{ immediate: true }
// { immediate: true }
)
// 新增评估用户页面

View File

@@ -402,6 +402,11 @@ const info = async (i: number) => {
const typeId = ref(null)
// 过滤数据
const formatter = (row: any) => {
// 检查数据是否已加载完成
if (!row.cellValue && row.cellValue !== 0) {
return ''; // 数据未加载时返回空字符串
}
if (row.column.field == 'transtypeId') {
if (row.cellValue) {
const found = transformer.value.find((item: any) => item.transtypeId == row.cellValue)
@@ -430,7 +435,11 @@ const formatter = (row: any) => {
}
else if (row.column.field == 'harmId') {
const found = characteristic.value.find((item: any) => item.harmId == row.cellValue)
return found.harmName || '' // 使用可选链并提供默认值
if(found){
return found.harmName
}else{
return ''
}
} else if (
row.column.field == 'capacitorScale' ||
row.column.field == 'linevoltageScale' ||
@@ -459,7 +468,7 @@ const dictionary = () => {
})
}
onMounted(async () => {
onBeforeMount(async () => {
await dictionary()
info(0) // 变压器参数维护
info(1) // 电容器参数维护