alchemy_cms 2.5.0.b5 → 2.5.0.b9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (209) hide show
  1. data/README.md +1 -1
  2. data/alchemy_cms.gemspec +2 -2
  3. data/app/assets/javascripts/alchemy/alchemy.base.js +0 -24
  4. data/app/assets/javascripts/alchemy/alchemy.growler.js +2 -4
  5. data/app/assets/javascripts/alchemy/alchemy.gui.js.coffee +0 -1
  6. data/app/assets/javascripts/alchemy/alchemy.page_sorter.js +1 -1
  7. data/app/assets/stylesheets/alchemy/base.scss +4 -20
  8. data/app/assets/stylesheets/alchemy/elements.scss +19 -31
  9. data/app/assets/stylesheets/alchemy/flash.scss +11 -0
  10. data/app/assets/stylesheets/alchemy/form_elements.scss +2 -14
  11. data/app/assets/stylesheets/alchemy/menubar.css.scss +1 -0
  12. data/app/assets/stylesheets/alchemy/mixins.scss +37 -2
  13. data/app/assets/stylesheets/alchemy/notices.scss +1 -0
  14. data/app/assets/stylesheets/alchemy/sitemap.scss +30 -0
  15. data/app/assets/stylesheets/alchemy/tables.scss +20 -27
  16. data/app/controllers/alchemy/admin/attachments_controller.rb +3 -3
  17. data/app/controllers/alchemy/admin/base_controller.rb +1 -1
  18. data/app/controllers/alchemy/admin/contents_controller.rb +2 -2
  19. data/app/controllers/alchemy/admin/elements_controller.rb +3 -3
  20. data/app/controllers/alchemy/admin/essence_pictures_controller.rb +2 -2
  21. data/app/controllers/alchemy/admin/pages_controller.rb +16 -9
  22. data/app/controllers/alchemy/admin/pictures_controller.rb +8 -8
  23. data/app/controllers/alchemy/admin/resources_controller.rb +1 -1
  24. data/app/controllers/alchemy/admin/tags_controller.rb +4 -4
  25. data/app/controllers/alchemy/admin/users_controller.rb +3 -3
  26. data/app/controllers/alchemy/base_controller.rb +10 -12
  27. data/app/controllers/alchemy/messages_controller.rb +2 -2
  28. data/app/controllers/alchemy/pages_controller.rb +4 -1
  29. data/app/controllers/alchemy/pictures_controller.rb +1 -4
  30. data/app/controllers/alchemy/user_sessions_controller.rb +5 -5
  31. data/app/helpers/alchemy/admin/attachments_helper.rb +1 -1
  32. data/app/helpers/alchemy/admin/base_helper.rb +13 -13
  33. data/app/helpers/alchemy/admin/contents_helper.rb +6 -6
  34. data/app/helpers/alchemy/admin/elements_helper.rb +2 -2
  35. data/app/helpers/alchemy/admin/essences_helper.rb +8 -8
  36. data/app/helpers/alchemy/admin/pages_helper.rb +13 -7
  37. data/app/helpers/alchemy/base_helper.rb +20 -5
  38. data/app/helpers/alchemy/elements_helper.rb +2 -2
  39. data/app/helpers/alchemy/essences_helper.rb +2 -2
  40. data/app/helpers/alchemy/pages_helper.rb +2 -3
  41. data/app/models/alchemy/cell.rb +11 -3
  42. data/app/models/alchemy/content.rb +17 -17
  43. data/app/models/alchemy/element.rb +49 -26
  44. data/app/models/alchemy/legacy_page_url.rb +6 -0
  45. data/app/models/alchemy/page.rb +24 -45
  46. data/app/models/alchemy/picture.rb +1 -2
  47. data/app/views/alchemy/admin/attachments/_archive_overlay.html.erb +3 -3
  48. data/app/views/alchemy/admin/attachments/_attachment.html.erb +6 -6
  49. data/app/views/alchemy/admin/attachments/_files_list.html.erb +2 -2
  50. data/app/views/alchemy/admin/attachments/edit.html.erb +5 -3
  51. data/app/views/alchemy/admin/attachments/index.html.erb +3 -3
  52. data/app/views/alchemy/admin/attachments/new.html.erb +2 -2
  53. data/app/views/alchemy/admin/clipboard/clear.js.erb +1 -1
  54. data/app/views/alchemy/admin/clipboard/index.html.erb +3 -3
  55. data/app/views/alchemy/admin/clipboard/insert.js.erb +2 -2
  56. data/app/views/alchemy/admin/clipboard/remove.js.erb +4 -4
  57. data/app/views/alchemy/admin/contents/_missing.html.erb +2 -2
  58. data/app/views/alchemy/admin/contents/create.js.erb +1 -1
  59. data/app/views/alchemy/admin/contents/new.html.erb +3 -3
  60. data/app/views/alchemy/admin/dashboard/index.html.erb +12 -12
  61. data/app/views/alchemy/admin/elements/_add_picture.html.erb +1 -1
  62. data/app/views/alchemy/admin/elements/_element.html.erb +1 -1
  63. data/app/views/alchemy/admin/elements/_element_foot.html.erb +5 -5
  64. data/app/views/alchemy/admin/elements/_element_head.html.erb +6 -6
  65. data/app/views/alchemy/admin/elements/_elements_select.html.erb +2 -2
  66. data/app/views/alchemy/admin/elements/_new_element_form.html.erb +4 -4
  67. data/app/views/alchemy/admin/elements/_picture_gallery_editor.html.erb +1 -1
  68. data/app/views/alchemy/admin/elements/create.js.erb +2 -2
  69. data/app/views/alchemy/admin/elements/index.html.erb +2 -2
  70. data/app/views/alchemy/admin/elements/list.js.erb +1 -1
  71. data/app/views/alchemy/admin/elements/new.html.erb +4 -4
  72. data/app/views/alchemy/admin/elements/order.js.erb +1 -1
  73. data/app/views/alchemy/admin/elements/trash.js.erb +1 -1
  74. data/app/views/alchemy/admin/elements/update.js.erb +1 -1
  75. data/app/views/alchemy/admin/essence_files/edit.html.erb +5 -5
  76. data/app/views/alchemy/admin/essence_pictures/crop.html.erb +4 -4
  77. data/app/views/alchemy/admin/essence_pictures/edit.html.erb +4 -4
  78. data/app/views/alchemy/admin/languages/_form.html.erb +6 -10
  79. data/app/views/alchemy/admin/languages/_language.html.erb +4 -4
  80. data/app/views/alchemy/admin/languages/_table.html.erb +1 -1
  81. data/app/views/alchemy/admin/languages/index.html.erb +1 -1
  82. data/app/views/alchemy/admin/layoutpages/_layoutpage.html.erb +6 -6
  83. data/app/views/alchemy/admin/layoutpages/index.html.erb +8 -8
  84. data/app/views/alchemy/admin/pages/_contactform_links.html.erb +7 -7
  85. data/app/views/alchemy/admin/pages/_create_language_form.html.erb +10 -9
  86. data/app/views/alchemy/admin/pages/_external_link.html.erb +7 -7
  87. data/app/views/alchemy/admin/pages/_file_link.html.erb +6 -6
  88. data/app/views/alchemy/admin/pages/_internal_link.html.erb +5 -5
  89. data/app/views/alchemy/admin/pages/_new_page_form.html.erb +1 -1
  90. data/app/views/alchemy/admin/pages/_page.html.erb +28 -28
  91. data/app/views/alchemy/admin/pages/_page_for_links.html.erb +5 -5
  92. data/app/views/alchemy/admin/pages/_page_infos.html.erb +3 -3
  93. data/app/views/alchemy/admin/pages/_page_status.html.erb +3 -3
  94. data/app/views/alchemy/admin/pages/_sitemap.html.erb +1 -1
  95. data/app/views/alchemy/admin/pages/configure.html.erb +11 -11
  96. data/app/views/alchemy/admin/pages/configure_external.html.erb +4 -4
  97. data/app/views/alchemy/admin/pages/destroy.js.erb +0 -1
  98. data/app/views/alchemy/admin/pages/edit.html.erb +35 -35
  99. data/app/views/alchemy/admin/pages/flush.js.erb +1 -1
  100. data/app/views/alchemy/admin/pages/fold.js.erb +0 -1
  101. data/app/views/alchemy/admin/pages/index.html.erb +14 -14
  102. data/app/views/alchemy/admin/pages/link.html.erb +4 -4
  103. data/app/views/alchemy/admin/pages/locked.html.erb +1 -1
  104. data/app/views/alchemy/admin/pages/new.html.erb +4 -4
  105. data/app/views/alchemy/admin/pages/update.js.erb +2 -2
  106. data/app/views/alchemy/admin/partials/_autocomplete_tag_list.html.erb +1 -1
  107. data/app/views/alchemy/admin/partials/_flash_notices.html.erb +3 -3
  108. data/app/views/alchemy/admin/partials/_flash_upload.html.erb +8 -8
  109. data/app/views/alchemy/admin/partials/_language_tree_select.html.erb +1 -1
  110. data/app/views/alchemy/admin/partials/_main_navigation_entry.html.erb +1 -1
  111. data/app/views/alchemy/admin/partials/_remote_search_form.html.erb +2 -2
  112. data/app/views/alchemy/admin/partials/_search_form.html.erb +2 -2
  113. data/app/views/alchemy/admin/partials/_sub_navigation_tab.html.erb +1 -1
  114. data/app/views/alchemy/admin/partials/_upload_form.html.erb +11 -11
  115. data/app/views/alchemy/admin/pictures/_archive.html.erb +13 -13
  116. data/app/views/alchemy/admin/pictures/_filter_and_size_bar.html.erb +7 -7
  117. data/app/views/alchemy/admin/pictures/_filter_bar.html.erb +4 -4
  118. data/app/views/alchemy/admin/pictures/_overlay_picture_list.html.erb +1 -1
  119. data/app/views/alchemy/admin/pictures/_picture.html.erb +7 -7
  120. data/app/views/alchemy/admin/pictures/_picture_to_assign.html.erb +1 -1
  121. data/app/views/alchemy/admin/pictures/_tag_list.html.erb +2 -2
  122. data/app/views/alchemy/admin/pictures/edit.html.erb +2 -2
  123. data/app/views/alchemy/admin/pictures/edit_multiple.html.erb +6 -6
  124. data/app/views/alchemy/admin/pictures/index.html.erb +10 -10
  125. data/app/views/alchemy/admin/pictures/info.html.erb +2 -2
  126. data/app/views/alchemy/admin/pictures/new.html.erb +2 -2
  127. data/app/views/alchemy/admin/resources/_boolean.html.erb +5 -0
  128. data/app/views/alchemy/admin/resources/_datetime.html.erb +2 -0
  129. data/app/views/alchemy/admin/resources/_form.html.erb +17 -28
  130. data/app/views/alchemy/admin/resources/_resource.html.erb +4 -4
  131. data/app/views/alchemy/admin/resources/_string.html.erb +5 -0
  132. data/app/views/alchemy/admin/resources/_table.html.erb +1 -1
  133. data/app/views/alchemy/admin/resources/_text.html.erb +5 -0
  134. data/app/views/alchemy/admin/resources/index.html.erb +1 -1
  135. data/app/views/alchemy/admin/tags/_tag.html.erb +4 -4
  136. data/app/views/alchemy/admin/tags/edit.html.erb +4 -4
  137. data/app/views/alchemy/admin/tags/index.html.erb +5 -5
  138. data/app/views/alchemy/admin/tags/new.html.erb +2 -2
  139. data/app/views/alchemy/admin/trash/clear.js.coffee +1 -1
  140. data/app/views/alchemy/admin/trash/index.html.erb +3 -3
  141. data/app/views/alchemy/admin/users/_table.html.erb +3 -3
  142. data/app/views/alchemy/admin/users/_user.html.erb +6 -6
  143. data/app/views/alchemy/admin/users/index.html.erb +4 -4
  144. data/app/views/alchemy/base/error_notice.html.erb +1 -4
  145. data/app/views/alchemy/elements/_editor_not_found.html.erb +2 -2
  146. data/app/views/alchemy/essences/_essence_boolean_view.html.erb +1 -1
  147. data/app/views/alchemy/essences/_essence_file_editor.html.erb +7 -7
  148. data/app/views/alchemy/essences/_essence_picture_editor.html.erb +5 -5
  149. data/app/views/alchemy/essences/_essence_picture_tools.html.erb +8 -8
  150. data/app/views/alchemy/essences/_linkable_essence_tools.html.erb +2 -2
  151. data/app/views/alchemy/search/_form.html.erb +2 -2
  152. data/app/views/alchemy/search/_result.html.erb +1 -1
  153. data/app/views/alchemy/search/_results.html.erb +3 -3
  154. data/app/views/alchemy/user_sessions/leave.html.erb +5 -5
  155. data/app/views/alchemy/user_sessions/login.html.erb +1 -1
  156. data/app/views/alchemy/user_sessions/signup.html.erb +2 -2
  157. data/app/views/kaminari/_gap.html.erb +1 -1
  158. data/app/views/kaminari/_next_page.html.erb +2 -2
  159. data/app/views/kaminari/_prev_page.html.erb +2 -2
  160. data/app/views/layouts/alchemy/admin.html.erb +7 -7
  161. data/bin/alchemy +1 -1
  162. data/config/authorization_rules.rb +1 -3
  163. data/config/locales/alchemy.de.yml +33 -23
  164. data/config/locales/alchemy.en.yml +31 -6
  165. data/db/migrate/{20121026100815_alchemy_two_point_three.rb → 20121118000000_alchemy_two_point_four.rb} +51 -28
  166. data/db/migrate/20130110212411_create_alchemy_legacy_page_urls.rb +11 -0
  167. data/lib/alchemy/capistrano.rb +22 -30
  168. data/lib/alchemy/errors.rb +45 -0
  169. data/lib/alchemy/i18n.rb +7 -5
  170. data/lib/alchemy/logger.rb +16 -0
  171. data/lib/alchemy/page_layout.rb +3 -3
  172. data/lib/alchemy/resource.rb +17 -1
  173. data/lib/alchemy/resources_helper.rb +8 -1
  174. data/lib/alchemy/upgrader.rb +9 -0
  175. data/lib/alchemy/version.rb +1 -1
  176. data/lib/alchemy_cms.rb +1 -6
  177. data/lib/rails/generators/alchemy/scaffold/files/elements.yml +41 -19
  178. data/lib/rails/generators/alchemy/scaffold/scaffold_generator.rb +13 -0
  179. data/lib/tasks/alchemy/db.rake +5 -11
  180. data/lib/tasks/alchemy/install.rake +7 -7
  181. data/spec/controllers/admin/pages_controller_spec.rb +14 -2
  182. data/spec/controllers/pages_controller_spec.rb +50 -17
  183. data/spec/dummy/config/application.rb +1 -1
  184. data/spec/dummy/db/migrate/{20121026100815_alchemy_two_point_three.rb → 20121118000000_alchemy_two_point_four.rb} +51 -28
  185. data/spec/dummy/db/migrate/20130110212411_create_alchemy_legacy_page_urls.rb +11 -0
  186. data/spec/dummy/db/schema.rb +10 -1
  187. data/spec/factories.rb +1 -0
  188. data/spec/integration/admin/picture_library_integration_spec.rb +8 -2
  189. data/spec/integration/security_spec.rb +2 -2
  190. data/spec/integration/translation_integration_spec.rb +20 -4
  191. data/spec/libraries/resources_helper_spec.rb +1 -1
  192. data/spec/models/cell_spec.rb +45 -0
  193. data/spec/models/page_spec.rb +19 -2
  194. data/spec/models/picture_spec.rb +12 -0
  195. data/spec/routing_spec.rb +115 -115
  196. data/spec/spec_helper.rb +3 -0
  197. data/spec/support/alchemy/specs_helpers.rb +6 -2
  198. data/spec/support/image.png +0 -0
  199. data/spec/support/image2.PNG +0 -0
  200. data/spec/support/image3.jpeg +0 -0
  201. metadata +27 -23
  202. data/db/migrate/20121113115120_create_alchemy_essence_links.rb +0 -13
  203. data/db/migrate/20121115100736_add_cached_tag_list_to_elements_pages_and_users.rb +0 -7
  204. data/db/migrate/20121116140636_add_cached_tag_list_to_alchemy_attachments.rb +0 -5
  205. data/db/migrate/20121116141016_change_alchemy_pictures_tag_list_column.rb +0 -9
  206. data/spec/dummy/db/migrate/20121113115120_create_alchemy_essence_links.rb +0 -13
  207. data/spec/dummy/db/migrate/20121115100736_add_cached_tag_list_to_elements_pages_and_users.rb +0 -7
  208. data/spec/dummy/db/migrate/20121116140636_add_cached_tag_list_to_alchemy_attachments.rb +0 -5
  209. data/spec/dummy/db/migrate/20121116141016_change_alchemy_pictures_tag_list_column.rb +0 -9
