Skip to content

Instantly share code, notes, and snippets.

@creich
Created October 5, 2012 10:54
Show Gist options
  • Save creich/3839237 to your computer and use it in GitHub Desktop.
Save creich/3839237 to your computer and use it in GitHub Desktop.
def show_edit
time_logs = TimeLog.where(:id => params[:time_log_ids]).all
render :update do |page|
time_logs.each do |item|
@time_log = item
page.replace_html 'entry-'+item.id.to_s, :partial => 'time_logs/edit_form'
end
end
end
Started GET "/time_logs/show_edit?time_log_ids%5B%5D=1" for 127.0.0.1 at 2012-10-05 12:52:49 +0200
Processing by TimeLogsController#show_edit as JS
Parameters: {"time_log_ids"=>["1"]}
(0.0ms) SELECT MAX("settings"."updated_on") AS max_id FROM "settings"
User Load (1.0ms) SELECT "users".* FROM "users" WHERE "users"."type" IN ('User', 'AnonymousUser') AND "users"."id" = ? AND (users.status = 1) LIMIT 1 [["id", 1]]
Current user: admin (id=1)
TimeLog Load (0.0ms) SELECT "time_logs".* FROM "time_logs" WHERE "time_logs"."id" IN (1)
Missing template, responding with 404
Rendered common/error.html.erb (1.0ms)
Completed 404 Not Found in 63ms (Views: 3.0ms | ActiveRecord: 0.0ms)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment