Sha256: 7471c445247f7bd9fc70ed18f0af656db18e4003e72e9d892f0ea642153394c6

Contents?: true

Size: 821 Bytes

Versions: 7

Compression:

Stored size: 821 Bytes

Contents

module Plutus
  # This controller provides restful route handling for Accounts.
  #
  # The controller supports ActiveResource, and provides for
  # HMTL, XML, and JSON presentation.
  #
  # == Security:
  # Only GET requests are supported. You should ensure that your application
  # controller enforces its own authentication and authorization, which this
  # controller will inherit.
  #
  # @author Michael Bulat
  class AccountsController < Plutus::ApplicationController
    unloadable

    # @example
    #   GET /accounts
    #   GET /accounts.xml
    #   GET /accounts.json
    def index
      @accounts = Account.all

      respond_to do |format|
        format.html # index.html.erb
        format.xml  { render :xml => @accounts }
        format.json  { render :json => @accounts }
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 3 rubygems

Version Path
plutus-0.16 app/controllers/plutus/accounts_controller.rb
plutus-0.15 app/controllers/plutus/accounts_controller.rb
plutus-0.14 app/controllers/plutus/accounts_controller.rb
tyche-0.14 app/controllers/plutus/accounts_controller.rb
odania_plutus-0.13 app/controllers/plutus/accounts_controller.rb
plutus-0.13 app/controllers/plutus/accounts_controller.rb
plutus-0.12.2 app/controllers/plutus/accounts_controller.rb