@@ -13,7 +13,7 @@
13
13
  :url => @url_prefix + page_for_links.urlname
14
14
  },
15
15
  :class => "show_elements_to_link",
16
- :title => t('show_elements_from_page')
16
+ :title => _t('show_elements_from_page')
17
17
  ) %>
18
18
  <div id="elements_for_page_<%= page_for_links.id %>" style="display: none" class="elements_for_page">
19
19
  <%= image_tag("alchemy/ajax_loader.gif", :alt => '') %>
@@ -21,9 +21,9 @@
21
21
  <% end %>
22
22
  </div>
23
23
  <div class="page_infos">
24
- <span class="page_status <%= page_for_links.public ? 'public' : 'not_public' %>" title="<%= page_for_links.public ? t('Page public') : t('Page not public') %>"></span>
25
- <span class="page_status <%= page_for_links.visible ? 'visible' : 'not_visible' %>" title="<%= page_for_links.visible ? t('Page visible') : t('Page not visible') %>"></span>
26
- <span class="page_status <%= page_for_links.restricted ? 'restricted' : 'not_restricted' %>" title="<%= page_for_links.restricted ? t('Page restricted') : t('Page not restricted') %>"></span>
24
+ <span class="page_status <%= page_for_links.public ? 'public' : 'not_public' %>" title="<%= page_for_links.status_title(:public) %>"></span>
25
+ <span class="page_status <%= page_for_links.visible ? 'visible' : 'not_visible' %>" title="<%= page_for_links.status_title(:visible) %>"></span>
26
+ <span class="page_status <%= page_for_links.restricted ? 'restricted' : 'not_restricted' %>" title="<%= page_for_links.status_title(:restricted) %>"></span>
27
27
  </div>
