Merge pull request #41 from pdxlocations/fix-repeated-input

ignore-incoming work - still not saving
This commit is contained in:
pdxlocations
2025-01-21 09:27:07 -08:00
committed by GitHub
2 changed files with 2 additions and 1 deletions

View File

@@ -102,7 +102,7 @@ def get_repeated_input(current_value):
repeated_win.clear()
repeated_win.border()
repeated_win.addstr(1, 2, "Enter comma-separated values:", curses.A_BOLD)
repeated_win.addstr(3, 2, f"Current: {', '.join(current_value)}")
repeated_win.addstr(3, 2, f"Current: {', '.join(map(str, current_value))}")
repeated_win.addstr(5, 2, f"New value: {user_input}")
repeated_win.refresh()

View File

@@ -173,6 +173,7 @@ def settings_menu(sdscr, interface):
elif field.label == field.LABEL_REPEATED: # Handle repeated field
new_value = get_repeated_input(current_value)
new_value = current_value if new_value is None else [int(item) for item in new_value]
elif field.enum_type: # Enum field
enum_options = [v.name for v in field.enum_type.values]