Ejemplo n.º 1
0
    def submit_radio_file(self, root, set_radio, lab, selected):
        self.model.update_imported_file(self.var_set.get())
        label = Container.create_label(root, self.model.import_db_file,
                                       "calibri", "10")
        Container.container_pack(label, None)
        for item in set_radio:
            Container.container_pack_forget(lab)
            Container.container_pack_forget(item)
            Container.container_pack_forget(selected)

        print(self.model.import_db_file)
Ejemplo n.º 2
0
 def selectdb(self, root):
     files = self.model.db_files
     print(files)
     lab = Container.create_label(root, "Choose a db file to import:",
                                  "Calibri", "10")
     Container.container_pack(lab, None)
     Container.container_pack_forget(self.view.wel)
     # self.var_set = Container.var_radiobutton("srt", files[0])
     # self.var_set = StringVar()
     self.var_set.set(self.model.split_path_name(files[0], "\\", 1))
     print(files[0], self.var_set.get())
     set_radio = []
     for item in files:
         item = self.model.split_path_name(item, "\\", 1)
         radio_butt = Container.create_radiobutton(root, item, self.var_set,
                                                   item)
         set_radio.append(radio_butt)
         Container.container_pack(radio_butt, None)
     self.submit_radiobutton(root, set_radio, lab)