28
28
  <div class="sitemap_sitename" id="sitemap_sitename_<%= page_for_links.id %>" name="<%= parse_sitemap_name(page_for_links) %>">
29
29
  <% if page_for_links.redirects_to_external? %>
@@ -34,7 +34,7 @@
34
34
  'page-id' => page_for_links.id,
35
35
  :url => @url_prefix + page_for_links.urlname
36
36
  },
37
- :title => t('page_for_links.choose_page', :name => page_for_links.name),
37
+ :title => _t('page_for_links.choose_page', :name => page_for_links.name),
38
38
  :class => "sitemap_pagename_link #{cycle('even', 'odd')}"
39
39
  }) %>
40
40
  <% end %>
@@ -1,3 +1,3 @@
1
- <span class="page_status <%= page.public ? 'public' : 'not_public' %>" title="<%= page.public ? t('Page public') : t('Page not public') %>"></span>
2
- <span class="page_status <%= page.visible ? 'visible' : 'not_visible' %>" title="<%= page.visible ? t('Page visible') : t('Page not visible') %>"></span>
3
- <span class="page_status <%= page.restricted ? 'restricted' : 'not_restricted' %>" title="<%= page.restricted ? t('Page restricted') : t('Page not restricted') %>"></span>
1
+ <span class="page_status <%= page.public ? 'public' : 'not_public' %>" title="<%= page.status_title(:public) %>"></span>
2
+ <span class="page_status <%= page.visible ? 'visible' : 'not_visible' %>" title="<%= page.status_title(:visible) %>"></span>
3
+ <span class="page_status <%= page.restricted ? 'restricted' : 'not_restricted' %>" title="<%= page.status_title(:restricted) %>"></span>
@@ -3,7 +3,7 @@
3
3
  <%- if multi_language? -%>
