activeadmin


Creating a new admin user in activeadmin


I'm using active admin on rails 4, I white-listed the parameters for admin users in the controller using:
ActiveAdmin.register AdminUser do
controller do
def permitted_params
params.permit(:admin_user => [:email, :password, :password_confirmation])
end
end
end
but when I try to add a new user, I get the error "cannot be blank" on the email and password fields. The logs read the following:
Unpermitted parameters: utf8, authenticity_token, commit
Unpermitted parameters: utf8, authenticity_token, admin_user, commit
Is there something I'm missing?
I was also facing the same issue.
Changing
params.permit(:admin_user => [:email, :password, :password_confirmation])
to
params.permit(:user => [:email, :password, :password_confirmation])
solved the issue. devise in active admin creates model with name user and in active admin user model, its mentioned as admin_user.
In my case it was happenning because i had a validation for an associated record on that model. Disabling that validation fixes it, will need to check how to disable validations for active admin only.

Related Links

How to customize site_title_link of active_admin?
rails mountable engine I used rails 4.2.8 and try to install active admin, It's give me error like this
Is it possible to render subscript and superscript in ActiveAdmin pages?
How to make a form row's label into a selection input for a different attribute in ActiveAdmin?
How to use Money filter in active admin?
Can a rubocop check be disabled on certain paths only?
Render plain form html from ActiveAdmin instead of full page
Customize ActiveAdmin Page based on Roles
NoMethodError error for search_methods activeadmin
rails concerns - superclass mismatch error with active_admin in gems list
How to filter by “is not” in active admin/ransack
Active Admin image upload with refile
AuthorizationAdapter in ActiveAdmin
ActiveAdmin and Rails Engine. How do you keep the path name the same?
Active admin defining scope for custom page
ActiveAdmin: Can I redirect the user to the index after they create/edit something?

Categories

HOME
extjs
class
typelite
yaml
adfs3.0
filesize
apk
twitter-fabric
dronekit-python
share
stored-procedures
sympy
jpa-criteria
reportviewer
yahoo
siesta
xbap
jpa-2.0
twisted
fosuserbundle
nose
cpu-usage
significance
spring-shell
node-webkit
social-tables
sqlplus
batch-rename
prompt
spreadsheetgear
sap-lumira
uilocalnotification
tf-idf
macromedia
amazon-cloudtrail
bitbake
guice
locks
google-play-developer-api
dotcms
location-services
john-the-ripper
cloudera-manager
android-canvas
spinner
stackpanel
love2d
xvfb
installanywhere
variable-variables
xll
assert
jacoco-maven-plugin
distributed-caching
robust
git-tfs
windows-media-player
xcglogger
node-apn
sigsegv
google-news
dynamics-crm-4
oracle-fusion-apps
allegro
mifos
xcode6.4
livecycle
wolfram-language
node.js-connect
mathnet
vaadin4spring
gwt-syncproxy
psd
vim-plugin
hmisc
physicsjs
uno
microsoft-expression-web
lifetime
adwords-apiv201402
qt5.4
nidaqmx
aho-corasick
full-text-indexing
android-2.3-gingerbread
windows-messages
pageviews
pre
facebook-game-groups
flv
axacropdf
mongo-jackson-mapper
spiral
tfs-sdk
smartfox
simplecov
xalan
idispatch
getproperty
system-information
zotonic
fitch-proofs
dropshadow
dynamic-c
litespeed
nsrangeexception
page-curl
canonicalization
css-friendly
ccl
jdownloader
downcasting
objectinstantiation

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App