Class: Dsu::Subcommands::Browse

Inherits:
BaseSubcommand show all
Includes:
Dsu::Support::CommandOptions::TimeMnemonic, Dsu::Support::EntryGroupBrowsable, Dsu::Support::TimeFormatable
Defined in:
lib/dsu/subcommands/browse.rb

Constant Summary

Constants included from Dsu::Support::CommandOptions::TimeMnemonics

Dsu::Support::CommandOptions::TimeMnemonics::RELATIVE_REGEX, Dsu::Support::CommandOptions::TimeMnemonics::TODAY, Dsu::Support::CommandOptions::TimeMnemonics::TOMORROW, Dsu::Support::CommandOptions::TimeMnemonics::YESTERDAY

Instance Method Summary collapse

Methods included from Dsu::Support::TimeFormatable

dd_mm_yyyy, formatted_time, mm_dd, mm_dd_yyyy, timezone_for, yyyy_mm_dd, yyyy_mm_dd_or_through_for

Methods included from Dsu::Support::CommandOptions::TimeMnemonic

relative_time_mnemonic?, time_from_mnemonic, time_from_mnemonic!, time_mnemonic?

Methods included from Dsu::Support::EntryGroupBrowsable

#browse_entry_groups

Methods included from Dsu::Support::Ask

#ask_while, #yes?

Methods inherited from BaseCLI

date_option_description, exit_on_failure?, #initialize, mnemonic_option_description

Methods included from Dsu::Support::TimesSortable

#sorted_dsu_times_for, #times_for, #times_sort

Methods included from Dsu::Support::CommandHookable

included

Methods included from Dsu::Support::CommandHelpColorizable

included

Methods included from Dsu::Support::ColorThemable

apply_theme, #prompt_with_options

Constructor Details

This class inherits a constructor from Dsu::BaseCLI

Instance Method Details

#monthObject



38
39
40
# File 'lib/dsu/subcommands/browse.rb', line 38

def month
  browse_entry_groups time: Time.now, options: options.merge({ browse: :month })
end

#weekObject



32
33
34
# File 'lib/dsu/subcommands/browse.rb', line 32

def week
  browse_entry_groups time: Time.now, options: options.merge({ browse: :week })
end

#yearObject



44
45
46
# File 'lib/dsu/subcommands/browse.rb', line 44

def year
  browse_entry_groups time: Time.now, options: options.merge({ browse: :year })
end