4
4
  <span class="page_language"><%= @page.language_code %></span>
5
5
  <%- end -%>
6
- <span class="page_status <%= @page.public ? 'public' : 'not_public' %>" title="<%= @page.public ? t('Page public') : t('Page not public') %>"></span>
7
- <span class="page_status <%= @page.visible ? 'visible' : 'not_visible' %>" title="<%= @page.visible ? t('Page visible') : t('Page not visible') %>"></span>
8
- <span class="page_status <%= @page.restricted ? 'restricted' : 'not_restricted' %>" title="<%= @page.restricted ? t('Page restricted') : t('Page not restricted') %>"></span>
6
+ <span class="page_status <%= @page.public ? 'public' : 'not_public' %>" title="<%= @page.status_title(:public) %>"></span>
7
+ <span class="page_status <%= @page.visible ? 'visible' : 'not_visible' %>" title="<%= @page.status_title(:visible) %>"></span>
8
+ <span class="page_status <%= @page.restricted ? 'restricted' : 'not_restricted' %>" title="<%= @page.status_title(:restricted) %>"></span>
9
9
  </span>
@@ -1,3 +1,3 @@
1
- <ul id="sitemap" class="list">
1
+ <ul id="sitemap" class="list<%= @sorting ? ' sorting' : nil %>">
2
2
  <%= render :partial => 'page', :object => @page_root %>
