Beispiel #1
0
 def click_configure(self):
     current_selection = self.current.listbox.curselection()
     if len(current_selection):
         dialog = ServiceConfigDialog(
             master=self,
             app=self.app,
             service_name=self.current.listbox.get(current_selection[0]),
             node_id=self.node_id,
         )
         dialog.show()
     else:
         messagebox.showinfo(
             "Node service configuration", "Select a service to configure"
         )
Beispiel #2
0
    def click_configure(self):
        current_selection = self.current.listbox.curselection()
        if len(current_selection):
            dialog = ServiceConfigDialog(
                master=self,
                app=self.app,
                service_name=self.current.listbox.get(current_selection[0]),
                node_id=self.node_id,
            )

            # if error occurred when creating ServiceConfigDialog, don't show the dialog
            if not dialog.has_error:
                dialog.show()
            else:
                dialog.destroy()
        else:
            messagebox.showinfo("Node service configuration",
                                "Select a service to configure")
Beispiel #3
0
    def click_configure(self) -> None:
        current_selection = self.current.listbox.curselection()
        if len(current_selection):
            dialog = ServiceConfigDialog(
                self,
                self.app,
                self.current.listbox.get(current_selection[0]),
                self.node,
            )

            # if error occurred when creating ServiceConfigDialog, don't show the dialog
            if not dialog.has_error:
                dialog.show()
            else:
                dialog.destroy()
        else:
            messagebox.showinfo("Service Configuration",
                                "Select a service to configure",
                                parent=self)