refinerycms-core 2.0.10 → 2.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/refinery/admin.js.erb +126 -234
- data/app/assets/javascripts/refinery/ajaxy_pagination.js.coffee +1 -1
- data/app/assets/javascripts/refinery/boot_wym.js.erb +4 -8
- data/app/assets/javascripts/refinery/core.js +1 -1
- data/app/assets/javascripts/refinery/interface.js.coffee.erb +3 -16
- data/app/assets/javascripts/refinery/modal_dialogs.js.erb +0 -3
- data/app/assets/javascripts/refinery/nestedsortables.js +312 -312
- data/app/assets/javascripts/refinery/refinery.js.erb +14 -15
- data/app/assets/javascripts/refinery/site_bar.js +3 -9
- data/app/assets/javascripts/refinery/sortable_list.js +145 -0
- data/app/assets/javascripts/refinery/sortable_menu.js.coffee +3 -4
- data/app/assets/javascripts/refinery/submit_continue.js.coffee.erb +1 -2
- data/app/assets/javascripts/refinery/tree.js +3 -3
- data/app/assets/javascripts/refinery/wymeditor.js +6 -6
- data/{public → app/assets/javascripts}/wymeditor/GPL-license.txt +0 -0
- data/{public → app/assets/javascripts}/wymeditor/MIT-license.txt +0 -0
- data/{public → app/assets/javascripts}/wymeditor/README +0 -0
- data/app/assets/javascripts/wymeditor/browsers/mozilla.js.erb +10 -11
- data/app/assets/javascripts/wymeditor/browsers/webkit.js.erb +17 -18
- data/app/assets/javascripts/wymeditor/classes.js.erb +3 -5
- data/app/assets/javascripts/wymeditor/functions.js.erb +5 -1
- data/app/assets/javascripts/wymeditor/prototypes.js.erb +0 -3
- data/app/assets/javascripts/wymeditor/setup.js.erb +5 -5
- data/app/assets/javascripts/wymeditor/skins/refinery/skin.js +1 -4
- data/app/assets/javascripts/wymeditor/validators.js.erb +3 -2
- data/app/assets/stylesheets/{formatting.css.scss → refinery/formatting.css.scss} +0 -0
- data/app/assets/stylesheets/refinery/layout.css.scss +41 -11
- data/app/assets/stylesheets/{theme.css.scss → refinery/theme.css.scss} +0 -0
- data/app/controllers/refinery/sitemap_controller.rb +1 -5
- data/app/helpers/refinery/admin_helper.rb +6 -0
- data/app/helpers/refinery/image_helper.rb +2 -1
- data/app/helpers/refinery/menu_helper.rb +0 -49
- data/app/helpers/refinery/meta_helper.rb +7 -3
- data/app/helpers/refinery/site_bar_helper.rb +3 -15
- data/app/models/refinery/core/base_model.rb +2 -0
- data/{lib → app/presenters}/refinery/base_presenter.rb +1 -2
- data/app/views/layouts/application.html.erb +8 -7
- data/app/views/refinery/_content_page.html.erb +1 -1
- data/app/views/refinery/_google_analytics.html.erb +12 -5
- data/app/views/refinery/_head.html.erb +11 -15
- data/app/views/refinery/_header.html.erb +1 -4
- data/app/views/refinery/_javascripts.html.erb +14 -8
- data/app/views/refinery/_site_bar.html.erb +4 -4
- data/app/views/refinery/admin/_form_advanced_options_menu.html.erb +12 -0
- data/app/views/refinery/admin/_javascripts.html.erb +13 -1
- data/app/views/refinery/admin/_locale_picker.html.erb +11 -0
- data/app/views/refinery/admin/_make_sortable.html.erb +8 -5
- data/app/views/refinery/admin/_search.html.erb +1 -7
- data/app/views/refinery/admin/_search_header.html.erb +1 -0
- data/app/views/refinery/admin/_wysiwyg.html.erb +16 -0
- data/config/initializers/will_paginate_monkeypatch.rb +1 -1
- data/config/locales/bg.yml +5 -1
- data/config/locales/cs.yml +5 -1
- data/config/locales/da.yml +5 -1
- data/config/locales/de.yml +7 -3
- data/config/locales/el.yml +5 -1
- data/config/locales/en.yml +7 -1
- data/config/locales/es.yml +5 -1
- data/config/locales/fi.yml +5 -1
- data/config/locales/fr.yml +5 -1
- data/config/locales/hu.yml +82 -0
- data/config/locales/it.yml +38 -34
- data/config/locales/ja.yml +5 -1
- data/config/locales/ko.yml +5 -1
- data/config/locales/lt.yml +5 -1
- data/config/locales/lv.yml +5 -1
- data/config/locales/nb.yml +5 -1
- data/config/locales/nl.yml +36 -29
- data/config/locales/pl.yml +8 -1
- data/config/locales/pt-BR.yml +7 -3
- data/config/locales/pt.yml +82 -0
- data/config/locales/rs.yml +5 -1
- data/config/locales/ru.yml +5 -1
- data/config/locales/sk.yml +10 -3
- data/config/locales/sl.yml +5 -1
- data/config/locales/sv.yml +5 -1
- data/config/locales/tr.yml +82 -0
- data/config/locales/uk.yml +77 -0
- data/config/locales/vi.yml +5 -1
- data/config/locales/zh-CN.yml +5 -1
- data/config/locales/zh-TW.yml +5 -1
- data/config/routes.rb +3 -3
- data/lib/generators/refinery/cms/cms_generator.rb +29 -0
- data/lib/generators/refinery/cms/templates/.gitignore +1 -0
- data/lib/generators/refinery/cms/templates/app/views/sitemap/index.xml.builder +13 -13
- data/lib/generators/refinery/core/templates/config/initializers/refinery/core.rb.erb +8 -12
- data/lib/generators/refinery/dummy/templates/rails/database.yml +3 -3
- data/lib/generators/refinery/engine/engine_generator.rb +8 -12
- data/lib/generators/refinery/engine/templates/Gemfile +5 -39
- data/lib/generators/refinery/engine/templates/app/controllers/refinery/namespace/admin/plural_name_controller.rb.erb +4 -4
- data/lib/generators/refinery/engine/templates/app/models/refinery/namespace/singular_name.rb.erb +2 -3
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_actions.html.erb +1 -1
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_form.html.erb +31 -33
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_records.html.erb +1 -3
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_singular_name.html.erb +2 -2
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/index.html.erb +1 -1
- data/lib/generators/refinery/engine/templates/config/locales/cs.yml +28 -0
- data/lib/generators/refinery/engine/templates/config/locales/it.yml +28 -0
- data/lib/generators/refinery/engine/templates/config/locales/nl.yml +6 -6
- data/lib/generators/refinery/engine/templates/config/locales/tr.yml +28 -0
- data/lib/generators/refinery/engine/templates/config/routes.rb.erb +2 -2
- data/lib/generators/refinery/engine/templates/db/seeds.rb.erb +1 -1
- data/lib/generators/refinery/engine/templates/lib/generators/refinery/extension_plural_name_generator.rb.erb +1 -1
- data/lib/generators/refinery/engine/templates/lib/refinery/plural_name/engine.rb.erb +1 -1
- data/lib/generators/refinery/engine/templates/spec/{requests → features}/refinery/namespace/admin/plural_name_spec.rb.erb +1 -1
- data/lib/generators/refinery/engine/templates/spec/spec_helper.rb +25 -49
- data/lib/generators/refinery/form/form_generator.rb +1 -13
- data/lib/generators/refinery/form/templates/app/models/refinery/namespace/singular_name.rb.erb +0 -4
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/plural_name/_records.html.erb +2 -2
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/plural_name/spam.html.erb +7 -6
- data/lib/generators/refinery/form/templates/config/locales/nl.yml +29 -29
- data/lib/generators/refinery/form/templates/config/locales/tr.yml +78 -0
- data/lib/generators/refinery/form/templates/config/routes.rb.erb +1 -1
- data/lib/generators/refinery/form/templates/db/migrate/1_create_plural_name.rb.erb +2 -6
- data/lib/generators/refinery/form/templates/db/seeds.rb.erb +1 -1
- data/lib/generators/refinery/form/templates/lib/refinery/plural_name/engine.rb.erb +1 -1
- data/lib/generators/refinery/form/templates/refinerycms-plural_name.gemspec +2 -5
- data/lib/refinery.rb +191 -0
- data/lib/refinery/admin/base_controller.rb +27 -16
- data/lib/refinery/application_controller.rb +15 -47
- data/lib/refinery/cli.rb +48 -27
- data/lib/refinery/core.rb +7 -183
- data/lib/refinery/core/configuration.rb +17 -9
- data/lib/refinery/core/engine.rb +11 -47
- data/lib/refinery/crud.rb +81 -66
- data/lib/refinery/engine.rb +52 -55
- data/lib/refinery/ext/action_view/helpers/form_builder.rb +2 -0
- data/lib/refinery/extension_generation.rb +208 -110
- data/lib/refinery/menu.rb +16 -7
- data/lib/refinery/menu_item.rb +56 -54
- data/lib/refinery/plugin.rb +11 -3
- data/lib/refinery/plugins.rb +14 -1
- data/lib/refinery/version.rb +3 -3
- data/refinerycms-core.gemspec +11 -10
- data/spec/controllers/refinery/admin/dummy_controller_spec.rb +57 -0
- data/spec/controllers/refinery/admin/refinery_core_controller_spec.rb +3 -4
- data/spec/controllers/refinery/sitemap_controller_spec.rb +1 -14
- data/spec/{requests → features}/refinery/admin/custom_assets_spec.rb +1 -1
- data/spec/{requests → features}/refinery/admin/dialogs_spec.rb +1 -1
- data/spec/features/refinery/admin/xhr_paging_spec.rb +55 -0
- data/spec/features/refinery/application_layout_spec.rb +19 -0
- data/spec/features/refinery/core_spec.rb +14 -0
- data/spec/{requests → features}/refinery/site_bar_spec.rb +1 -1
- data/spec/helpers/refinery/meta_helper_spec.rb +25 -0
- data/spec/lib/generators/refinery/cms/cms_generator_spec.rb +61 -0
- data/spec/lib/generators/refinery/engine/engine_generator_multiple_resources_spec.rb +28 -1
- data/spec/lib/generators/refinery/engine/engine_generator_sanity_check_spec.rb +7 -7
- data/spec/lib/generators/refinery/engine/engine_generator_spec.rb +69 -8
- data/spec/lib/generators/refinery/engine/engine_generator_with_i18n_spec.rb +0 -2
- data/spec/lib/generators/refinery/form/form_generator_spec.rb +9 -1
- data/spec/lib/refinery/application_controller_spec.rb +48 -63
- data/spec/lib/refinery/cli_spec.rb +136 -0
- data/spec/lib/refinery/core/configuration_spec.rb +17 -0
- data/spec/lib/refinery/core_spec.rb +19 -13
- data/spec/lib/refinery/crud_spec.rb +0 -4
- data/spec/lib/refinery/menu_spec.rb +16 -26
- data/spec/support/refinery.rb +6 -1
- data/{app → vendor}/assets/javascripts/jquery/GPL-LICENSE.txt +0 -0
- data/{app → vendor}/assets/javascripts/jquery/MIT-LICENSE.txt +0 -0
- data/vendor/assets/javascripts/jquery/jquery.browser.js +49 -0
- data/{app → vendor}/assets/javascripts/jquery/jquery.html5-placeholder-shim.js +0 -0
- data/{app → vendor}/assets/javascripts/jquery/jquery.jcarousel.js +0 -0
- data/{app → vendor}/assets/javascripts/jquery/jquery.textTruncate.js +0 -0
- data/{app → vendor}/assets/javascripts/jquery/jquery.timers.js +0 -0
- data/{app → vendor}/assets/javascripts/modernizr-min.js +0 -0
- metadata +231 -78
- data/app/assets/images/refinery/resolve_digital_footer_logo.png +0 -0
- data/app/assets/javascripts/dd_belatedpng.js +0 -13
- data/app/assets/javascripts/jquery/jquery.corner.js +0 -345
- data/app/assets/stylesheets/application.css.scss +0 -55
- data/app/assets/stylesheets/home.css.scss +0 -3
- data/app/views/refinery/_ie6check.html.erb +0 -63
- data/app/views/refinery/_menu.html.erb +0 -20
- data/app/views/refinery/_menu_branch.html.erb +0 -19
- data/lib/generators/refinery/engine/templates/Guardfile +0 -27
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_locale_picker.html.erb +0 -11
- data/lib/refinery/catch_all_routes.rb +0 -3
- data/lib/tasks/yard.rake +0 -30
- data/spec/requests/refinery/admin/controller_restriction_spec.rb +0 -27
- data/spec/requests/refinery/search_spec.rb +0 -71
data/config/locales/sv.yml
CHANGED
@@ -47,13 +47,17 @@ sv:
|
|
47
47
|
current: Aktuell fil
|
48
48
|
search:
|
49
49
|
button_text: Sök
|
50
|
-
|
50
|
+
results_for_html: "Sökresultat för ‘<em>%{query}</em>’"
|
51
51
|
no_results: Tyvärr, sökningen gav inga träffar.
|
52
52
|
delete:
|
53
53
|
message: 'Är du säker på att du vill ta bort %{title}?'
|
54
54
|
error_messages:
|
55
55
|
problems_in_following_fields: Det uppstod problem med följande fält
|
56
56
|
help: hjälp
|
57
|
+
form_advanced_options_menu:
|
58
|
+
advanced_options: Avancerade alternativ
|
59
|
+
toggle_advanced_options: Klicka för att få tillgång till meta-taggar och menyval
|
60
|
+
save_as_draft: Spara som Utkast
|
57
61
|
message:
|
58
62
|
close: Stäng
|
59
63
|
close_this_message: Stäng detta meddelande
|
@@ -0,0 +1,82 @@
|
|
1
|
+
tr:
|
2
|
+
refinery:
|
3
|
+
js:
|
4
|
+
admin:
|
5
|
+
confirm_changes: Yaptiginiz degisiklikler kaybolacaktir. Kayit etmeden devam etmek istediginize emin misiniz ?
|
6
|
+
plugins:
|
7
|
+
refinery_core:
|
8
|
+
title: Refinery
|
9
|
+
description: Cekirdek refinery eklentisi
|
10
|
+
refinery_dialogs:
|
11
|
+
title: Iletisim
|
12
|
+
description: Refinery diyalog eklentisi
|
13
|
+
welcome:
|
14
|
+
there_are_no_users: "Henuz kayitli bir kullanici yok. Ilk once sizi kayit edelim."
|
15
|
+
crudify:
|
16
|
+
created: '%{what} basari ile eklendi'
|
17
|
+
updated: '%{what} basari ile guncellendi'
|
18
|
+
destroyed: '%{what} basari ile silindi.'
|
19
|
+
site_bar:
|
20
|
+
log_out: Cikis Yap
|
21
|
+
switch_to_your_website: Web Siteni Ac
|
22
|
+
switch_to_your_website_editor: Web Site Editorunu Ac
|
23
|
+
admin:
|
24
|
+
menu:
|
25
|
+
reorder_menu: Yeniden duzenleme menusu
|
26
|
+
reorder_menu_done: Yeniden duzenleme tamamlandi
|
27
|
+
dialogs:
|
28
|
+
show:
|
29
|
+
save: Kayit Et
|
30
|
+
cancel: Vazgec
|
31
|
+
continue_editing:
|
32
|
+
save_and_continue_editing: 'Kaydet & Duzenlemeye Devam Et'
|
33
|
+
form_actions:
|
34
|
+
save: Kayit Et
|
35
|
+
cancel: Vazgec
|
36
|
+
cancel_lose_changes: Eger vazgec'e tiklarsaniz burada yaptiginiz degisiklikler kaybolacaktir.
|
37
|
+
delete: Sil
|
38
|
+
close: Kapat
|
39
|
+
image_picker:
|
40
|
+
none_selected: Secilmis bir fotograf bulunmamaktadir. Eklemek icin buraya tiklayin
|
41
|
+
remove_current: Mevcut fotografi sil
|
42
|
+
change: Fotograf secmek icin tiklayin
|
43
|
+
show: Goster
|
44
|
+
resource_picker:
|
45
|
+
download_current: Mevcut dosyayi indir
|
46
|
+
opens_in_new_window: Yeni bir pencerede ac
|
47
|
+
remove_current: "Mevcut dosyayi sil"
|
48
|
+
no_resource_selected: 'Herhangi bir dosya secilmemis. Eklemek icin tiklayin'
|
49
|
+
name: Dosya Ekle
|
50
|
+
current: Mevcut Dosya
|
51
|
+
search:
|
52
|
+
button_text: Arama
|
53
|
+
results_for_html: " ‘<em>%{query}</em>’ icin arama sonucu"
|
54
|
+
no_results: 'Uzgunum, herhangi bir sonuc bulunamadi'
|
55
|
+
cancel_search: 'Aramayi iptal et'
|
56
|
+
search_input_notice: "Buraya aradiginiz karakterleri iceren en az 3 tane harf girin."
|
57
|
+
delete:
|
58
|
+
message: " '%{title}' Silmek istediginize emin misiniz?"
|
59
|
+
error_messages:
|
60
|
+
problems_in_following_fields: Asagidaki alanlarda problem vardir.
|
61
|
+
help: yardim
|
62
|
+
form_advanced_options_menu:
|
63
|
+
advanced_options: Gelismis Secenekler
|
64
|
+
toggle_advanced_options: Gelismis Secenekleri Ac
|
65
|
+
save_as_draft: Taslak Olarak Kaydet
|
66
|
+
message:
|
67
|
+
close: Kapat
|
68
|
+
close_this_message: Bu Mesaji Kapat
|
69
|
+
draft_page_message:
|
70
|
+
not_live: Bu sayfa halka acik canli goruntuleme degildir.
|
71
|
+
footer:
|
72
|
+
copyright: "Telif Hakki © %{year} %{site_name}"
|
73
|
+
no_script:
|
74
|
+
enable_javascript_html: Bu sayfanin tum fonsiyonlari icin JavaScript'in aktif olmasi gerekmekte
|
75
|
+
here_are: Iste burada
|
76
|
+
instructions_enable_javascript_html: Tarayicinizin JavaScript'ini nasil aktif edilecegi.
|
77
|
+
time:
|
78
|
+
formats:
|
79
|
+
short: "%A, %d %B %Y"
|
80
|
+
will_paginate:
|
81
|
+
previous_label: "«"
|
82
|
+
next_label: "»"
|
@@ -0,0 +1,77 @@
|
|
1
|
+
uk:
|
2
|
+
refinery:
|
3
|
+
plugins:
|
4
|
+
refinery_core:
|
5
|
+
title: Refinery
|
6
|
+
description: Ядро Refinery
|
7
|
+
refinery_dialogs:
|
8
|
+
title: Діалоги
|
9
|
+
description: Плагін для діалогів Refinery
|
10
|
+
welcome:
|
11
|
+
there_are_no_users: "Жодного користувача не створено. Ви будете першим."
|
12
|
+
crudify:
|
13
|
+
created: "%{what} створений(а)."
|
14
|
+
updated: "%{what} відредагований(а)."
|
15
|
+
destroyed: "%{what} знищений(а)."
|
16
|
+
site_bar:
|
17
|
+
log_out: Вийти
|
18
|
+
switch_to_your_website: Перейти на сайт
|
19
|
+
switch_to_your_website_editor: Перейти в панель управління
|
20
|
+
admin:
|
21
|
+
menu:
|
22
|
+
reorder_menu: Змінити порядок в меню
|
23
|
+
reorder_menu_done: Зберегти такий порядок в меню
|
24
|
+
dialogs:
|
25
|
+
show:
|
26
|
+
save: Зберегти
|
27
|
+
cancel: Скасувати
|
28
|
+
continue_editing:
|
29
|
+
save_and_continue_editing: Зберегти та продовжити
|
30
|
+
form_actions:
|
31
|
+
save: Зберегти
|
32
|
+
cancel: Відміна
|
33
|
+
cancel_lose_changes: При скасуванні всі зміни будуть втрачені
|
34
|
+
delete: Видалити
|
35
|
+
close: Закрити
|
36
|
+
image_picker:
|
37
|
+
none_selected: Жодного зображення не вибрано. Будь ласка, натисніть тут, щоб додати зображення.
|
38
|
+
remove_current: Видалити поточне зображення
|
39
|
+
change: Натисніть тут, щоб вибрати зображення
|
40
|
+
show: Показати
|
41
|
+
resource_picker:
|
42
|
+
download_current: Завантажити поточний файл
|
43
|
+
opens_in_new_window: Відкриється в новому вікні
|
44
|
+
remove_current: "Видалити поточний файл"
|
45
|
+
no_resource_selected: Жоден файл не вибраний, натисніть тут, щоб додати файл.
|
46
|
+
name: Додати файл
|
47
|
+
current: Поточний файл
|
48
|
+
search:
|
49
|
+
button_text: Пошук
|
50
|
+
results_for_html: "Результати пошуку для ‘<em>%{query}</em>’"
|
51
|
+
no_results: Нічого не знайдено
|
52
|
+
delete:
|
53
|
+
message: Ви впевнені, що хочете видалити '%{title}'?
|
54
|
+
error_messages:
|
55
|
+
problems_in_following_fields: Виявлені проблеми з наступними полями
|
56
|
+
help: Допомога
|
57
|
+
form_advanced_options_menu:
|
58
|
+
advanced_options: Додаткові налаштування
|
59
|
+
toggle_advanced_options: Налаштування мета-тегів, меню та ін.
|
60
|
+
save_as_draft: Зберегти як чернетку
|
61
|
+
message:
|
62
|
+
close: Закрити
|
63
|
+
close_this_message: Закрити це повідомлення
|
64
|
+
draft_page_message:
|
65
|
+
not_live: Ця сторінка не призначена для публічного перегляду.
|
66
|
+
footer:
|
67
|
+
copyright: © %{site_name}, %{year}
|
68
|
+
no_script:
|
69
|
+
enable_javascript_html: Для використання всіх можливостей цієї сторінки необхідно увімкнути JavaScript
|
70
|
+
here_are: Вот
|
71
|
+
instructions_enable_javascript_html: інструкції як включити Javascript у вашому браузері
|
72
|
+
time:
|
73
|
+
formats:
|
74
|
+
short: "%A, %d %B %Y"
|
75
|
+
will_paginate:
|
76
|
+
previous_label: "«"
|
77
|
+
next_label: "»"
|
data/config/locales/vi.yml
CHANGED
@@ -47,13 +47,17 @@ vi:
|
|
47
47
|
current: File hiện tại
|
48
48
|
search:
|
49
49
|
button_text: Tìm kiếm
|
50
|
-
|
50
|
+
results_for_html: "Các kết quả tìm kiếm với truy vấn ‘<em>%{query}</em>’"
|
51
51
|
no_results: Rất tiếc, không có kết quả nào được tìm thấy
|
52
52
|
delete:
|
53
53
|
message: Bạn có thực sự chắc chắn khi xóa bỏ '%{title}' không?
|
54
54
|
error_messages:
|
55
55
|
problems_in_following_fields: Có lỗi xảy ra với những trường sau
|
56
56
|
help: giúp đỡ
|
57
|
+
form_advanced_options_menu:
|
58
|
+
advanced_options: Các tùy chọn nâng cao
|
59
|
+
toggle_advanced_options: Mở các thiết lập meta-tag và menu
|
60
|
+
save_as_draft: Lưu trữ dưới dạng bản thảo
|
57
61
|
message:
|
58
62
|
close: Đóng
|
59
63
|
close_this_message: Đóng thông báo này
|
data/config/locales/zh-CN.yml
CHANGED
@@ -47,13 +47,17 @@ zh-CN:
|
|
47
47
|
current: 当前文件
|
48
48
|
search:
|
49
49
|
button_text: 搜索
|
50
|
-
|
50
|
+
results_for_html: "搜索 ‘<em>%{query}</em>’ 的结果"
|
51
51
|
no_results: 对不起, 没有找到结果
|
52
52
|
delete:
|
53
53
|
message: 您确认要删除 '%{title}'?
|
54
54
|
error_messages:
|
55
55
|
problems_in_following_fields: 以下字段存在问题
|
56
56
|
help: 帮助
|
57
|
+
form_advanced_options_menu:
|
58
|
+
advanced_options: 高级选项
|
59
|
+
toggle_advanced_options: meta 标签设定与菜单选项
|
60
|
+
save_as_draft: 另存为草稿
|
57
61
|
message:
|
58
62
|
close: 关闭
|
59
63
|
close_this_message: 关闭这条信息
|
data/config/locales/zh-TW.yml
CHANGED
@@ -47,13 +47,17 @@ zh-TW:
|
|
47
47
|
current: 目前檔案
|
48
48
|
search:
|
49
49
|
button_text: 搜尋
|
50
|
-
|
50
|
+
results_for_html: "搜尋 ‘<em>%{query}</em>’ 的結果"
|
51
51
|
no_results: 抱歉, 沒有任何搜尋結果
|
52
52
|
delete:
|
53
53
|
message: 確定要移除 '%{title}' 嗎?
|
54
54
|
error_messages:
|
55
55
|
problems_in_following_fields: 以下幾個欄位出現問題
|
56
56
|
help: 求助
|
57
|
+
form_advanced_options_menu:
|
58
|
+
advanced_options: 進階選項
|
59
|
+
toggle_advanced_options: 存取 meta 標籤設定與選單選項
|
60
|
+
save_as_draft: 儲存草稿
|
57
61
|
message:
|
58
62
|
close: 關閉
|
59
63
|
close_this_message: 關閉這個訊息
|
data/config/routes.rb
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
Refinery::Core::Engine.routes.draw do
|
2
2
|
filter(:refinery_locales) if defined?(RoutingFilter::RefineryLocales) # optionally use i18n.
|
3
3
|
get 'wymiframe(/:id)', :to => 'fast#wymiframe', :as => :wymiframe
|
4
|
-
get
|
4
|
+
get "#{Refinery::Core.backend_route}/message", :to => 'fast#message', :as => :message
|
5
5
|
|
6
|
-
namespace :admin, :path =>
|
6
|
+
namespace :admin, :path => Refinery::Core.backend_route do
|
7
7
|
root :to => 'dashboard#index'
|
8
8
|
resources :dialogs, :only => [:index, :show]
|
9
9
|
end
|
10
10
|
|
11
|
-
|
11
|
+
post "/#{Refinery::Core.backend_route}/update_menu_positions", :to => 'admin/core#update_plugin_positions'
|
12
12
|
|
13
13
|
get '/sitemap.xml' => 'sitemap#index', :defaults => { :format => 'xml' }
|
14
14
|
end
|
@@ -30,6 +30,8 @@ module Refinery
|
|
30
30
|
|
31
31
|
append_gitignore!
|
32
32
|
|
33
|
+
append_asset_pipeline!
|
34
|
+
|
33
35
|
forced_overwriting?
|
34
36
|
|
35
37
|
copy_files!
|
@@ -49,6 +51,15 @@ module Refinery
|
|
49
51
|
|
50
52
|
protected
|
51
53
|
|
54
|
+
def append_asset_pipeline!
|
55
|
+
application_css = 'app/assets/stylesheets/application.css'
|
56
|
+
if destination_path.join(application_css).file?
|
57
|
+
insert_into_file application_css, %q{*= require refinery/formatting
|
58
|
+
*= require refinery/theme
|
59
|
+
}, :before => "*= require_self"
|
60
|
+
end
|
61
|
+
end
|
62
|
+
|
52
63
|
def append_gemfile!
|
53
64
|
if destination_path.join('Gemfile').file? &&
|
54
65
|
destination_path.join('Gemfile').read !~ %r{group :development, :test do\n.+?gem 'sqlite3'\nend}m
|
@@ -149,6 +160,24 @@ gem 'pg'
|
|
149
160
|
%w(development test production).map{|e| "config/environments/#{e}.rb"}.each do |env|
|
150
161
|
next unless destination_path.join(env).file?
|
151
162
|
|
163
|
+
# Refinery does not necessarily expect action_mailer to be available as
|
164
|
+
# we may not always require it (currently only the authentication extension).
|
165
|
+
# Rails, however, will optimistically place config entries for action_mailer.
|
166
|
+
current_mailer_config = File.read(destination_path.join(env)).to_s.
|
167
|
+
match(%r{^\s.+?config\.action_mailer\..+([\w\W]*\})?}).
|
168
|
+
to_a.flatten.first
|
169
|
+
|
170
|
+
if current_mailer_config.present?
|
171
|
+
new_mailer_config = [
|
172
|
+
" if config.respond_to?(:action_mailer)",
|
173
|
+
current_mailer_config.gsub(%r{\A\n+?}, ''). # remove extraneous newlines at the start
|
174
|
+
gsub(%r{^\ \ }) { |line| " #{line}" }, # add indentation on each line
|
175
|
+
" end"
|
176
|
+
].join("\n")
|
177
|
+
|
178
|
+
gsub_file env, current_mailer_config, new_mailer_config, :verbose => false
|
179
|
+
end
|
180
|
+
|
152
181
|
gsub_file env, "config.assets.compile = false", "config.assets.compile = true", :verbose => false
|
153
182
|
end
|
154
183
|
end
|
@@ -5,20 +5,20 @@ xml.urlset "xmlns" => "http://www.sitemaps.org/schemas/sitemap/0.9" do
|
|
5
5
|
@locales.each do |locale|
|
6
6
|
::I18n.locale = locale
|
7
7
|
::Refinery::Page.live.in_menu.includes(:parts).each do |page|
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
8
|
+
# exclude sites that are external to our own domain.
|
9
|
+
page_url = if page.url.is_a?(Hash)
|
10
|
+
# This is how most pages work without being overriden by link_url
|
11
|
+
page.url.merge({:only_path => false})
|
12
|
+
elsif page.url.to_s !~ /^http/
|
13
|
+
# handle relative link_url addresses.
|
14
|
+
[request.protocol, request.host_with_port, page.url].join
|
15
|
+
end
|
16
16
|
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
17
|
+
# Add XML entry only if there is a valid page_url found above.
|
18
|
+
xml.url do
|
19
|
+
xml.loc url_for(page_url)
|
20
|
+
xml.lastmod page.updated_at.to_date
|
21
|
+
end if page_url.present? and page.show_in_menu?
|
22
22
|
end
|
23
23
|
end
|
24
24
|
|
@@ -10,6 +10,11 @@ Refinery::Core.configure do |config|
|
|
10
10
|
# the default file system for storing resources and images
|
11
11
|
config.s3_backend = !(ENV['S3_KEY'].nil? || ENV['S3_SECRET'].nil?)
|
12
12
|
|
13
|
+
# Use a custom Dragonfly storage backend instead of the default
|
14
|
+
# file system for storing resources and images
|
15
|
+
# config.dragonfly_custom_backend_class = <%= Refinery::Core.dragonfly_custom_backend_class.inspect %>
|
16
|
+
# config.dragonfly_custom_backend_opts = <%= Refinery::Core.dragonfly_custom_backend_opts.inspect %>
|
17
|
+
|
13
18
|
# Whenever Refinery caches anything and can set a cache key, it will add
|
14
19
|
# a prefix to the cache key containing the string you set here.
|
15
20
|
# config.base_cache_key = <%= Refinery::Core.base_cache_key.inspect %>
|
@@ -25,22 +30,10 @@ Refinery::Core.configure do |config|
|
|
25
30
|
# Enable/disable authenticity token on frontend
|
26
31
|
# config.authenticity_token_on_frontend = <%= Refinery::Core.authenticity_token_on_frontend.inspect %>
|
27
32
|
|
28
|
-
# Hide/show child pages in menu
|
29
|
-
# config.menu_hide_children = <%= Refinery::Core.menu_hide_children.inspect %>
|
30
|
-
|
31
|
-
# CSS class selectors for menu helper
|
32
|
-
# config.menu_css = <%= Refinery::Core.menu_css.inspect %>
|
33
|
-
|
34
33
|
# Should set this if concerned about DOS attacks. See
|
35
34
|
# http://markevans.github.com/dragonfly/file.Configuration.html#Configuration
|
36
35
|
# config.dragonfly_secret = <%= Refinery::Core.dragonfly_secret.inspect %>
|
37
36
|
|
38
|
-
# Show/hide IE6 upgrade message in the backend
|
39
|
-
# config.ie6_upgrade_message_enabled = <%= Refinery::Core.ie6_upgrade_message_enabled.inspect %>
|
40
|
-
|
41
|
-
# Show/hide browser update message in the backend
|
42
|
-
# config.show_internet_explorer_upgrade_message = <%= Refinery::Core.show_internet_explorer_upgrade_message.inspect %>
|
43
|
-
|
44
37
|
# Add extra tags to the wymeditor whitelist e.g. = {'tag' => {'attributes' => {'1' => 'href'}}} or just {'tag' => {}}
|
45
38
|
# config.wymeditor_whitelist_tags = <%= Refinery::Core.wymeditor_whitelist_tags.inspect %>
|
46
39
|
|
@@ -49,4 +42,7 @@ Refinery::Core.configure do |config|
|
|
49
42
|
|
50
43
|
# Register extra stylesheet for backend (optional options)
|
51
44
|
# config.register_stylesheet "custom", :media => 'screen'
|
45
|
+
|
46
|
+
# Specify a different backend path than the default of /refinery.
|
47
|
+
# config.backend_route = <%= Refinery::Core.backend_route.inspect %>
|
52
48
|
end
|
@@ -1,13 +1,13 @@
|
|
1
1
|
login: &login
|
2
|
-
<% if
|
3
|
-
adapter:
|
2
|
+
<% if /mysql$/ === @database %>
|
3
|
+
adapter: mysql<%= '2' unless /jdbc/ === @database %>
|
4
4
|
encoding: utf8
|
5
5
|
reconnect: false
|
6
6
|
pool: 5
|
7
7
|
username: root
|
8
8
|
password:
|
9
9
|
#socket: /tmp/mysql.sock
|
10
|
-
<% elsif
|
10
|
+
<% elsif /postgresql/ === @database %>
|
11
11
|
adapter: postgresql
|
12
12
|
encoding: unicode
|
13
13
|
database: refinery_database_development
|
@@ -18,22 +18,18 @@ module Refinery
|
|
18
18
|
end
|
19
19
|
|
20
20
|
def generate
|
21
|
-
|
22
|
-
|
23
|
-
evaluate_templates!
|
24
|
-
|
25
|
-
unless options[:pretend]
|
26
|
-
merge_locales!
|
27
|
-
|
28
|
-
copy_or_merge_seeds!
|
21
|
+
default_generate!
|
22
|
+
end
|
29
23
|
|
30
|
-
|
24
|
+
def backend_route
|
25
|
+
@backend_route ||= if namespacing.underscore != plural_name
|
26
|
+
%Q{"#\{Refinery::Core.backend_route\}/#{namespacing.underscore}"}
|
27
|
+
else
|
28
|
+
"Refinery::Core.backend_route"
|
31
29
|
end
|
32
|
-
|
33
|
-
finalize_extension!
|
34
30
|
end
|
35
31
|
|
36
|
-
|
32
|
+
protected
|
37
33
|
|
38
34
|
def generator_command
|
39
35
|
'rails generate refinery:engine'
|