3
3
  </ul>
@@ -2,14 +2,14 @@
2
2
  <div id="errors"></div>
3
3
  <table id="page_names">
4
4
  <tr>
5
- <td class="label"><%= t("page_type") %>: </td>
5
+ <td class="label"><%= _t("page_type") %>: </td>
6
6
  <td class="select">
7
7
  <%= f.select('page_layout', @page_layouts, {}, {:class => 'alchemy_selectbox long'}) %>
8
8
  </td>
9
9
  </tr>
10
10
  <% unless @page.layoutpage %>
11
11
  <tr>
12
- <td class="label"><%= t("page_status") %>: </td>
12
+ <td class="label"><%= _t("page_status") %>: </td>
13
13
  <td class="checkbox long">
14
14
  <%= f.check_box :public %>
15
15
  <%= f.label :public %><br/>
@@ -26,7 +26,7 @@
26
26
  <% end %>
27
27
  <% unless @page.layoutpage %>
28
28
  <tr>
29
- <td colspan="2" class="heading"><%= t("names") %></td>
29
+ <td colspan="2" class="heading"><%= _t("names") %></td>
30
30
  </tr>
31
31
  <% end %>
32
32
  <tr>
@@ -43,10 +43,10 @@
43
43
  <td class="input"><%= f.text_field "title", :size => 31, :class => "thin_border long" %></td>
44
44
  </tr>
45
45
  <tr>
46
- <td colspan="2" class="heading"><%= t("meta_data") %></td>
46
+ <td colspan="2" class="heading"><%= _t("meta_data") %></td>
47
47
  </tr>
48
48
  <tr>
49
- <td class="label"><%= t("search_engines") %>: </td>
49
+ <td class="label"><%= _t("search_engines") %>: </td>
50
50
  <td class="checkbox long">
51
51
  <%= f.check_box "robot_index" %>
52
52
  <%= f.label "robot_index" %><br/>
@@ -62,6 +62,11 @@
62
62
  <td class="label"><%= f.label "meta_keywords" %>*:&nbsp;</td>
63
63
  <td class="input">
64
64
  <%= f.text_area "meta_keywords", :class => "thin_border long" %><br/>
65
+ <% if !@page.layoutpage %>
66
+ <p class="foot_note">
67
+ * <%= _t('pages.update.comma_seperated') %>
68
+ </p>
69
+ <% end %>
65
70
  </td>
66
71
  </tr>
67
72
  <% end %>
@@ -75,12 +80,7 @@
75
80
  <% end %>
76
81
  <tr>
77
82
  <td colspan="2" class="submit">
78
- <% if !@page.layoutpage || @page.taggable? %>
79
- <p class="foot_note">
80
- *<%= t('pages.update.comma_seperated') %>
81
- </p>
82
- <% end %>
83
- <%= f.button t("save"), :class => 'button' %>
83
+ <%= f.button _t("save"), :class => 'button' %>
84
84
  </td>
85
85
  </tr>
86
86
  </table>
@@ -2,13 +2,13 @@
2
2
  <div id="errors"></div>
3
3
  <table id="page_names">
4
4
  <tr>
5
- <td class="label"><%= t("page_type") %>: </td>
5
+ <td class="label"><%= _t("page_type") %>: </td>
6
6
  <td class="value long">
7
7
  <p><%= @page.layout_display_name %></p>
8
8
  </td>
9
9
  </tr>
10
10
  <tr>
11
- <td class="label"><%= t("page_status") %>: </td>
11
+ <td class="label"><%= _t("page_status") %>: </td>
12
12
  <td class="checkbox long">
13
13
  <%= f.check_box :visible -%>
14
14
  <%= f.label :visible %><br/>
@@ -19,7 +19,7 @@
19
19
  </td>
20
20
  </tr>
21
21
  <tr>
22
- <td colspan="2" class="heading"><%= t("names") %></td>
22
+ <td colspan="2" class="heading"><%= _t("names") %></td>
23
23
  </tr>
24
24
  <tr>
25
25
  <td class="label"><%= f.label "name" %>:&nbsp;</td>
@@ -34,7 +34,7 @@
34
34
  <td class="input"><%= f.text_field "title", :size => 31, :class => "thin_border long" %></td>
35
35
  </tr>
36
36
  <tr>
