issue-20: Added binding action for prompting for tables
At the moment, this is not bound to anything
This commit is contained in:
parent
5f76836166
commit
454fcf2eae
|
@ -24,6 +24,7 @@ type ViewKeyBindings struct {
|
|||
Rescan key.Binding `keymap:"rescan"`
|
||||
PromptForQuery key.Binding `keymap:"prompt-for-query"`
|
||||
PromptForFilter key.Binding `keymap:"prompt-for-filter"`
|
||||
PromptForTable key.Binding `keymap:"prompt-for-table"`
|
||||
ViewBack key.Binding `keymap:"view-back"`
|
||||
ViewForward key.Binding `keymap:"view-forward"`
|
||||
CycleLayoutForward key.Binding `keymap:"cycle-layout-forward"`
|
||||
|
|
|
@ -227,6 +227,10 @@ func (m Model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
|
|||
// return m, nil
|
||||
case key.Matches(msg, m.keyMap.PromptForCommand):
|
||||
return m, m.commandController.Prompt
|
||||
case key.Matches(msg, m.keyMap.PromptForTable):
|
||||
return m, func() tea.Msg {
|
||||
return m.tableReadController.ListTables()
|
||||
}
|
||||
case key.Matches(msg, m.keyMap.Quit):
|
||||
return m, tea.Quit
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue