Adrian Ehrsam 1 tahun lalu
induk
melakukan
990eaf6c28
1 mengubah file dengan 1 tambahan dan 1 penghapusan
  1. 1 1
      tests/test_aggrid.py

+ 1 - 1
tests/test_aggrid.py

@@ -95,7 +95,7 @@ def test_call_column_api_method_with_argument(screen: Screen):
         'columnDefs': [{'field': 'name'}, {'field': 'parent_name', 'hide': True}],
         'rowData': [{'name': 'Alice', 'parent_name': 'Frederic'}, {'name': 'Bob', 'parent_name': 'Joseph'}, {'name': 'Carol', 'parent_name': 'John-Peter'}],
     })
-    ui.button('Show Age', on_click=lambda: grid.call_column_api_method('setColumnVisible', 'age'))
+    ui.button('Show Age', on_click=lambda: grid.call_column_api_method('setColumnVisible', 'parent_name'))
 
     screen.open('/')
     screen.should_contain('Alice')