37
- <td colspan="2" class="submit"><%= f.button t("save"), :class => 'button' %></td>
37
+ <td colspan="2" class="submit"><%= f.button _t("save"), :class => 'button' %></td>
38
38
  </tr>
39
39
  </table>
40
40
  <% end %>
@@ -8,7 +8,6 @@ window.location.replace('<%= alchemy.admin_layoutpages_path -%>');
8
8
 
9
9
  $('#sitemap').replaceWith('<%= escape_javascript(render(:partial => "sitemap")) -%>');
10
10
  Alchemy.growl('<%= @message -%>');
11
- Alchemy.Tooltips();
12
11
  Alchemy.overlayObserver('#sitemap');
13
12
 
14
13
  <% else %>
@@ -1,7 +1,7 @@
1
1
  <% content_for(:title) { @page.name } %>
2
2
 
3
3
  <% content_for(:subnav_additions) do %>
4
- <label><%= t('Active Pages') %> &raquo;</label>
4
+ <label><%= _t('Active Pages') %> &raquo;</label>
5
5
  <% @locked_pages.each do |page| %>
6
6
  <% if @page == page %>
7
7
  <%= render :partial => 'page_status' %>
@@ -13,7 +13,7 @@
13
13
  </span>
14
14
  <% end %>
15
15
  <%= form_tag(alchemy.unlock_admin_page_path(page), :remote => true) do %>
16
- <button class="icon_button small" title="<%= t('explain_unlocking') %>">
16
+ <button class="icon_button small" title="<%= _t('explain_unlocking') %>">
17
17
  <%= render_icon('close small') %>
18
18
  </button>
19
19
  <% end %>
@@ -26,19 +26,19 @@
26
26
  <div id="toolbar_buttons">
27
27
  <div class="button_with_label">
28
28
  <%= form_tag alchemy.unlock_admin_page_path(@page, :redirect_to => @layoutpage ? alchemy.admin_layoutpages_path : alchemy.admin_pages_path), :id => 'unlock_page_form' do %>
29
- <button class="icon_button" title="<%= t('explain_unlocking') %>">
29
+ <button class="icon_button" title="<%= _t('explain_unlocking') %>">
30
30
  <%= render_icon('close') %>
31
31
  </button>
32
- <label><%= t("unlock_page") %></label>
32
+ <label><%= _t("unlock_page") %></label>
33
33
  <% end %>
34
34
  </div>
35
35
  <% unless @page.layoutpage? %>
36
36
  <div class="button_with_label">
37
37
  <%= form_tag alchemy.visit_admin_page_path(@page), :id => 'visit_page_form' do %>
38
- <button class="icon_button" title="<%= t('Visit page') %>">
38
+ <button class="icon_button" title="<%= _t('Visit page') %>">
39
39
  <%= render_icon('visit_page') %>
40
40
  </button>
41
- <label><%= t("Visit page") %></label>
41
+ <label><%= _t("Visit page") %></label>
42
42
  <% end %>
43
43
  </div>
44
44
  <% end %>
@@ -47,45 +47,45 @@
47
47
  render_icon('settings'),
48
48
  alchemy.configure_admin_page_path(@page),
49
49
  {
50
- :title => t('edit_page_properties'),
50
+ :title => _t('edit_page_properties'),
51
51
  :size => @page.layoutpage? ? '410x150' : '410x650'
52
52
  },
53
53
  :class => :icon_button,
54
- :title => t('edit_page_properties')
54
+ :title => _t('edit_page_properties')
55
55
  ) %>
56
- <label><%= t('page_properties') %></label>
56
+ <label><%= _t('page_properties') %></label>
57
57
  </div>
58
58
  <% if configuration(:cache_pages) && !@page.layoutpage? %>
59
59
  <div class="button_with_label">
60
60
  <%= form_tag alchemy.publish_admin_page_path(@page), :id => 'publish_page_form' do %>
61
- <button class="icon_button" title="<%= t('explain_publishing') %>">
61
+ <button class="icon_button" title="<%= _t('explain_publishing') %>">
62
62
  <%= render_icon('publish') %>
63
63
  </button>
64
- <label><%= t("Publish page") %></label>
64
+ <label><%= _t("Publish page") %></label>
65
65
  <% end %>
66
66
  </div>
67
67
  <% end %>
68
68
  <div class="button_with_label">
69
69
  <%= select_tag('preview_size', preview_sizes_for_select, :class => 'alchemy_selectbox short') %>
70
- <label><%= t :preview_size %></label>
70
+ <label><%= _t(:preview_size) %></label>
71
71
  </div>
72
72
  </div>
73
73
  <div id="toolbar_buttons_right">
74
74
  <div class="button_with_label" id="show_preview_window">
75
75
  <%= link_to(render_icon(:preview_window), '#', {
76
76
  :onclick => "Alchemy.openPreviewWindow()",
77
- :title => t('Show Preview Window'),
77
+ :title => _t('Show Preview Window'),
78
78
  :class => :icon_button
79
79
  }) %>
80
- <label><%= t('Show Preview Window') %></label>
80
+ <label><%= _t('Show Preview Window') %></label>
81
81
  </div>
82
82
  <div class="button_with_label" id="show_element_window">
83
83
  <%= link_to(render_icon(:element_window), '#', {
84
84
  :onclick => "Alchemy.openElementsWindow()",
85
- :title => t('Show Elements Window'),
85
+ :title => _t('Show Elements Window'),
86
86
  :class => :icon_button
87
87
  }) %>
