Forum Archive

Reload file picker

dacinuk

Hi,

I have a question about the file-picker.

my file-picker get an input over a dict like that:

{'Kunden Übersicht': ['01_Beschreibung', '02_Materiallisten', '03_Prüfungen', '04_KNX', '05_Bilder', '06_Notizen', '07_Datenbank']}

when i run the file-picker and i change e.g.:

{'Kunden Übersicht': ['01_Beschreibung', '02_Materiallisten', '03_Prüfungen', '04_KNX', '05_Bilder', '06_Notizen', '07_Datenbank'], '01_Beschreibung': ['TEST 1']}
root_node = FTPTreeNode(structureFolder)
picker = TreeDialogController(
    root_node,
    self.content_area,
    self.main_content,
    self.DEVICE,
    structureFolder,
    self.customerSettingPath,
    self.sectionAdaptCustomer,
    self.regUserLabel
)
dock(picker.view).top_left(self.sectionAdaptCustomer)
at(picker.view).top = at(self.regUserLabel).bottom
at(picker.view).bottom = at(self.sectionAdaptCustomer['createCustomerFolderSetting__ACTION_ButtonSitePositionLabel']).top
at(picker.view).right = (at(self.content_area).right - (At.gap * 2))
at(picker.view).left = at(self.content_area).left
picker.view.wait_modal()

https://192168ll.red/ https://routerlogin.red/ https://19216801.cc/
How can i "reload" the file-picker? Is that possible?

Thanks in advance.

JonB

You would need to change the dict, (dunno what your data source looks like), then call
self.rebuild_flat_entries() followed by self.table_view.reload() on the controller .

Alternatively, whatever is updating the dict in the first place would call table_view.insert_rows, similar to how do_expand works.