From 269292a8d345e23a0f0a46e71ece3633e14baa8e Mon Sep 17 00:00:00 2001 From: jaydee Date: Fri, 5 Dec 2025 07:36:54 +0100 Subject: [PATCH] build --- portainer.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/portainer.py b/portainer.py index 5a3ed50..c627f62 100755 --- a/portainer.py +++ b/portainer.py @@ -272,11 +272,17 @@ def prompt_missing_args(args_in, defaults_in, fields): try: if field == "stack": commands_tuples = [(cmd, cmd) for cmd in commands] + commands_tuples.insert(0, ("__ALL__", "[Select ALL]")) value_in = checkboxlist_dialog( title="Select Services", text="Choose one or more services:", values=commands_tuples, ).run() + if value_in is None: + print("Cancelled.") + elif "__ALL__" in value_in: + # User selected "Select ALL" + value_in = commands # all real commands print(" >> Stacks :", ",".join(value_in)) else: value_in = ( @@ -311,7 +317,9 @@ def prompt_missing_args(args_in, defaults_in, fields): sys.exit(0) # value_in = input_with_default(text, default, longest+2) - + if "pihole" in value_in: + value_in.remove("pihole") + value_in.insert(0, "pihole") if por._debug: print("Value entered:", value_in) defaults_in[f"PORTAINER_{field}".upper()] = value_in