Class: Kiqr::Users::Settings::ProfilesController
- Inherits:
-
BaseController
- Object
- BaseController
- Kiqr::Users::Settings::ProfilesController
- Defined in:
- app/controllers/kiqr/users/settings/profiles_controller.rb
Instance Method Summary collapse
- #cancel_pending_email ⇒ Object
-
#show ⇒ Object
GET /settings.
-
#update ⇒ Object
PATCH /settings/profile.
Instance Method Details
#cancel_pending_email ⇒ Object
22 23 24 25 26 27 28 29 30 |
# File 'app/controllers/kiqr/users/settings/profiles_controller.rb', line 22 def cancel_pending_email @user.cancel_pending_email_change! (:notice, :email_change_pending_cancelled) render turbo_stream: [ turbo_stream.remove("pending_email_notification"), ] end |
#show ⇒ Object
GET /settings
9 10 |
# File 'app/controllers/kiqr/users/settings/profiles_controller.rb', line 9 def show end |
#update ⇒ Object
PATCH /settings/profile
13 14 15 16 17 18 19 20 |
# File 'app/controllers/kiqr/users/settings/profiles_controller.rb', line 13 def update if @user.update(user_profile_params) (:success, :profile_updated) redirect_to user_settings_profile_path else render :show, status: :unprocessable_content end end |