Explorar o código

修复默认值回显

yukai %!s(int64=2) %!d(string=hai) anos
pai
achega
6edb19aa2e
Modificáronse 1 ficheiros con 4 adicións e 2 borrados
  1. 4 2
      src/views/system/datahub/modeling/component/juhe.vue

+ 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;
+						}
 					});
 				});
 			}