88
- <label><%= t('Show Elements Window') %></label>
88
+ <label><%= _t('Show Elements Window') %></label>
89
89
  </div>
90
90
  </div>
91
91
  <% end %>
@@ -95,27 +95,27 @@
95
95
  <script type="text/javascript" charset="utf-8">
96
96
 
97
97
  Alchemy.openPreviewWindow = function() {
98
- Alchemy.PreviewWindow.init('<%= admin_page_url(@page) %>', '<%= t("Page Preview") %>');
98
+ Alchemy.PreviewWindow.init('<%= admin_page_url(@page) %>', '<%= _t("Page Preview") %>');
99
99
  }
100
100
 
101
101
  Alchemy.openElementsWindow = function() {
102
102
  Alchemy.ElementsWindow.init('<%= alchemy.admin_elements_path(:page_id => @page.id) %>', {
103
103
  texts: {
104
- title: '<%= t("Elements") %>',
105
- dirtyTitle: '<%= t("Warning!") %>',
106
- dirtyMessage: '<%= t(:element_dirty_close_window_notice) %>',
107
- okLabel: '<%= t("Yes") %>',
108
- cancelLabel: '<%= t("No") %>'
104
+ title: '<%= _t("Elements") %>',
105
+ dirtyTitle: '<%= _t("Warning!") %>',
106
+ dirtyMessage: '<%= _t(:element_dirty_close_window_notice) %>',
107
+ okLabel: '<%= _t("Yes") %>',
108
+ cancelLabel: '<%= _t("No") %>'
109
109
  },
110
110
  toolbarButtons: [
111
111
  {
112
- title: '<%= t("New Element") %>',
113
- label: '<%= t("New Element") %>',
112
+ title: '<%= _t("New Element") %>',
113
+ label: '<%= _t("New Element") %>',
114
114
  iconClass: 'new_element',
115
115
  onClick: function() {
116
116
  Alchemy.openWindow(
117
117
  '<%= alchemy.new_admin_element_path(:page_id => @page.id) %>',
118
- '<%= t("New Element") %>',
118
+ '<%= _t("New Element") %>',
119
119
  320,
120
120
  120,
121
121
  false,
@@ -125,14 +125,14 @@
125
125
  }
126
126
  },
127
127
  {
128
- title: '<%= t("Clipboard") %>',
129
- label: '<%= t("Show clipboard") %>',
128
+ title: '<%= _t("Clipboard") %>',
129
+ label: '<%= _t("Show clipboard") %>',
130
130
  iconClass: 'clipboard<%= clipboard_empty?("elements") ? "" : " full" %>',
131
131
  buttonId: 'clipboard_button',
132
132
  onClick: function() {
133
133
  Alchemy.openWindow(
134
134
  '<%= alchemy.admin_clipboard_path(:remarkable_type => "elements") %>',
135
- '<%= t("Clipboard") %>',
135
+ '<%= _t("Clipboard") %>',
136
136
  380,
137
137
  270,
138
138
  false,
@@ -142,12 +142,12 @@
142
142
  }
143
143
  },
144
144
  {
145
- title: '<%= t("Show trash") %>',
146
- label: '<%= t("Show trash") %>',
145
+ title: '<%= _t("Show trash") %>',
146
+ label: '<%= _t("Show trash") %>',
147
147
  iconClass: 'trash<%= trash_empty?("elements") ? "" : " full" %>',
148
148
  buttonId: 'element_trash_button',
149
149
  onClick: function() {
150
- Alchemy.openTrashWindow(<%= @page.id %>, '<%= t("Trash") %>');
150
+ Alchemy.openTrashWindow(<%= @page.id %>, '<%= _t("Trash") %>');
151
151
  }
152
152
  }
153
153
  ]
@@ -173,10 +173,10 @@
173
173
 
174
174
  jQuery(function($) {
175
175
  var texts = {
176
- title: '<%= t("Warning!") %>',
177
- message: '<%= t(:element_dirty_page_leave_warning) %>',
178
- okLabel: '<%= t("Yes") %>',
179
- cancelLabel: '<%= t("No") %>'
176
+ title: '<%= _t("Warning!") %>',
177
+ message: '<%= _t(:element_dirty_page_leave_warning) %>',
178
+ okLabel: '<%= _t("Yes") %>',
179
+ cancelLabel: '<%= _t("No") %>'
180
180
  };
181
181
  $('#unlock_page_form, #visit_page_form, #publish_page_form').on('submit', function(event) {
182
182
  var not_dirty = Alchemy.checkPageDirtyness(this, texts);
@@ -1,2 +1,2 @@
1
- Alchemy.growl('<%= t("Page cache flushed") -%>');
1
+ Alchemy.growl('<%= _t("Page cache flushed") -%>');
2
2
  Alchemy.pleaseWaitOverlay(false);
@@ -1,5 +1,4 @@
1
1
  (function($) {
2
2
  $('#page_<%= @page.id -%>').replaceWith('<%= escape_javascript(render(:partial => "page", :locals => {:page => @page})) -%>');
3
- Alchemy.Tooltips();
4
3
  Alchemy.overlayObserver('#page_<%= @page.id -%>');
5
4
  })(jQuery);
@@ -1,6 +1,6 @@
1
1
  <%- content_for(:subnav_additions) do -%>
2
2
  <%- unless @locked_pages.blank? -%>
3
- <label><%= t('Active Pages') %> &raquo;</label>
3
+ <label><%= _t('Active Pages') %> &raquo;</label>
4
4
  <%- @locked_pages.each do |page| -%>
5
5
  <div class="subnavi_tab wide" id="locked_page_<%= page.id %>">
6
6
  <%= link_to alchemy.edit_admin_page_path(page) do %>
@@ -9,7 +9,7 @@
9
9
  </span>
10
10
  <% end %>
11
11
  <%= form_tag(alchemy.unlock_admin_page_path(page), :remote => true) do %>
12
- <button class="icon_button small" title="<%= t('explain_unlocking') %>">
12
+ <button class="icon_button small" title="<%= _t('explain_unlocking') %>">
13
13
  <%= render_icon('close small') %>
14
14
  </button>
15
15
  <% end %>
@@ -29,9 +29,9 @@
29
29
  :remote => true,
30
30
  :method => :post,
31
31
  :class => 'icon_button please_wait',
32
- :title => t('Flush page cache')
32
+ :title => _t('Flush page cache')
33
33
  ) -%>
34
- <label><%= t('Flush page cache') %></label>
34
+ <label><%= _t('Flush page cache') %></label>
35
35
  </div>
36
36
  <%- end -%>
37
37
  <%- permitted_to?(:sort, :alchemy_admin_pages) do -%>
@@ -43,9 +43,9 @@
43
43
  :method => :get,
44
44
  :remote => true,
45
45
  :class => 'icon_button please_wait',
46
- :title => t('Sort pages')
46
+ :title => _t('Sort pages')
47
47
  ) -%>
48
- <label><%= t('Sort pages') %></label>
48
+ <label><%= _t('Sort pages') %></label>
49
49
  </div>
50
50
  <%- end -%>
51
51
  <div class="button_with_label" id="clipboard_button">
@@ -53,13 +53,13 @@
53
53
  render_icon("clipboard#{clipboard_empty?('pages') ? '' : ' full'}"),
54
54
  alchemy.admin_clipboard_path(:remarkable_type => 'pages'),
55
55
  {
56
- :title => t('Clipboard'),
56
+ :title => _t('Clipboard'),
57
57
  :size => '380x270'
58
58
  },
59
59
  :class => 'icon_button',
60
- :title => t('Show clipboard')
60
+ :title => _t('Show clipboard')
61
61
  ) -%>
62
- <label><%= t('Show clipboard') %></label>
62
+ <label><%= _t('Show clipboard') %></label>
63
63
  </div>
64
64
  </div>
65
65
  <%- end -%>
@@ -70,17 +70,17 @@
70
70
  <div id="sort_panel" style="display: none">
71
71
  <div class="info">
72
72
  <%= render_icon('info') %>
73
- <%= t('explain_sitemap_dragndrop_sorting') %>
73
+ <%= _t('explain_sitemap_dragndrop_sorting') %>
74
74
  </div>
75
75
  <div class="buttons">
76
- <%= link_to( t('cancel'), alchemy.admin_pages_path, :class => 'button' ) %>&nbsp;
77
- <%= submit_tag( t('save order'), :id => 'save_page_order', :class => 'button' ) %>
76
+ <%= link_to( _t('cancel'), alchemy.admin_pages_path, :class => 'button' ) %>&nbsp;
77
+ <%= submit_tag( _t('save order'), :id => 'save_page_order', :class => 'button' ) %>
78
78
  </div>
79
79
  </div>
80
80
 
81
81
  <h2 id="sitemap_heading">
82
- <span class="page_name"><%= t('Name') %></span>
83
- <span class="page_infos"><%= t('Status') %></span>
82
+ <span class="page_name"><%= _t('Name') %></span>
83
+ <span class="page_infos"><%= _t('Status') %></span>
84
84
  </h2>
85
85
 
86
86
  <%= render :partial => 'sitemap' %>
@@ -1,10 +1,10 @@
1
1
  <div id="overlay_tabs">
2
2
  <ul>
3
- <li><a href="#overlay_tab_internal_link"><%= t('link_overlay_tab_label.internal') %></a></li>
4
- <li><a href="#overlay_tab_external_link"><%= t('link_overlay_tab_label.external') %></a></li>
5
- <li><a href="#overlay_tab_file_link"><%= t('link_overlay_tab_label.file') %></a></li>
3
+ <li><a href="#overlay_tab_internal_link"><%= _t('link_overlay_tab_label.internal') %></a></li>
4
+ <li><a href="#overlay_tab_external_link"><%= _t('link_overlay_tab_label.external') %></a></li>
5
+ <li><a href="#overlay_tab_file_link"><%= _t('link_overlay_tab_label.file') %></a></li>
6
6
  <%- if configuration(:mailer)[:contactform_linking] -%>
7
- <li><a href="#overlay_tab_contactform_link"><%= t('link_overlay_tab_label.contactform') %></a></li>
7
+ <li><a href="#overlay_tab_contactform_link"><%= _t('link_overlay_tab_label.contactform') %></a></li>
8
8
  <%- end -%>
9
9
  </ul>
10
10
  <div class="with_padding">