소스 검색

chart: do not show warning on no data bound when figure is declared (#1107)

* do not show warning on no data bound when figure is declared
resolves #1106

* check data for non chart control

---------

Co-authored-by: Fred Lefévère-Laoide <Fred.Lefevere-Laoide@Taipy.io>
Fred Lefévère-Laoide 1 년 전
부모
커밋
09ace5221a
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      taipy/gui/_renderers/builder.py

+ 2 - 2
taipy/gui/_renderers/builder.py

@@ -802,8 +802,8 @@ class _Builder:
                 else:
                     self.__set_default_value(var_name, var_type=var_type)
         else:
-            if var_type == PropertyType.data:
-                _warn(f"{self.__control_type}.data property should be bound.")
+            if var_type == PropertyType.data and (self.__control_type != "chart" or "figure" not in self.__attributes):
+                _warn(f"{self.__control_type}.{var_name} property should be bound.")
             value = self.__attributes.get(var_name)
             if value is not None:
                 if native_type: