From 99b4888709b8b9dc435bff476cb73210e91017cc Mon Sep 17 00:00:00 2001 From: T Date: Wed, 13 Aug 2025 23:09:07 -0600 Subject: edit clients and projects --- internal/tui/keys.go | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'internal/tui/keys.go') diff --git a/internal/tui/keys.go b/internal/tui/keys.go index 52e15f6..5cbefa4 100644 --- a/internal/tui/keys.go +++ b/internal/tui/keys.go @@ -58,9 +58,9 @@ var Bindings map[KeyBindingScope]map[string]KeyBinding = map[KeyBindingScope]map Result: func(am *AppModel) tea.Cmd { return am.refreshCmd }, }, "c": KeyBinding{ - Key: "c", + Key: "c", Description: func(am AppModel) string { return "Edit Contractor" }, - Result: func(am *AppModel) tea.Cmd { return editContractor() }, + Result: func(am *AppModel) tea.Cmd { return editContractor() }, }, "q": KeyBinding{ Key: "q", @@ -108,6 +108,16 @@ var Bindings map[KeyBindingScope]map[string]KeyBinding = map[KeyBindingScope]map Description: func(AppModel) string { return "Up" }, Result: func(*AppModel) tea.Cmd { return changeSelection(false) }, }, + "e": KeyBinding{ + Key: "e", + Description: func(m AppModel) string { + if m.projectsBox.selectedProject != nil { + return "Edit Project" + } + return "Edit Client" + }, + Result: func(*AppModel) tea.Cmd { return editClientOrProject() }, + }, "down": KeyBinding{ Key: "down", Description: func(AppModel) string { return "Down" }, -- cgit v1.2.3