activeadmin 2.1.0 → 2.5.0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of activeadmin might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/CHANGELOG.md +112 -27
- data/CONTRIBUTING.md +50 -26
- data/README.md +8 -1
- data/app/assets/javascripts/active_admin/base.js +509 -0
- data/app/assets/stylesheets/active_admin/_base.scss +29 -29
- data/app/assets/stylesheets/active_admin/_header.scss +3 -5
- data/app/assets/stylesheets/active_admin/_mixins.scss +1 -1
- data/{vendor → app}/assets/stylesheets/active_admin/_normalize.scss +0 -0
- data/app/assets/stylesheets/active_admin/components/_tables.scss +1 -2
- data/app/assets/stylesheets/active_admin/mixins/_all.scss +8 -8
- data/app/assets/stylesheets/active_admin/mixins/_variables.scss +5 -0
- data/app/assets/stylesheets/active_admin/print.scss +2 -2
- data/app/assets/stylesheets/active_admin/structure/_main_structure.scss +1 -1
- data/app/javascript/active_admin/base.js +19 -0
- data/app/{assets/javascripts/active_admin/ext/jquery-ui.es6 → javascript/active_admin/ext/jquery-ui.js} +0 -0
- data/app/{assets/javascripts/active_admin/ext/jquery.es6 → javascript/active_admin/ext/jquery.js} +0 -0
- data/app/{assets/javascripts/active_admin/lib/batch_actions.es6 → javascript/active_admin/initializers/batch-actions.js} +9 -3
- data/app/javascript/active_admin/initializers/checkbox-toggler.js +3 -0
- data/app/{assets/javascripts/active_admin/initializers/datepicker.es6 → javascript/active_admin/initializers/datepicker.js} +0 -0
- data/app/javascript/active_admin/initializers/dropdown-menu.js +9 -0
- data/app/javascript/active_admin/initializers/filters.js +10 -0
- data/app/{assets/javascripts/active_admin/lib/has_many.es6 → javascript/active_admin/initializers/has-many.js} +0 -0
- data/app/javascript/active_admin/initializers/per-page.js +13 -0
- data/app/javascript/active_admin/initializers/table-checkbox-toggler.js +3 -0
- data/app/{assets/javascripts/active_admin/initializers/tabs.es6 → javascript/active_admin/initializers/tabs.js} +0 -0
- data/app/{assets/javascripts/active_admin/lib/checkbox-toggler.es6 → javascript/active_admin/lib/checkbox-toggler.js} +2 -2
- data/app/{assets/javascripts/active_admin/lib/dropdown-menu.es6 → javascript/active_admin/lib/dropdown-menu.js} +2 -9
- data/app/javascript/active_admin/lib/filters.js +39 -0
- data/app/{assets/javascripts/active_admin/lib/modal_dialog.es6 → javascript/active_admin/lib/modal-dialog.js} +3 -1
- data/app/javascript/active_admin/lib/per-page.js +38 -0
- data/app/{assets/javascripts/active_admin/lib/table-checkbox-toggler.es6 → javascript/active_admin/lib/table-checkbox-toggler.js} +4 -2
- data/app/javascript/active_admin/lib/utils.js +40 -0
- data/app/views/kaminari/active_admin_countless/_first_page.html.erb +11 -0
- data/app/views/kaminari/active_admin_countless/_gap.html.erb +8 -0
- data/app/views/kaminari/active_admin_countless/_next_page.html.erb +11 -0
- data/app/views/kaminari/active_admin_countless/_page.html.erb +12 -0
- data/app/views/kaminari/active_admin_countless/_paginator.html.erb +24 -0
- data/app/views/kaminari/active_admin_countless/_prev_page.html.erb +11 -0
- data/config/locales/ar.yml +3 -2
- data/config/locales/az.yml +138 -0
- data/config/locales/bg.yml +1 -0
- data/config/locales/bs.yml +1 -0
- data/config/locales/ca.yml +1 -1
- data/config/locales/cs.yml +1 -0
- data/config/locales/da.yml +1 -0
- data/config/locales/de-CH.yml +1 -0
- data/config/locales/de.yml +19 -0
- data/config/locales/el.yml +1 -0
- data/config/locales/en-CA.yml +1 -0
- data/config/locales/en-GB.yml +1 -0
- data/config/locales/en.yml +1 -0
- data/config/locales/eo.yml +1 -0
- data/config/locales/es-MX.yml +1 -0
- data/config/locales/es.yml +1 -0
- data/config/locales/fa.yml +1 -0
- data/config/locales/fi.yml +1 -0
- data/config/locales/fr.yml +2 -1
- data/config/locales/he.yml +1 -0
- data/config/locales/hr.yml +1 -0
- data/config/locales/hu.yml +1 -0
- data/config/locales/id.yml +1 -0
- data/config/locales/it.yml +1 -0
- data/config/locales/ja.yml +1 -0
- data/config/locales/ko.yml +1 -0
- data/config/locales/lt.yml +1 -0
- data/config/locales/lv.yml +1 -0
- data/config/locales/mk.yml +134 -0
- data/config/locales/nb.yml +1 -0
- data/config/locales/nl.yml +1 -0
- data/config/locales/pl.yml +1 -0
- data/config/locales/pt-BR.yml +1 -0
- data/config/locales/pt-PT.yml +1 -0
- data/config/locales/ro.yml +1 -0
- data/config/locales/ru.yml +1 -0
- data/config/locales/sk.yml +60 -0
- data/config/locales/sv-SE.yml +1 -0
- data/config/locales/tr.yml +1 -0
- data/config/locales/uk.yml +1 -0
- data/config/locales/vi.yml +1 -0
- data/config/locales/zh-CN.yml +1 -0
- data/config/locales/zh-TW.yml +1 -0
- data/docs/1-general-configuration.md +20 -0
- data/docs/12-arbre-components.md +13 -0
- data/docs/13-authorization-adapter.md +2 -2
- data/docs/2-resource-customization.md +1 -1
- data/docs/3-index-pages/index-as-table.md +7 -0
- data/docs/Gemfile +0 -1
- data/docs/Gemfile.lock +58 -58
- data/docs/_config.yml +2 -0
- data/docs/_includes/top-menu.html +2 -2
- data/docs/index.html +108 -7
- data/docs/stylesheets/main.css +29 -0
- data/lib/active_admin.rb +0 -1
- data/lib/active_admin/application.rb +12 -3
- data/lib/active_admin/batch_actions/resource_extension.rb +5 -1
- data/lib/active_admin/controller_action.rb +2 -1
- data/lib/active_admin/csv_builder.rb +3 -2
- data/lib/active_admin/dependency.rb +0 -4
- data/lib/active_admin/error.rb +3 -1
- data/lib/active_admin/filters/active_filter.rb +3 -4
- data/lib/active_admin/filters/resource_extension.rb +24 -0
- data/lib/active_admin/generators/boilerplate.rb +12 -4
- data/lib/active_admin/inputs/filters/date_range_input.rb +4 -4
- data/lib/active_admin/namespace_settings.rb +13 -0
- data/lib/active_admin/order_clause.rb +1 -1
- data/lib/active_admin/page_presenter.rb +2 -1
- data/lib/active_admin/pundit_adapter.rb +7 -3
- data/lib/active_admin/resource.rb +16 -2
- data/lib/active_admin/resource/belongs_to.rb +6 -1
- data/lib/active_admin/resource/model.rb +15 -0
- data/lib/active_admin/resource/routes.rb +11 -3
- data/lib/active_admin/resource_controller.rb +2 -0
- data/lib/active_admin/resource_controller/decorators.rb +2 -2
- data/lib/active_admin/resource_controller/polymorphic_routes.rb +37 -0
- data/lib/active_admin/router.rb +2 -1
- data/lib/active_admin/scope.rb +7 -3
- data/lib/active_admin/sidebar_section.rb +3 -1
- data/lib/active_admin/version.rb +1 -1
- data/lib/active_admin/view_helpers/breadcrumb_helper.rb +2 -2
- data/lib/active_admin/view_helpers/display_helper.rb +3 -2
- data/lib/active_admin/views/components/paginated_collection.rb +3 -2
- data/lib/active_admin/views/components/status_tag.rb +5 -1
- data/lib/active_admin/views/components/table_for.rb +1 -0
- data/lib/active_admin/views/index_as_table.rb +7 -0
- data/lib/active_admin/views/pages/base.rb +1 -1
- data/lib/active_admin/views/pages/index.rb +1 -0
- data/lib/generators/active_admin/install/templates/active_admin.rb.erb +14 -1
- data/lib/generators/active_admin/resource/templates/admin.rb.erb +40 -37
- data/lib/ransack_ext.rb +2 -2
- metadata +38 -45
- data/app/assets/images/active_admin/nested_menu_arrow.gif +0 -0
- data/app/assets/images/active_admin/nested_menu_arrow_dark.gif +0 -0
- data/app/assets/images/active_admin/orderable.png +0 -0
- data/app/assets/javascripts/active_admin/base.es6 +0 -23
- data/app/assets/javascripts/active_admin/initializers/filters.es6 +0 -45
- data/app/assets/javascripts/active_admin/lib/active_admin.es6 +0 -41
- data/app/assets/javascripts/active_admin/lib/per_page.es6 +0 -47
data/config/locales/hu.yml
CHANGED
data/config/locales/id.yml
CHANGED
data/config/locales/it.yml
CHANGED
data/config/locales/ja.yml
CHANGED
data/config/locales/ko.yml
CHANGED
data/config/locales/lt.yml
CHANGED
data/config/locales/lv.yml
CHANGED
@@ -0,0 +1,134 @@
|
|
1
|
+
mk:
|
2
|
+
activerecord:
|
3
|
+
models:
|
4
|
+
comment:
|
5
|
+
one: "Коментар"
|
6
|
+
other: "Коментари"
|
7
|
+
active_admin/comment:
|
8
|
+
one: "Коментар"
|
9
|
+
other: "Коментари"
|
10
|
+
active_admin:
|
11
|
+
dashboard: "Почетна"
|
12
|
+
dashboard_welcome:
|
13
|
+
welcome: "Добредојдовте во Active Admin. Ова е стандардна верзија на почетната страна."
|
14
|
+
call_to_action: "За да додадете секции на почетната страна, прегледајте го 'app/admin/dashboard.rb'."
|
15
|
+
view: "Прегледај"
|
16
|
+
edit: "Измени"
|
17
|
+
delete: "Избриши"
|
18
|
+
delete_confirmation: "Дали сте сигурни дека сакате да го избришете записот?"
|
19
|
+
create_another: "Креирај нов %{model}"
|
20
|
+
new_model: "Додај нов %{model}"
|
21
|
+
edit_model: "Измени %{model}"
|
22
|
+
delete_model: "Избриши %{model}"
|
23
|
+
details: "Детали за %{model}"
|
24
|
+
cancel: "Откажи"
|
25
|
+
empty: "Празно"
|
26
|
+
previous: "Претходно"
|
27
|
+
next: "Следно"
|
28
|
+
download: "Преземи во понудените формати:"
|
29
|
+
has_many_new: "Додај нов %{model}"
|
30
|
+
has_many_delete: "Избриши"
|
31
|
+
has_many_remove: "Отстрани"
|
32
|
+
move: "Премести"
|
33
|
+
filters:
|
34
|
+
buttons:
|
35
|
+
filter: "Пребарај"
|
36
|
+
clear: "Исчисти филтри"
|
37
|
+
predicates:
|
38
|
+
contains: "Содржи"
|
39
|
+
equals: "Е еднакво со"
|
40
|
+
starts_with: "Започнува со"
|
41
|
+
ends_with: "Завршува сo"
|
42
|
+
greater_than: "Е поголемо од"
|
43
|
+
less_than: "Е помало од"
|
44
|
+
gteq_datetime: "Е поголемо или еднакво со"
|
45
|
+
lteq_datetime: "Е помало или еднакво со"
|
46
|
+
from: "Од"
|
47
|
+
to: "До"
|
48
|
+
search_status:
|
49
|
+
headline: "Пронајдени резултати:"
|
50
|
+
current_filters: "Резултати врз основа на следниве филтри:"
|
51
|
+
no_current_filters: "Моментално нема филтри"
|
52
|
+
status_tag:
|
53
|
+
"yes": "Да"
|
54
|
+
"no": "Не"
|
55
|
+
"unset": "Не"
|
56
|
+
main_content: "Ве замолуваме имплементирајте %{model}#main_content за да прикажете содржина."
|
57
|
+
logout: "Одјави се"
|
58
|
+
powered_by: "Овозможено од %{active_admin} %{version}"
|
59
|
+
sidebars:
|
60
|
+
filters: "Филтри за пребарување"
|
61
|
+
search_status: "Резултати од пребарување"
|
62
|
+
pagination:
|
63
|
+
empty: "Нема пронајдени записи за %{model}"
|
64
|
+
one: "Прикажан <b>1</b> %{model}"
|
65
|
+
one_page: "Прикажани <b>сите %{n}</b> %{model}"
|
66
|
+
multiple: "Прикажани %{model} <b>%{from} - %{to}</b> од вкупно <b>%{total}</b>"
|
67
|
+
multiple_without_total: "Прикажани %{model} <b>%{from} - %{to}</b>"
|
68
|
+
per_page: "Прикази на записи по страна:"
|
69
|
+
entry:
|
70
|
+
one: "запис"
|
71
|
+
other: "записи"
|
72
|
+
any: "Било кој"
|
73
|
+
blank_slate:
|
74
|
+
content: "Не се креирани записи од типот на %{resource_name}."
|
75
|
+
link: "Креирај нов"
|
76
|
+
dropdown_actions:
|
77
|
+
button_label: "Активности"
|
78
|
+
batch_actions:
|
79
|
+
button_label: "Групни активности"
|
80
|
+
default_confirmation: "Дали сте сигурни?"
|
81
|
+
delete_confirmation: "Дали сте сигурни дека сакате да ги избришете %{plural_model}?"
|
82
|
+
succesfully_destroyed:
|
83
|
+
one: "Успешно е избришан 1 %{model}"
|
84
|
+
other: "Успешно се избришани %{count} %{plural_model}"
|
85
|
+
selection_toggle_explanation: "(Toggle Selection)"
|
86
|
+
action_label: "%{title} го селектираното"
|
87
|
+
labels:
|
88
|
+
destroy: "Избриши"
|
89
|
+
devise:
|
90
|
+
username:
|
91
|
+
title: "Корисничко име"
|
92
|
+
email:
|
93
|
+
title: "Е-маил"
|
94
|
+
password:
|
95
|
+
title: "Лозинка"
|
96
|
+
password_confirmation:
|
97
|
+
title: "Потврди Лозинка"
|
98
|
+
sign_up:
|
99
|
+
title: "Креирај профил"
|
100
|
+
submit: "Креирај"
|
101
|
+
login:
|
102
|
+
title: "Најави се"
|
103
|
+
remember_me: "Запомни ме"
|
104
|
+
submit: "Најави се"
|
105
|
+
reset_password:
|
106
|
+
title: "Ја заборавивте Вашата лозинка?"
|
107
|
+
submit: "Промени лозинка"
|
108
|
+
change_password:
|
109
|
+
title: "Променете ја лозинката"
|
110
|
+
submit: "Промени лозинка"
|
111
|
+
unlock:
|
112
|
+
title: "Повторно испраќање на инструкции за отклучување на профил"
|
113
|
+
submit: "Испрати инструкции"
|
114
|
+
resend_confirmation_instructions:
|
115
|
+
title: "Повторно испраќање на инструкции за потврдување на профил"
|
116
|
+
submit: "Инспрати инструкции"
|
117
|
+
links:
|
118
|
+
sign_up: "Креирај профил"
|
119
|
+
sign_in: "Најави се"
|
120
|
+
forgot_your_password: "Ја заборавивте Вашата лозинка?"
|
121
|
+
sign_in_with_omniauth_provider: "Најави се со %{provider}"
|
122
|
+
resend_unlock_instructions: "Повторно испрати инструкции за отклучување на профил"
|
123
|
+
resend_confirmation_instructions: "Повторно испрати инструкции за потврдување на профил"
|
124
|
+
unsupported_browser:
|
125
|
+
headline: "Ве замолуваме, имајте во предвид дека ActiveAdmin не нуди поддршка за Internet Explorer 8 верзијата или претходни верзии."
|
126
|
+
recommendation: "Ви порачуваме да го <a href=\"http://browsehappy.com/\"> ажурирате Вашиот пребарувач</a> за да си го подобрите пребарувањето."
|
127
|
+
turn_off_compatibility_view: "Доколку користите IE 9 или понова верзија, Ве замолуваме <a href=\"https://support.microsoft.com/en-us/help/17471\">да исклучите \"Compatibility View\"</a>."
|
128
|
+
access_denied:
|
129
|
+
message: "Немате овластување да ја извршите оваа активност."
|
130
|
+
index_list:
|
131
|
+
table: "Табела"
|
132
|
+
block: "Листа"
|
133
|
+
grid: "Грид"
|
134
|
+
blog: "Блог"
|
data/config/locales/nb.yml
CHANGED
data/config/locales/nl.yml
CHANGED
data/config/locales/pl.yml
CHANGED
data/config/locales/pt-BR.yml
CHANGED
data/config/locales/pt-PT.yml
CHANGED
data/config/locales/ro.yml
CHANGED
data/config/locales/ru.yml
CHANGED
data/config/locales/sk.yml
CHANGED
@@ -1,4 +1,24 @@
|
|
1
1
|
sk:
|
2
|
+
activerecord:
|
3
|
+
models:
|
4
|
+
comment:
|
5
|
+
one: "Komentár"
|
6
|
+
few: "Komentáre"
|
7
|
+
many: "Komentárov"
|
8
|
+
other: "Komentáre"
|
9
|
+
active_admin/comment:
|
10
|
+
one: "Komentár"
|
11
|
+
few: "Komentáre"
|
12
|
+
many: "Komentárov"
|
13
|
+
other: "Komentáre"
|
14
|
+
attributes:
|
15
|
+
active_admin/comment:
|
16
|
+
author_type: "Typ autora"
|
17
|
+
body: "Telo"
|
18
|
+
created_at: "Vytvorený"
|
19
|
+
namespace: "Namespace"
|
20
|
+
resource_type: "Typ komentovanej položky"
|
21
|
+
updated_at: "Upravený"
|
2
22
|
active_admin:
|
3
23
|
dashboard: Úvod
|
4
24
|
dashboard_welcome:
|
@@ -8,6 +28,7 @@ sk:
|
|
8
28
|
edit: "Upraviť"
|
9
29
|
delete: "Zmazať"
|
10
30
|
delete_confirmation: "Ste si istí, že chcete túto položku zmazať?"
|
31
|
+
create_another: "Vytvoriť ďalší %{model}"
|
11
32
|
new_model: "Vytvoriť"
|
12
33
|
edit_model: "Upraviť"
|
13
34
|
delete_model: "Zmazať"
|
@@ -20,6 +41,7 @@ sk:
|
|
20
41
|
has_many_new: "Pridať nový"
|
21
42
|
has_many_delete: "Zmazať"
|
22
43
|
has_many_remove: "Odstrániť"
|
44
|
+
move: "Presunúť"
|
23
45
|
filters:
|
24
46
|
buttons:
|
25
47
|
filter: "Filtrovať"
|
@@ -31,14 +53,27 @@ sk:
|
|
31
53
|
ends_with: "Končí na"
|
32
54
|
greater_than: "Väčší ako"
|
33
55
|
less_than: "Menší ako"
|
56
|
+
gteq_datetime: "Od"
|
57
|
+
lteq_datetime: "Do"
|
58
|
+
from: "Od"
|
59
|
+
to: "Do"
|
60
|
+
scopes:
|
61
|
+
all: "Všetko"
|
62
|
+
search_status:
|
63
|
+
headline: "Stav vyhľadávania:"
|
64
|
+
current_scope: "Scope:"
|
65
|
+
current_filters: "Filtre:"
|
66
|
+
no_current_filters: "Žiadne"
|
34
67
|
status_tag:
|
35
68
|
"yes": "Áno"
|
36
69
|
"no": "Nie"
|
70
|
+
"unset": "Nie"
|
37
71
|
main_content: "Implementujte prosím %{model}#main_content pre zobrazenie obsahu."
|
38
72
|
logout: "Odhlásiť"
|
39
73
|
powered_by: "%{active_admin} %{version}"
|
40
74
|
sidebars:
|
41
75
|
filters: "Filtre"
|
76
|
+
search_status: "Stav vyhľadávania"
|
42
77
|
pagination:
|
43
78
|
empty: "Nenájdený."
|
44
79
|
one: "Zobrazená <b>1</b> položka"
|
@@ -69,11 +104,14 @@ sk:
|
|
69
104
|
labels:
|
70
105
|
destroy: "Vymazať"
|
71
106
|
comments:
|
107
|
+
created_at: "Vytvorený"
|
72
108
|
resource_type: "Typ zdroja"
|
73
109
|
author_type: "Typ autora"
|
74
110
|
body: "Telo"
|
75
111
|
author: "Autor"
|
76
112
|
add: "Pridať komentár"
|
113
|
+
delete: "Zmazať komentár"
|
114
|
+
delete_confirmation: "Naozaj chcete zmazať tento komentár?"
|
77
115
|
resource: "Zdroj"
|
78
116
|
no_comments_yet: "Žiadny komentár"
|
79
117
|
author_missing: "Anonymný"
|
@@ -81,6 +119,19 @@ sk:
|
|
81
119
|
errors:
|
82
120
|
empty_text: "Komentár nebol uložený, je prázdny."
|
83
121
|
devise:
|
122
|
+
username:
|
123
|
+
title: "Užívateľské meno"
|
124
|
+
email:
|
125
|
+
title: "Email"
|
126
|
+
subdomain:
|
127
|
+
title: "Subdoména"
|
128
|
+
password:
|
129
|
+
title: "Heslo"
|
130
|
+
password_confirmation:
|
131
|
+
title: "Potvrdenie hesla"
|
132
|
+
sign_up:
|
133
|
+
title: "Registrácia"
|
134
|
+
submit: "Registrovať"
|
84
135
|
login:
|
85
136
|
title: "Prihlásenie"
|
86
137
|
remember_me: "Zapamätať si ma"
|
@@ -94,11 +145,20 @@ sk:
|
|
94
145
|
unlock:
|
95
146
|
title: "Zaslanie inštrukcií k odomknutiu účtu"
|
96
147
|
submit: "Zaslať inštrukcií k odomknutiu účtu"
|
148
|
+
resend_confirmation_instructions:
|
149
|
+
title: "Preposlanie potvrdzovacie inštrukcie"
|
150
|
+
submit: "Preposlať potvrdzovacie inštrukcie"
|
97
151
|
links:
|
98
152
|
sign_in: "Prihlásiť sa"
|
99
153
|
sign_up: "Registrovať sa"
|
100
154
|
forgot_your_password: "Zabudli ste heslo?"
|
101
155
|
sign_in_with_omniauth_provider: "Prihlásiť sa cez %{provider}"
|
156
|
+
resend_unlock_instructions: "Poslať znovu inštrukcie na odomknutie účtu"
|
157
|
+
resend_confirmation_instructions: "Preposlať potvrdzovacie inštrukcie"
|
158
|
+
unsupported_browser:
|
159
|
+
headline: "ActiveAdmin nepodporuje Internet Explorer vo verzii <= 8."
|
160
|
+
recommendation: "Odporúčame <a href=\"http://browsehappy.com/\">aktualizovať Váš prehliadač</a>."
|
161
|
+
turn_off_compatibility_view: "Ak používate Internet Explorer vo verzii >= 9, uistite sa, že <a href=\"https://support.microsoft.com/en-us/help/17471\">\"režim kompatibility\" je vypnutý</a>"
|
102
162
|
access_denied:
|
103
163
|
message: "Nemáte oprávnenie k vykonaniu tejto akcie."
|
104
164
|
index_list:
|
data/config/locales/sv-SE.yml
CHANGED
data/config/locales/tr.yml
CHANGED
data/config/locales/uk.yml
CHANGED
data/config/locales/vi.yml
CHANGED
data/config/locales/zh-CN.yml
CHANGED
data/config/locales/zh-TW.yml
CHANGED
@@ -106,6 +106,26 @@ ActiveAdmin.setup do |config|
|
|
106
106
|
end
|
107
107
|
```
|
108
108
|
|
109
|
+
If you are creating a multi-tenant application you may want to have multiple namespaces mounted to the same path. We can do this using the `route_options` settings on the namespace
|
110
|
+
|
111
|
+
```ruby
|
112
|
+
config.namespace :site_1 do |admin|
|
113
|
+
admin.route_options = { path: :admin, constraints: ->(request){ request.domain == "site1.com" } }
|
114
|
+
end
|
115
|
+
|
116
|
+
config.namespace :site_2 do |admin|
|
117
|
+
admin.route_options = { path: :admin, constraints: ->(request){ request.domain == "site2.com" } }
|
118
|
+
end
|
119
|
+
```
|
120
|
+
|
121
|
+
If you would like to mount the namespace to a subdomain instead of path we can use the `route_options` for this as well
|
122
|
+
|
123
|
+
```ruby
|
124
|
+
config.namespace :admin do |admin|
|
125
|
+
admin.route_options = { path: '', subdomain: 'admin' }
|
126
|
+
end
|
127
|
+
```
|
128
|
+
|
109
129
|
Each setting available in the Active Admin setup block is configurable on a per
|
110
130
|
namespace basis.
|
111
131
|
|