Ver código fonte

修复默认值回显

yukai 2 anos atrás
pai
commit
6edb19aa2e

+ 4 - 2
src/views/system/datahub/modeling/component/juhe.vue

@@ -109,8 +109,10 @@ export default defineComponent({
 						state.sourceData = res.list;
 						state.ruleForm.GroupNodeKey = row.groupNodeKey;
 						state.ruleForm.TimeNodeKey = row.timeNodeKey;
-						state.ruleForm.Duration = row.duration;
-						state.ruleForm.TimeUnit = row.timeUnit;
+						if(row.duration>0){
+							state.ruleForm.Duration = row.duration;
+							state.ruleForm.TimeUnit = row.timeUnit;
+						}
 					});
 				});
 			}