Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,19 @@

class ApplicationController < ActionController::Base
before_action :set_paper_trail_whodunnit

protected

def after_sign_in_path_for(resource)
stored_location_for(resource) ||
if resource.admin?
admin_health_insurances_path
else
api_v1_event_procedures_path
end
end

def after_sign_up_path_for(resource)
after_sign_in_path_for(resource)
end
end
2 changes: 2 additions & 0 deletions app/views/layouts/application.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
</head>

<body>
<p class = "notice"><%= notice%></p>
<p class = "alert"><%= alert%></p>
<%= yield %>
</body>
</html>
Loading