Class: Weekdone::Cli::Item
- Inherits:
-
Thor
- Object
- Thor
- Weekdone::Cli::Item
- Includes:
- Weekdone::Cli
- Defined in:
- lib/weekdone/cli/command_item.rb
Constant Summary
Constants included from Weekdone::Cli
Instance Method Summary collapse
Methods included from Weekdone::Cli
Instance Method Details
#getComments ⇒ Object
36 37 38 39 40 41 42 |
# File 'lib/weekdone/cli/command_item.rb', line 36 def getComments client = build_client comments = client.getItemComments([:itemid]) Credential.write_credential(client.token_hash) Output.format(comments, :json) end |
#likes ⇒ Object
25 26 27 28 29 30 31 |
# File 'lib/weekdone/cli/command_item.rb', line 25 def likes client = build_client likes = client.getItemLikes([:itemid]) Credential.write_credential(client.token_hash) Output.format(likes, format: :json) end |
#search ⇒ Object
15 16 17 18 19 20 21 |
# File 'lib/weekdone/cli/command_item.rb', line 15 def search client = build_client items = client.searchForItems(user_id: [:userid]) Credential.write_credential(client.token_hash) Output.format(items, format: :json) end |