Skip to content

Commit

Permalink
added rails admin for back ground job
Browse files Browse the repository at this point in the history
  • Loading branch information
hlee committed Feb 9, 2014
1 parent 6bbfe1a commit c0c899b
Show file tree
Hide file tree
Showing 4 changed files with 69 additions and 0 deletions.
1 change: 1 addition & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,4 @@ end
# Use debugger
gem 'debugger', group: [:development, :test]
gem 'pry-nav', group: :development
gem 'rails_admin'
33 changes: 33 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ GEM
warden (~> 1.2.3)
erubis (2.7.0)
execjs (2.0.2)
font-awesome-rails (4.0.3.1)
railties (>= 3.2, < 5.0)
haml (4.0.5)
tilt
hike (1.2.3)
i18n (0.6.9)
jbuilder (1.5.3)
Expand All @@ -60,14 +64,23 @@ GEM
jquery-rails (3.1.0)
railties (>= 3.0, < 5.0)
thor (>= 0.14, < 2.0)
jquery-ui-rails (4.1.1)
railties (>= 3.1.0)
json (1.8.1)
kaminari (0.15.1)
actionpack (>= 3.0.0)
activesupport (>= 3.0.0)
mail (2.5.4)
mime-types (~> 1.16)
treetop (~> 1.4.8)
method_source (0.8.2)
mime-types (1.25.1)
mini_portile (0.5.2)
minitest (4.7.5)
multi_json (1.8.4)
nested_form (0.3.2)
nokogiri (1.6.1)
mini_portile (~> 0.5.0)
orm_adapter (0.5.0)
polyglot (0.3.3)
pry (0.9.12.6)
Expand All @@ -77,6 +90,9 @@ GEM
pry-nav (0.2.3)
pry (~> 0.9.10)
rack (1.5.2)
rack-pjax (0.7.0)
nokogiri (~> 1.5)
rack (~> 1.3)
rack-test (0.6.2)
rack (>= 1.0)
rails (4.0.2)
Expand All @@ -87,6 +103,20 @@ GEM
bundler (>= 1.3.0, < 2.0)
railties (= 4.0.2)
sprockets-rails (~> 2.0.0)
rails_admin (0.6.1)
builder (~> 3.1)
coffee-rails (~> 4.0)
font-awesome-rails (>= 3.0)
haml (~> 4.0)
jquery-rails (~> 3.0)
jquery-ui-rails (~> 4.0)
kaminari (~> 0.14)
nested_form (~> 0.3)
rack-pjax (~> 0.7)
rails (~> 4.0)
remotipart (~> 1.0)
safe_yaml (~> 1.0)
sass-rails (~> 4.0)
railties (4.0.2)
actionpack (= 4.0.2)
activesupport (= 4.0.2)
Expand All @@ -95,6 +125,8 @@ GEM
rake (10.1.1)
rdoc (4.1.1)
json (~> 1.4)
remotipart (1.2.1)
safe_yaml (1.0.1)
sass (3.2.14)
sass-rails (4.0.1)
railties (>= 4.0.0, < 5.0)
Expand Down Expand Up @@ -141,6 +173,7 @@ DEPENDENCIES
jquery-rails
pry-nav
rails (= 4.0.2)
rails_admin
sass-rails (~> 4.0.0)
sdoc
sqlite3
Expand Down
34 changes: 34 additions & 0 deletions config/initializers/rails_admin.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
RailsAdmin.config do |config|

### Popular gems integration

## == Devise ==
# config.authenticate_with do
# warden.authenticate! scope: :user
# end
# config.current_user_method(&:current_user)

## == Cancan ==
# config.authorize_with :cancan

## == PaperTrail ==
# config.audit_with :paper_trail, 'User', 'PaperTrail::Version' # PaperTrail >= 3.0.0

### More at https://github.com/sferik/rails_admin/wiki/Base-configuration

config.actions do
dashboard # mandatory
index # mandatory
new
export
bulk_delete
show
edit
delete
show_in_app

## With an audit adapter, you can add:
# history_index
# history_show
end
end
1 change: 1 addition & 0 deletions config/routes.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Insight2::Application.routes.draw do
mount RailsAdmin::Engine => '/admin', :as => 'rails_admin'
devise_for :users
get '/wel', to: 'welcome#index'
get '/req_list', to: 'welcome#request_list', as: "request_list"
Expand Down

0 comments on commit c0c899b

Please sign in to comment.