Class: Pike13::CLI::Commands::Desk::Refund

Inherits:
Base
  • Object
show all
Defined in:
lib/pike13/cli/commands/desk/refund.rb

Instance Method Summary collapse

Methods inherited from Base

base_usage, format_options, handle_argument_error, printable_commands

Methods included from ThorNestedSubcommand

included

Instance Method Details

#get(id) ⇒ Object



10
11
12
13
14
15
# File 'lib/pike13/cli/commands/desk/refund.rb', line 10

def get(id)
  handle_error do
    result = Pike13::Desk::Refund.find(id)
    output(result)
  end
end

#void(id) ⇒ Object



19
20
21
22
23
24
25
26
# File 'lib/pike13/cli/commands/desk/refund.rb', line 19

def void(id)
  handle_error do
    result = with_progress("Voiding refund") do
      Pike13::Desk::Refund.void(refund_id: id)
    end
    output(result)
  end
end