-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can not edit or create new records in rails admin #2830
Comments
I'm getting the same too, and I think this happened after I upgraded my gems, try reverting to older version |
Yep, the problem is on |
Not reproducible here, can you make the problem happen by using brand-new Rails app? |
Just installed a fresh rails instance, and was able to replicate same issue. Rolling back to 1.1.0 resolved it for me also. Using papertrail and devise if that helps any? |
I just did fresh rails instance with papertrail and devise and I can create new record. I'm not able to reproducible. |
I am having the same issue with |
I can also reproduce it with a fresh Rails app using --api. Removing The delete problem still persists though. |
Also reported here: rails/rails#21948 (comment) |
The rails core issue seems to happens when you close the page and open again, so it might be unrelated. |
I've considered it, of course, as well as the secondary calls (e.g. pjax) that may be recreating the token, and two users accessing the same site with the same admin_user.id. |
Fixed this by one or both of:
|
I have rails 5.1.1 and no nginx. |
I just upgraded from Rails 5.0.0 to 5.1.0 because of this error and the problem still persists (in development). I'm running Puma locally not Nginx. Adding new records:
Downgrading to RailsAdmin 1.1.0 solved the first issue but not the second - I still can't update records.
UPDATE:
The routing issue was caused by the MethodOverride Rack middleware being left out - so when Rails receives forms with the hidden
These workarounds work with both Administrate and RailsAdmin 1.2.0. |
@lesliev Dude, you saved my day. |
Fixed by #3006. |
I had this issue and adding This issue was present in my recently deployed production server (nginx+puma+rails), SSL enabled. I fixed this by adding
This also solved getting "connection not secure" in Chrome even though my certificate was valid. It's not a rails_admin problem but it was raising up there. My settings |
I have a problem with crating and updating records with rails_admin. For update I get the 404 error, where POST actions is not found:
{"status":404,"error":"Not Found","exception":"#\u003cActionController::RoutingError: No route matches [POST] \"/admin/api_key/1/edit\"....
But if i look in the routes file, i see it's registered at PUT method.
For creating new record i get:
{"status":422,"error":"Unprocessable Entity","exception":"#\u003cActionController::InvalidAuthenticityToken: ActionController::InvalidAuthenticityToken\u003e","traces":{"Application Trace":[],"Framewor....
my config file:
RailsAdmin.config do |config| config.actions do dashboard # mandatory index # mandatory new export bulk_delete show edit delete show_in_app end end
my route setting:
Rails.application.routes.draw do mount RailsAdmin::Engine => '/admin', as: 'rails_admin'
The text was updated successfully, but these errors were encountered: