Class: ProfilesController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/profiles_controller.rb

Instance Method Summary collapse

Instance Method Details

#editObject



16
17
18
# File 'app/controllers/profiles_controller.rb', line 16

def edit
  current_profile
end

#showObject



6
7
8
9
10
11
12
13
14
# File 'app/controllers/profiles_controller.rb', line 6

def show
  subject_profile

  respond_to do |format|
    format.html
    format.js
    format.json { render json: subject_profile.to_json }
  end
end

#updateObject



20
21
22
23
24
25
26
27
# File 'app/controllers/profiles_controller.rb', line 20

def update
  current_profile.update_attributes profile_params

  respond_to do |format|
    format.html{ redirect_to [profile_subject, :profile] }
    format.js
  end
end