diff --git a/src/views/pqs/supervise/terminalNetworkDetection/components/monitorpoint/addForm.vue b/src/views/pqs/supervise/terminalNetworkDetection/components/monitorpoint/addForm.vue index 0644f30a..0199f0e8 100644 --- a/src/views/pqs/supervise/terminalNetworkDetection/components/monitorpoint/addForm.vue +++ b/src/views/pqs/supervise/terminalNetworkDetection/components/monitorpoint/addForm.vue @@ -497,19 +497,19 @@ const numList = [ //测量间隔数据 const timeIntervalList = [ { - id: '1', + id: 1, name: '一分钟' }, { - id: '3', + id: 3, name: '三分钟' }, { - id: '5', + id: 5, name: '五分钟' }, { - id: '10', + id: 10, name: '十分钟' } ] @@ -541,7 +541,7 @@ const changeDevice = () => { //定义切换form类型 const selectFormType = ref('') selectFormType.value = '0' -const resetForm = () => { +const resetForm = async () => { form.value = { // reporter: '', //填报人 // reporterName: '', //填报人名称 @@ -562,9 +562,9 @@ const resetForm = () => { ct2: 5, //CT变比2 pt1: 1, // PT变比1 pt2: 1, // PT变比2 - shortCapacity: '10', // 短路容量 - dealCapacity: '10', //协议容量 - devCapacity: '10', //终端容量 + shortCapacity: 10, // 短路容量 + dealCapacity: 10, //协议容量 + devCapacity: 10, //终端容量 standardCapacity: 10, //基准容量 isGridConnectionPoint: 0, //是否并网点 isStatistical: 0, // 是否参与统计 @@ -583,12 +583,12 @@ const resetForm = () => { ptType: ptTypeList[0].id, //接线方式 num: numList[0].id //线路号 } - getList({}).then(res => { + await getList({}).then(res => { projectList.value = res.data userNameList.value = res.data //初始化 let obj = res.data[0] - if (title.value != '重新发起') { + if (title.value != '重新发起' && title.value != '编辑') { form.value = { ...form.value, // city: obj.city, @@ -605,7 +605,9 @@ const resetForm = () => { changeUserName() } }) - changevoltageDeviationLimit() + if(title.value != '编辑'){ + changevoltageDeviationLimit() + } } //根据检测点电压等级切换电压偏差上限/下限 const changevoltageDeviationLimit = async () => { @@ -1018,7 +1020,6 @@ const close = () => { ruleFormRef.value && ruleFormRef.value.resetFields() dialogFormVisible.value = false emits('onSubmit') - resetForm() } onMounted(() => {})