feat(daily-prep): add DailyPrepMaxTasks editor to Prime Claude settings

This commit is contained in:
mika kuns
2026-06-03 16:33:00 +02:00
parent 2d00160283
commit 5e0859fbb8
5 changed files with 11 additions and 4 deletions

View File

@@ -22,8 +22,6 @@ public sealed partial class SettingsModalViewModel : ViewModelBase
[ObservableProperty] private bool _isBusy;
[ObservableProperty] private string _statusMessage = "";
private int _loadedDailyPrepMaxTasks = 5;
public Action? CloseAction { get; set; }
public SettingsModalViewModel(WorkerClient worker, PrimeClaudeTabViewModel prime,
@@ -62,7 +60,7 @@ public sealed partial class SettingsModalViewModel : ViewModelBase
: string.Join(Environment.NewLine,
System.Text.Json.JsonSerializer.Deserialize<List<string>>(dto.ReportExcludedPaths) ?? new());
General.StandupWeekday = dto.StandupWeekday is >= 0 and <= 6 ? dto.StandupWeekday : (int)DayOfWeek.Wednesday;
_loadedDailyPrepMaxTasks = dto.DailyPrepMaxTasks < 1 ? 5 : dto.DailyPrepMaxTasks;
Prime.DailyPrepMaxTasks = dto.DailyPrepMaxTasks < 1 ? 5 : dto.DailyPrepMaxTasks;
}
else StatusMessage = Loc.T("vm.settingsModal.workerOffline");
@@ -95,7 +93,7 @@ public sealed partial class SettingsModalViewModel : ViewModelBase
General.ReportExcludedPaths
.Split('\n').Select(l => l.Trim().TrimEnd('\r')).Where(l => l.Length > 0).ToList()),
General.StandupWeekday,
_loadedDailyPrepMaxTasks);
Prime.DailyPrepMaxTasks);
await _worker.UpdateAppSettingsAsync(dto);
await Prime.SaveAsync();
CloseAction?.Invoke();