MCPcopy Create free account
hub / github.com/OverloadBlitz/cloudcent-cli / switchViewPrev

Method switchViewPrev

internal/tui/app.go:401–416  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

399}
400
401func (a *App) switchViewPrev() {
402 switch a.viewMode {
403 case ViewModePricing:
404 a.viewMode = ViewModeSettings
405 a.settingsView.ActiveSection = views.SettingsSectionHeader
406 case ViewModeHistory:
407 a.viewMode = ViewModePricing
408 a.pricingView.ActiveSection = views.PricingSectionHeader
409 case ViewModeSettings:
410 a.viewMode = ViewModeHistory
411 a.historyView.ActiveSection = views.HistorySectionHeader
412 if a.db != nil {
413 a.historyView.History, _ = a.db.GetHistory(100)
414 }
415 }
416}
417
418func (a App) submitPricingQuery() (tea.Model, tea.Cmd) {
419 if a.pricingView.Loading {

Callers 3

handlePricingEventMethod · 0.95
handleHistoryEventMethod · 0.95
handleSettingsEventMethod · 0.95

Calls 1

GetHistoryMethod · 0.80

Tested by

no test coverage detected