Last active
February 16, 2016 17:11
-
-
Save jasper502/8fd16c31ee26667c5a16 to your computer and use it in GitHub Desktop.
Active Admin + Apartment + Devise = Bad News
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ActiveAdmin.register_page "Dashboard" do | |
| controller do | |
| before_filter do | |
| @new_company = Company.find_by(tenant_name: params[:company].try(:downcase)) | |
| if @new_company.present? | |
| session[:admin_tenant] = @new_company.tenant_name | |
| session[:admin_tenant_name] = @new_company.name | |
| else | |
| session[:admin_tenant] = Company.first.tenant_name | |
| session[:admin_tenant_name] = Company.first.name | |
| end | |
| current_tenant = Apartment::Tenant.switch!(session[:admin_tenant]) | |
| end | |
| end | |
| menu priority: 1, label: proc{ I18n.t("active_admin.dashboard") } | |
| content title: proc{ I18n.t("active_admin.dashboard") } do | |
| div class: "blank_slate_container", id: "dashboard_default_message" do | |
| span class: "blank_slate" do | |
| span I18n.t("active_admin.dashboard_welcome.welcome") | |
| small I18n.t("active_admin.dashboard_welcome.call_to_action") | |
| end | |
| end | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| GIT | |
| remote: git://github.com/activeadmin/activeadmin.git | |
| revision: 4349a2237894aae45569c5a7d25488081ba2d32f | |
| specs: | |
| activeadmin (1.0.0.pre2) | |
| arbre (~> 1.0, >= 1.0.2) | |
| bourbon | |
| coffee-rails | |
| formtastic (~> 3.1) | |
| formtastic_i18n | |
| inherited_resources (~> 1.6) | |
| jquery-rails | |
| jquery-ui-rails | |
| kaminari (~> 0.15) | |
| rails (>= 3.2, < 5.0) | |
| ransack (~> 1.3) | |
| sass-rails | |
| GEM | |
| remote: https://rubygems.org/ | |
| specs: | |
| CFPropertyList (2.3.2) | |
| aasm (4.5.1) | |
| actionmailer (4.2.4) | |
| actionpack (= 4.2.4) | |
| actionview (= 4.2.4) | |
| activejob (= 4.2.4) | |
| mail (~> 2.5, >= 2.5.4) | |
| rails-dom-testing (~> 1.0, >= 1.0.5) | |
| actionpack (4.2.4) | |
| actionview (= 4.2.4) | |
| activesupport (= 4.2.4) | |
| rack (~> 1.6) | |
| rack-test (~> 0.6.2) | |
| rails-dom-testing (~> 1.0, >= 1.0.5) | |
| rails-html-sanitizer (~> 1.0, >= 1.0.2) | |
| actionview (4.2.4) | |
| activesupport (= 4.2.4) | |
| builder (~> 3.1) | |
| erubis (~> 2.7.0) | |
| rails-dom-testing (~> 1.0, >= 1.0.5) | |
| rails-html-sanitizer (~> 1.0, >= 1.0.2) | |
| activejob (4.2.4) | |
| activesupport (= 4.2.4) | |
| globalid (>= 0.3.0) | |
| activemodel (4.2.4) | |
| activesupport (= 4.2.4) | |
| builder (~> 3.1) | |
| activerecord (4.2.4) | |
| activemodel (= 4.2.4) | |
| activesupport (= 4.2.4) | |
| arel (~> 6.0) | |
| activerecord-reputation-system (3.0.1) | |
| activesupport (4.2.4) | |
| i18n (~> 0.7) | |
| json (~> 1.7, >= 1.7.7) | |
| minitest (~> 5.1) | |
| thread_safe (~> 0.3, >= 0.3.4) | |
| tzinfo (~> 1.1) | |
| ancestry (2.1.0) | |
| activerecord (>= 3.0.0) | |
| apartment (1.0.2) | |
| activerecord (>= 3.1.2, < 5.0) | |
| rack (>= 1.3.6) | |
| apartment-sidekiq (0.2.0) | |
| apartment (~> 1.0) | |
| sidekiq (>= 2.11) | |
| arbre (1.0.3) | |
| activesupport (>= 3.0.0) | |
| arel (6.0.3) | |
| asset_sync (1.1.0) | |
| activemodel | |
| fog (>= 1.8.0) | |
| unf | |
| autoprefixer-rails (6.2.3) | |
| execjs | |
| json | |
| aws-sdk (2.2.14) | |
| aws-sdk-resources (= 2.2.14) | |
| aws-sdk-core (2.2.14) | |
| jmespath (~> 1.0) | |
| aws-sdk-resources (2.2.14) | |
| aws-sdk-core (= 2.2.14) | |
| bcrypt (3.1.10) | |
| better_errors (2.1.1) | |
| coderay (>= 1.0.0) | |
| erubis (>= 2.6.6) | |
| rack (>= 0.9.0) | |
| binding_of_caller (0.7.2) | |
| debug_inspector (>= 0.0.1) | |
| bootstrap-datepicker-rails (1.5.0) | |
| railties (>= 3.0) | |
| bootstrap-sass (3.3.6) | |
| autoprefixer-rails (>= 5.2.1) | |
| sass (>= 3.3.4) | |
| bourbon (4.2.6) | |
| sass (~> 3.4) | |
| thor (~> 0.19) | |
| builder (3.2.2) | |
| byebug (6.0.2) | |
| capistrano (3.4.0) | |
| i18n | |
| rake (>= 10.0.0) | |
| sshkit (~> 1.3) | |
| capistrano-bundler (1.1.0) | |
| capistrano (~> 3.0) | |
| sshkit (>= 1.2.0) | |
| capistrano-passenger (0.1.1) | |
| capistrano (~> 3.0) | |
| capistrano-rails (1.1.3) | |
| capistrano (~> 3.1) | |
| capistrano-bundler (~> 1.1) | |
| capistrano-rbenv (2.0.3) | |
| capistrano (~> 3.1) | |
| sshkit (~> 1.3) | |
| carrierwave (0.10.0) | |
| activemodel (>= 3.2.0) | |
| activesupport (>= 3.2.0) | |
| json (>= 1.7) | |
| mime-types (>= 1.16) | |
| carrierwave-aws (1.0.0) | |
| aws-sdk (~> 2.0) | |
| carrierwave (~> 0.7) | |
| celluloid (0.17.2) | |
| celluloid-essentials | |
| celluloid-extras | |
| celluloid-fsm | |
| celluloid-pool | |
| celluloid-supervision | |
| timers (>= 4.1.1) | |
| celluloid-essentials (0.20.5) | |
| timers (>= 4.1.1) | |
| celluloid-extras (0.20.5) | |
| timers (>= 4.1.1) | |
| celluloid-fsm (0.20.5) | |
| timers (>= 4.1.1) | |
| celluloid-pool (0.20.5) | |
| timers (>= 4.1.1) | |
| celluloid-supervision (0.20.5) | |
| timers (>= 4.1.1) | |
| cloudfront-signer (3.0.0) | |
| coderay (1.1.0) | |
| coffee-rails (4.1.0) | |
| coffee-script (>= 2.2.0) | |
| railties (>= 4.0.0, < 5.0) | |
| coffee-script (2.4.1) | |
| coffee-script-source | |
| execjs | |
| coffee-script-source (1.9.1.1) | |
| colorize (0.7.7) | |
| connection_pool (2.2.0) | |
| custom_error_message (1.1.1) | |
| debug_inspector (0.0.2) | |
| devise (3.5.2) | |
| bcrypt (~> 3.0) | |
| orm_adapter (~> 0.1) | |
| railties (>= 3.2.6, < 5) | |
| responders | |
| thread_safe (~> 0.1) | |
| warden (~> 1.2.3) | |
| devise_invitable (1.5.3) | |
| actionmailer (>= 3.2.6, < 5) | |
| devise (>= 3.2.0) | |
| domain_name (0.5.25) | |
| unf (>= 0.0.5, < 1.0.0) | |
| dotiw (3.0.1) | |
| actionpack (>= 3) | |
| i18n | |
| erubis (2.7.0) | |
| excon (0.45.4) | |
| execjs (2.6.0) | |
| fast_stack (0.1.0) | |
| rake | |
| rake-compiler | |
| fission (0.5.0) | |
| CFPropertyList (~> 2.2) | |
| flamegraph (0.1.0) | |
| fast_stack | |
| fog (1.35.0) | |
| fog-aliyun | |
| fog-atmos | |
| fog-aws (>= 0.6.0) | |
| fog-brightbox (~> 0.4) | |
| fog-core (~> 1.32) | |
| fog-dynect (~> 0.0.2) | |
| fog-ecloud (~> 0.1) | |
| fog-google (>= 0.1.1) | |
| fog-json | |
| fog-local | |
| fog-powerdns (>= 0.1.1) | |
| fog-profitbricks | |
| fog-radosgw (>= 0.0.2) | |
| fog-riakcs | |
| fog-sakuracloud (>= 0.0.4) | |
| fog-serverlove | |
| fog-softlayer | |
| fog-storm_on_demand | |
| fog-terremark | |
| fog-vmfusion | |
| fog-voxel | |
| fog-xenserver | |
| fog-xml (~> 0.1.1) | |
| ipaddress (~> 0.5) | |
| nokogiri | |
| fog-aliyun (0.1.0) | |
| fog-core (~> 1.27) | |
| fog-json (~> 1.0) | |
| ipaddress (~> 0.8) | |
| xml-simple (~> 1.1) | |
| fog-atmos (0.1.0) | |
| fog-core | |
| fog-xml | |
| fog-aws (0.7.6) | |
| fog-core (~> 1.27) | |
| fog-json (~> 1.0) | |
| fog-xml (~> 0.1) | |
| ipaddress (~> 0.8) | |
| fog-brightbox (0.9.0) | |
| fog-core (~> 1.22) | |
| fog-json | |
| inflecto (~> 0.0.2) | |
| fog-core (1.32.1) | |
| builder | |
| excon (~> 0.45) | |
| formatador (~> 0.2) | |
| mime-types | |
| net-scp (~> 1.1) | |
| net-ssh (>= 2.1.3) | |
| fog-dynect (0.0.2) | |
| fog-core | |
| fog-json | |
| fog-xml | |
| fog-ecloud (0.3.0) | |
| fog-core | |
| fog-xml | |
| fog-google (0.1.1) | |
| fog-core | |
| fog-json | |
| fog-xml | |
| fog-json (1.0.2) | |
| fog-core (~> 1.0) | |
| multi_json (~> 1.10) | |
| fog-local (0.2.1) | |
| fog-core (~> 1.27) | |
| fog-powerdns (0.1.1) | |
| fog-core (~> 1.27) | |
| fog-json (~> 1.0) | |
| fog-xml (~> 0.1) | |
| fog-profitbricks (0.0.5) | |
| fog-core | |
| fog-xml | |
| nokogiri | |
| fog-radosgw (0.0.4) | |
| fog-core (>= 1.21.0) | |
| fog-json | |
| fog-xml (>= 0.0.1) | |
| fog-riakcs (0.1.0) | |
| fog-core | |
| fog-json | |
| fog-xml | |
| fog-sakuracloud (1.3.3) | |
| fog-core | |
| fog-json | |
| fog-serverlove (0.1.2) | |
| fog-core | |
| fog-json | |
| fog-softlayer (1.0.2) | |
| fog-core | |
| fog-json | |
| fog-storm_on_demand (0.1.1) | |
| fog-core | |
| fog-json | |
| fog-terremark (0.1.0) | |
| fog-core | |
| fog-xml | |
| fog-vmfusion (0.1.0) | |
| fission | |
| fog-core | |
| fog-voxel (0.1.0) | |
| fog-core | |
| fog-xml | |
| fog-xenserver (0.2.2) | |
| fog-core | |
| fog-xml | |
| fog-xml (0.1.2) | |
| fog-core | |
| nokogiri (~> 1.5, >= 1.5.11) | |
| font-awesome-rails (4.4.0.0) | |
| railties (>= 3.2, < 5.0) | |
| formatador (0.2.5) | |
| formtastic (3.1.3) | |
| actionpack (>= 3.2.13) | |
| formtastic_i18n (0.5.0) | |
| friendly_id (5.1.0) | |
| activerecord (>= 4.0.0) | |
| fullcalendar-rails (2.6.0.0) | |
| jquery-rails (>= 4.0.5, < 5.0.0) | |
| jquery-ui-rails (>= 5.0.2) | |
| momentjs-rails (>= 2.9.0) | |
| globalid (0.3.6) | |
| activesupport (>= 4.1.0) | |
| has_scope (0.6.0) | |
| actionpack (>= 3.2, < 5) | |
| activesupport (>= 3.2, < 5) | |
| hirb (0.7.3) | |
| hitimes (1.2.3) | |
| http-cookie (1.0.2) | |
| domain_name (~> 0.5) | |
| i18n (0.7.0) | |
| ice_cube (0.13.2) | |
| inflecto (0.0.2) | |
| inherited_resources (1.6.0) | |
| actionpack (>= 3.2, < 5) | |
| has_scope (~> 0.6.0.rc) | |
| railties (>= 3.2, < 5) | |
| responders | |
| ipaddress (0.8.0) | |
| jbuilder (2.3.2) | |
| activesupport (>= 3.0.0, < 5) | |
| multi_json (~> 1.2) | |
| jmespath (1.1.3) | |
| jquery-rails (4.0.5) | |
| rails-dom-testing (~> 1.0) | |
| railties (>= 4.2.0) | |
| thor (>= 0.14, < 2.0) | |
| jquery-ui-rails (5.0.5) | |
| railties (>= 3.2.16) | |
| json (1.8.3) | |
| kaminari (0.16.3) | |
| actionpack (>= 3.0.0) | |
| activesupport (>= 3.0.0) | |
| lograge (0.3.4) | |
| actionpack (>= 3) | |
| activesupport (>= 3) | |
| railties (>= 3) | |
| loofah (2.0.3) | |
| nokogiri (>= 1.5.9) | |
| mail (2.6.3) | |
| mime-types (>= 1.16, < 3) | |
| mandrill-api (1.0.53) | |
| excon (>= 0.16.0, < 1.0) | |
| json (>= 1.7.7, < 2.0) | |
| mime-types (2.6.2) | |
| mini_magick (4.3.6) | |
| mini_portile (0.6.2) | |
| minitest (5.8.1) | |
| momentjs-rails (2.11.0) | |
| railties (>= 3.1) | |
| multi_json (1.11.2) | |
| net-scp (1.2.1) | |
| net-ssh (>= 2.6.5) | |
| net-ssh (3.0.1) | |
| netrc (0.10.3) | |
| nokogiri (1.6.6.2) | |
| mini_portile (~> 0.6.0) | |
| orm_adapter (0.5.0) | |
| paper_trail (4.0.1) | |
| activerecord (>= 3.0, < 6.0) | |
| activesupport (>= 3.0, < 6.0) | |
| request_store (~> 1.1) | |
| pg (0.18.3) | |
| pg_array_parser (0.0.9) | |
| phony (2.15.4) | |
| phony_rails (0.12.10) | |
| activesupport (>= 3.0) | |
| phony (~> 2.12) | |
| poly_belongs_to (0.2.8) | |
| rails (>= 3.1, < 6) | |
| polyamorous (1.2.0) | |
| activerecord (>= 3.0) | |
| postgres_ext (2.4.1) | |
| activerecord (>= 4.0.0) | |
| arel (>= 4.0.1) | |
| pg_array_parser (~> 0.0.9) | |
| pundit (1.0.1) | |
| activesupport (>= 3.0.0) | |
| quiet_assets (1.1.0) | |
| railties (>= 3.1, < 5.0) | |
| rack (1.6.4) | |
| rack-mini-profiler (0.9.7) | |
| rack (>= 1.1.3) | |
| rack-protection (1.5.3) | |
| rack | |
| rack-test (0.6.3) | |
| rack (>= 1.0) | |
| rails (4.2.4) | |
| actionmailer (= 4.2.4) | |
| actionpack (= 4.2.4) | |
| actionview (= 4.2.4) | |
| activejob (= 4.2.4) | |
| activemodel (= 4.2.4) | |
| activerecord (= 4.2.4) | |
| activesupport (= 4.2.4) | |
| bundler (>= 1.3.0, < 2.0) | |
| railties (= 4.2.4) | |
| sprockets-rails | |
| rails-deprecated_sanitizer (1.0.3) | |
| activesupport (>= 4.2.0.alpha) | |
| rails-dom-testing (1.0.7) | |
| activesupport (>= 4.2.0.beta, < 5.0) | |
| nokogiri (~> 1.6.0) | |
| rails-deprecated_sanitizer (>= 1.0.1) | |
| rails-html-sanitizer (1.0.2) | |
| loofah (~> 2.0) | |
| railties (4.2.4) | |
| actionpack (= 4.2.4) | |
| activesupport (= 4.2.4) | |
| rake (>= 0.8.7) | |
| thor (>= 0.18.1, < 2.0) | |
| rake (10.4.2) | |
| rake-compiler (0.9.5) | |
| rake | |
| ransack (1.7.0) | |
| actionpack (>= 3.0) | |
| activerecord (>= 3.0) | |
| activesupport (>= 3.0) | |
| i18n | |
| polyamorous (~> 1.2) | |
| rdoc (4.2.0) | |
| recurring_select (2.0.0) | |
| coffee-rails (>= 3.1) | |
| ice_cube (>= 0.11) | |
| jquery-rails (>= 3.0) | |
| rails (>= 3.2) | |
| sass-rails (>= 4.0) | |
| redis (3.2.1) | |
| redis-namespace (1.5.2) | |
| redis (~> 3.0, >= 3.0.4) | |
| request_store (1.2.1) | |
| responders (2.1.0) | |
| railties (>= 4.2.0, < 5) | |
| rest-client (1.8.0) | |
| http-cookie (>= 1.0.2, < 2.0) | |
| mime-types (>= 1.16, < 3.0) | |
| netrc (~> 0.7) | |
| sass (3.4.18) | |
| sass-rails (5.0.4) | |
| railties (>= 4.0.0, < 5.0) | |
| sass (~> 3.1) | |
| sprockets (>= 2.8, < 4.0) | |
| sprockets-rails (>= 2.0, < 4.0) | |
| tilt (>= 1.1, < 3) | |
| sdoc (0.4.1) | |
| json (~> 1.7, >= 1.7.7) | |
| rdoc (~> 4.0) | |
| select2-rails (4.0.1) | |
| thor (~> 0.14) | |
| sidekiq (3.5.1) | |
| celluloid (~> 0.17.2) | |
| connection_pool (~> 2.2, >= 2.2.0) | |
| json (~> 1.0) | |
| redis (~> 3.2, >= 3.2.1) | |
| redis-namespace (~> 1.5, >= 1.5.2) | |
| simple_form (3.2.0) | |
| actionpack (~> 4.0) | |
| activemodel (~> 4.0) | |
| sinatra (1.4.6) | |
| rack (~> 1.4) | |
| rack-protection (~> 1.4) | |
| tilt (>= 1.3, < 3) | |
| spring (1.4.0) | |
| sprockets (3.3.5) | |
| rack (> 1, < 3) | |
| sprockets-rails (2.3.3) | |
| actionpack (>= 3.0) | |
| activesupport (>= 3.0) | |
| sprockets (>= 2.8, < 4.0) | |
| sshkit (1.7.1) | |
| colorize (>= 0.7.0) | |
| net-scp (>= 1.1.2) | |
| net-ssh (>= 2.8.0) | |
| syslogger (1.6.4) | |
| thor (0.19.1) | |
| thread_safe (0.3.5) | |
| tilt (2.0.1) | |
| time_diff (0.3.0) | |
| activesupport | |
| i18n | |
| timers (4.1.1) | |
| hitimes | |
| turbolinks (2.5.3) | |
| coffee-rails | |
| tzinfo (1.2.2) | |
| thread_safe (~> 0.1) | |
| uglifier (2.7.2) | |
| execjs (>= 0.3.0) | |
| json (>= 1.8.0) | |
| unf (0.1.4) | |
| unf_ext | |
| unf_ext (0.0.7.1) | |
| warden (1.2.3) | |
| rack (>= 1.0) | |
| web-console (2.2.1) | |
| activemodel (>= 4.0) | |
| binding_of_caller (>= 0.7.2) | |
| railties (>= 4.0) | |
| sprockets-rails (>= 2.0, < 4.0) | |
| wicked_pdf (1.0.3) | |
| will_paginate (3.0.7) | |
| will_paginate-bootstrap (1.0.1) | |
| will_paginate (>= 3.0.3) | |
| wkhtmltopdf-binary (0.9.9.3) | |
| xml-simple (1.1.5) | |
| PLATFORMS | |
| ruby | |
| DEPENDENCIES | |
| aasm | |
| activeadmin! | |
| activerecord-reputation-system | |
| ancestry | |
| apartment (~> 1.0, >= 1.0.2) | |
| apartment-sidekiq (~> 0.2.0) | |
| asset_sync (~> 1.1) | |
| better_errors | |
| binding_of_caller | |
| bootstrap-datepicker-rails | |
| bootstrap-sass (~> 3.3.6) | |
| byebug | |
| capistrano (~> 3.4.0) | |
| capistrano-bundler (= 1.1.0) | |
| capistrano-passenger | |
| capistrano-rails (= 1.1.3) | |
| capistrano-rbenv | |
| carrierwave | |
| carrierwave-aws | |
| cloudfront-signer | |
| coffee-rails (~> 4.1.0) | |
| custom_error_message (~> 1.1.1) | |
| devise (~> 3.5, >= 3.5.2) | |
| devise_invitable (~> 1.5, >= 1.5.3) | |
| dotiw | |
| flamegraph | |
| font-awesome-rails (~> 4.4.0.0) | |
| friendly_id (~> 5.1.0) | |
| fullcalendar-rails | |
| hirb | |
| ice_cube | |
| jbuilder (~> 2.0) | |
| jquery-rails | |
| lograge (~> 0.3.1) | |
| mandrill-api (~> 1.0.53) | |
| mini_magick | |
| momentjs-rails | |
| paper_trail (~> 4.0.0) | |
| pg | |
| phony_rails (~> 0.12.10) | |
| poly_belongs_to | |
| postgres_ext (~> 2.4, >= 2.4.1) | |
| pundit (~> 1.0, >= 1.0.1) | |
| quiet_assets | |
| rack-mini-profiler | |
| rails (= 4.2.4) | |
| ransack | |
| recurring_select | |
| rest-client (~> 1.8) | |
| sass-rails (~> 5.0) | |
| sdoc (~> 0.4.0) | |
| select2-rails | |
| sidekiq (~> 3.5, >= 3.5.1) | |
| simple_form | |
| sinatra | |
| spring | |
| syslogger (~> 1.6.0) | |
| time_diff | |
| turbolinks | |
| uglifier (>= 1.3.0) | |
| web-console (~> 2.0) | |
| wicked_pdf | |
| will_paginate (~> 3.0.6) | |
| will_paginate-bootstrap (~> 1.0, >= 1.0.1) | |
| wkhtmltopdf-binary | |
| BUNDLED WITH | |
| 1.10.6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ActiveAdmin.register Location do | |
| controller do | |
| before_filter do | |
| current_tenant = Apartment::Tenant.switch!(session[:admin_tenant]) | |
| end | |
| end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment