Class: UffizziCore::Api::Cli::V1::AccountsController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- UffizziCore::Api::Cli::V1::AccountsController
- Includes:
- AccountsControllerModule
- Defined in:
- app/controllers/uffizzi_core/api/cli/v1/accounts_controller.rb
Instance Method Summary collapse
-
#index ⇒ Object
Get accounts of current user.
-
#show ⇒ Object
Get account by name.
Instance Method Details
#index ⇒ Object
Get accounts of current user
16 17 18 19 20 |
# File 'app/controllers/uffizzi_core/api/cli/v1/accounts_controller.rb', line 16 def index accounts = current_user.accounts.order(name: :desc) respond_with accounts end |
#show ⇒ Object
Get account by name
28 29 30 |
# File 'app/controllers/uffizzi_core/api/cli/v1/accounts_controller.rb', line 28 def show respond_with resource_account end |