ActiveAdmin Addons
ActiveAdmin Addons will extend your ActiveAdmin and enable a set of addons you can optionally use to improve the ActiveAdmin UI and make it awesome.
What you get:
- Range Filter: Filter your results using a numeric range (i.e. age between 18-30).
- Select2: Cool select boxes for everyone.
- Paperclip Integration: Show thumbnails or icons on your lists.
- AASM Integration: Nice looking tags for states.
- Enum Integration: Nice looking tags for enums.
- Boolean Values: Beautiful boolean values.
- Number Formatting: Format you currencies with ease.
- List: Show Arrays or Hashes like a list.
- Color Picker: Select colors from a pretty popup.
- Date Time Picker: Pick date and time comfortably.
Table of Contents
Installation
Add this line to your application's Gemfile:
gem 'activeadmin_addons'
And then execute:
$ bundle
After that, run the generator:
$ rails g activeadmin_addons:install
check here to see more information about this generator.
Default changes to behaviour
Installing this gem will enable the following changes by default:
- The default date input will be
:datepicker
instead of:date_select
- Filters and selects will offer integration with enumerize
- All select boxes will use select2
Addons
Range Filter
To filter based on a range of values you can use range_select
like this:
filter :number, as: :range_select
Select2
Default
With select2 the select control looks nicer, it works great with large collections and multiple selection.
Tagging
Using tags input, you can add tags using select2.
Selected List
This form control allows you to handle your many to many associations.
Ajax Search
Using search_select
input, you can easily add ajax search to activeadmin
Nested Select
Using nested_select
input, you can build related select inputs.
Paperclip Integration
For Images
Displays a paperclip image into index and show views
For Any Attachment
Displays a paperclip link with attachment related icon into index and show views.
AASM Integration
You can show aasm values as active admin tags.
Enum Integration
You can show Rails' built in enums
or enumerize values as active admin tags.
Boolean Values
Modifies how boolean values are displayed
Number Formatting
You can show numbers with format supported by Rails NumberHelper
List
You can show Array
or Hash
values as html lists.
Color Picker
You can pick colors using JQuery Palette Color Picker
f.input :color, as: :color_picker
Date Time Picker
You can pick dates with time using the xdan's jQuery Plugin Date and Time Picker
f.input :updated_at, as: :date_time_picker
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request
Credits
Thank you contributors!
activeadmin_addons is maintained by platanus.
License
ActiveAdminAddons is © 2016 Platanus, spa. It is free software and may be redistributed under the terms specified in the LICENSE file.