refinerycms-pages 1.0.11 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/app/controllers/refinery/admin/page_parts_controller.rb +26 -0
- data/app/controllers/refinery/admin/pages_controller.rb +77 -0
- data/app/controllers/refinery/admin/pages_dialogs_controller.rb +91 -0
- data/app/controllers/refinery/page_sweeper.rb +29 -0
- data/app/controllers/refinery/pages_controller.rb +103 -0
- data/app/helpers/refinery/pages/content_pages_helper.rb +26 -0
- data/app/helpers/refinery/pages_helper.rb +4 -0
- data/app/models/refinery/page.rb +467 -0
- data/app/models/refinery/page_part.rb +33 -0
- data/app/presenters/refinery/page_presenter.rb +7 -0
- data/app/views/admin/pages/_sortable_list.html.erb +7 -4
- data/app/views/{admin → refinery/admin}/pages/_actions.html.erb +5 -4
- data/app/views/refinery/admin/pages/_form.html.erb +63 -0
- data/app/views/{admin → refinery/admin}/pages/_form_advanced_options.html.erb +35 -16
- data/app/views/refinery/admin/pages/_form_advanced_options_seo.html.erb +3 -0
- data/app/views/{admin → refinery/admin}/pages/_form_fields_after_title.html.erb +0 -0
- data/app/views/{admin → refinery/admin}/pages/_form_new_page_parts.html.erb +5 -7
- data/app/views/{admin → refinery/admin}/pages/_form_page_parts.html.erb +19 -11
- data/app/views/{admin → refinery/admin}/pages/_locale_picker.html.erb +3 -3
- data/app/views/refinery/admin/pages/_page.html.erb +48 -0
- data/app/views/{admin → refinery/admin}/pages/_page_part_field.html.erb +1 -1
- data/app/views/refinery/admin/pages/_records.html.erb +14 -0
- data/app/views/refinery/admin/pages/_sortable_list.html.erb +4 -0
- data/app/views/refinery/admin/pages/children.html.erb +1 -0
- data/app/views/refinery/admin/pages/edit.html.erb +1 -0
- data/app/views/refinery/admin/pages/index.html.erb +9 -0
- data/app/views/refinery/admin/pages/new.html.erb +1 -0
- data/app/views/refinery/admin/pages_dialogs/_page_link.html.erb +20 -0
- data/app/views/{admin → refinery/admin}/pages_dialogs/link_to.html.erb +31 -36
- data/app/views/refinery/pages/home.html.erb +1 -0
- data/app/views/refinery/pages/show.html.erb +1 -0
- data/config/locales/bg.yml +81 -73
- data/config/locales/cs.yml +71 -72
- data/config/locales/da.yml +69 -72
- data/config/locales/de.yml +69 -72
- data/config/locales/el.yml +70 -72
- data/config/locales/en.yml +88 -73
- data/config/locales/es.yml +70 -73
- data/config/locales/fi.yml +70 -73
- data/config/locales/fr.yml +69 -72
- data/config/locales/it.yml +92 -89
- data/config/locales/ja.yml +72 -0
- data/config/locales/ko.yml +83 -0
- data/config/locales/lt.yml +71 -73
- data/config/locales/lv.yml +71 -74
- data/config/locales/nb.yml +69 -72
- data/config/locales/nl.yml +68 -71
- data/config/locales/pl.yml +70 -73
- data/config/locales/pt-BR.yml +70 -73
- data/config/locales/pt-PT.yml +75 -0
- data/config/locales/rs.yml +69 -72
- data/config/locales/ru.yml +77 -96
- data/config/locales/sk.yml +69 -72
- data/config/locales/sl.yml +68 -71
- data/config/locales/sv.yml +69 -72
- data/config/locales/vi.yml +69 -72
- data/config/locales/zh-CN.yml +75 -72
- data/config/locales/zh-TW.yml +69 -72
- data/config/routes.rb +10 -5
- data/db/migrate/20100913234708_create_refinerycms_pages_schema.rb +49 -43
- data/db/seeds.rb +41 -0
- data/lib/generators/refinery/pages/pages_generator.rb +21 -0
- data/lib/generators/refinery/pages/templates/config/initializers/refinery/pages.rb.erb +44 -0
- data/lib/refinery/pages/admin/instance_methods.rb +10 -8
- data/lib/refinery/pages/configuration.rb +44 -0
- data/lib/refinery/pages/content_page_presenter.rb +33 -0
- data/lib/refinery/pages/content_presenter.rb +56 -0
- data/lib/refinery/pages/engine.rb +73 -0
- data/lib/refinery/pages/instance_methods.rb +12 -26
- data/lib/refinery/pages/page_part_section_presenter.rb +19 -0
- data/lib/refinery/pages/section_presenter.rb +69 -0
- data/lib/{pages/tabs.rb → refinery/pages/tab.rb} +0 -0
- data/lib/refinery/pages/title_section_presenter.rb +14 -0
- data/lib/refinery/pages/type.rb +17 -0
- data/lib/refinery/pages/types.rb +32 -0
- data/lib/refinery/pages.rb +55 -0
- data/lib/refinerycms-pages.rb +1 -61
- data/refinerycms-pages.gemspec +17 -118
- data/spec/factories/pages.rb +5 -0
- data/spec/helpers/refinery/pages/content_pages_helper_spec.rb +44 -0
- data/spec/lib/generators/refinery/pages/pages_generator_spec.rb +29 -0
- data/spec/lib/pages/content_page_presenter_spec.rb +43 -0
- data/spec/lib/pages/content_presenter_spec.rb +97 -0
- data/spec/lib/pages/page_part_section_presenter_spec.rb +35 -0
- data/spec/lib/pages/section_presenter_spec.rb +86 -0
- data/spec/lib/pages/title_section_presenter_spec.rb +21 -0
- data/spec/lib/pages_spec.rb +26 -0
- data/spec/models/refinery/page_spec.rb +415 -0
- data/spec/requests/refinery/admin/pages_spec.rb +581 -0
- data/spec/requests/refinery/pages_spec.rb +302 -0
- metadata +162 -153
- data/app/controllers/admin/page_parts_controller.rb +0 -24
- data/app/controllers/admin/pages_controller.rb +0 -68
- data/app/controllers/admin/pages_dialogs_controller.rb +0 -85
- data/app/controllers/pages_controller.rb +0 -33
- data/app/helpers/pages_helper.rb +0 -2
- data/app/models/page.rb +0 -391
- data/app/models/page_part.rb +0 -29
- data/app/presenters/page_presenter.rb +0 -7
- data/app/views/admin/pages/_form.html.erb +0 -61
- data/app/views/admin/pages/_form_advanced_options_seo.html.erb +0 -4
- data/app/views/admin/pages/_page.html.erb +0 -33
- data/app/views/admin/pages/_records.html.erb +0 -14
- data/app/views/admin/pages/edit.html.erb +0 -1
- data/app/views/admin/pages/index.html.erb +0 -11
- data/app/views/admin/pages/new.html.erb +0 -1
- data/app/views/admin/pages_dialogs/_page_link.html.erb +0 -14
- data/app/views/pages/home.html.erb +0 -1
- data/app/views/pages/show.html.erb +0 -1
- data/config/locales/jp.yml +0 -75
- data/config/locales/lolcat.yml +0 -76
- data/db/migrate/20101214040815_translate_page_plugin.rb +0 -29
- data/db/migrate/20101216194133_remove_cached_slug_from_pages.rb +0 -11
- data/db/migrate/20110307025652_translate_custom_title_on_pages.rb +0 -26
- data/db/migrate/20110314213540_remove_translated_fields_from_pages.rb +0 -13
- data/db/migrate/20110329080451_create_seo_meta.rb +0 -89
- data/db/seeds/pages.rb +0 -42
- data/features/manage_pages.feature +0 -48
- data/features/step_definitions/page_steps.rb +0 -72
- data/features/support/paths.rb +0 -28
- data/features/translate_pages.feature +0 -40
- data/features/visit_pages.feature +0 -68
- data/lib/gemspec.rb +0 -40
- data/lib/generators/refinerycms_pages_generator.rb +0 -8
- data/lib/pages/marketable_routes.rb +0 -12
- data/spec/models/page_spec.rb +0 -235
File without changes
|
@@ -4,11 +4,9 @@
|
|
4
4
|
<input id='new_page_part_title' value='' class='larger widest' />
|
5
5
|
<input id='new_page_part_index' type='hidden' value='<%= @page.parts.size %>' />
|
6
6
|
</div>
|
7
|
-
<%= render
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
:hide_delete => true
|
13
|
-
} %>
|
7
|
+
<%= render '/refinery/admin/form_actions', :f => f,
|
8
|
+
:continue_editing => false,
|
9
|
+
:submit_button_id => "new_page_part_save",
|
10
|
+
:cancel_button_id => "new_page_part_cancel",
|
11
|
+
:hide_delete => true %>
|
14
12
|
</div>
|
@@ -1,5 +1,14 @@
|
|
1
|
-
<% if
|
1
|
+
<% if ::Refinery::Pages.new_page_parts %>
|
2
2
|
<ul id="page_parts_controls">
|
3
|
+
<li>
|
4
|
+
<%= link_to refinery_icon_tag('arrow_switch.png'), '#',
|
5
|
+
:id => 'reorder_page_part',
|
6
|
+
:title => t('.reorder_content_section') %>
|
7
|
+
<%= link_to refinery_icon_tag('tick.png'), "",
|
8
|
+
:id => 'reorder_page_part_done',
|
9
|
+
:title => t('.reorder_content_section_done'),
|
10
|
+
:style => "display: none;" %>
|
11
|
+
</li>
|
3
12
|
<li>
|
4
13
|
<%= link_to refinery_icon_tag('add.png'), '#',
|
5
14
|
:id => 'add_page_part',
|
@@ -12,16 +21,17 @@
|
|
12
21
|
:name => t('.delete_content_section'),
|
13
22
|
:id => 'delete_page_part' %>
|
14
23
|
</li>
|
24
|
+
<li>
|
15
25
|
</ul>
|
16
26
|
<% end %>
|
17
27
|
<div id='page-tabs' class='clearfix ui-tabs ui-widget ui-widget-content ui-corner-all'>
|
18
28
|
<ul id='page_parts'>
|
19
29
|
<% @page.parts.each_with_index do |part, part_index| %>
|
20
|
-
<li class='ui-state-default<%= ' ui-state-active' if part_index == 0 %>'>
|
30
|
+
<li class='ui-state-default<%= ' ui-state-active' if part_index == 0 %>' data-index='<%= part_index %>'>
|
21
31
|
<%= link_to part.title, "##{@page.persisted? ? part.to_param : "page_part_new_#{part_index}"}" %>
|
22
32
|
</li>
|
23
33
|
<% end %>
|
24
|
-
<% Refinery::Pages.tabs.each_with_index do |tab, tab_index| %>
|
34
|
+
<% ::Refinery::Pages.tabs.each_with_index do |tab, tab_index| %>
|
25
35
|
<li class='ui-state-default' id="custom_<%= tab.name %>_tab">
|
26
36
|
<%= link_to tab.name.titleize, "#custom_tab_#{tab_index}" %>
|
27
37
|
</li>
|
@@ -31,16 +41,14 @@
|
|
31
41
|
<div id='page_part_editors'>
|
32
42
|
<% part_index = -1 %>
|
33
43
|
<%= f.fields_for :parts do |p| %>
|
34
|
-
<%= render
|
35
|
-
:
|
36
|
-
|
37
|
-
|
38
|
-
:new_part => !@page.persisted?
|
39
|
-
} -%>
|
44
|
+
<%= render 'page_part_field',
|
45
|
+
:part => p.object,
|
46
|
+
:part_index => (part_index += 1),
|
47
|
+
:new_part => @page.new_record? -%>
|
40
48
|
<% end %>
|
41
|
-
<% Refinery::Pages.tabs.each_with_index do |tab, tab_index| %>
|
49
|
+
<% ::Refinery::Pages.tabs.each_with_index do |tab, tab_index| %>
|
42
50
|
<div class='page_part' id='<%= "custom_tab_#{tab_index}" %>'>
|
43
|
-
<%= render
|
51
|
+
<%= render tab.partial, :f => f %>
|
44
52
|
</div>
|
45
53
|
<% end %>
|
46
54
|
</div>
|
@@ -1,10 +1,10 @@
|
|
1
1
|
<input type='hidden' name='switch_locale' id='switch_locale' value='<%= local_assigns[:current_locale] %>' />
|
2
|
-
<% if (locales ||=
|
2
|
+
<% if (locales ||= Refinery::I18n.frontend_locales).present? and locales.many? %>
|
3
3
|
<ul id='switch_locale_picker' class='clearfix'>
|
4
4
|
<% locales.each do |locale| %>
|
5
5
|
<li<%= " class='selected'" if locale.to_s == local_assigns[:current_locale].to_s %>>
|
6
|
-
<%= link_to refinery_icon_tag("flags/#{locale}.png", :size =>
|
7
|
-
url_for(:switch_locale => locale) %>
|
6
|
+
<%= link_to refinery_icon_tag("flags/#{locale}.png", :size => "32x22"),
|
7
|
+
refinery.url_for(:switch_locale => locale) %>
|
8
8
|
</li>
|
9
9
|
<% end %>
|
10
10
|
</ul>
|
@@ -0,0 +1,48 @@
|
|
1
|
+
<li class='clearfix record icons' id="<%= dom_id(page) -%>">
|
2
|
+
<div class='clearfix'>
|
3
|
+
<% if page.children.present? %>
|
4
|
+
<span class="icon toggle <%= 'expanded' if Refinery::Pages.auto_expand_admin_tree %>" title="<%= t('expand_collapse', :scope => 'refinery.admin.pages') %>"></span>
|
5
|
+
<% else %>
|
6
|
+
<span class="icon"></span>
|
7
|
+
<% end %>
|
8
|
+
|
9
|
+
<span class='title <%= 'toggle' if page.children.present? %>'>
|
10
|
+
<%= page.title_with_meta.html_safe %>
|
11
|
+
<% if Refinery.i18n_enabled? and Refinery::I18n.frontend_locales.many? %>
|
12
|
+
<span class='preview'>
|
13
|
+
<% page.translations.each do |translation| %>
|
14
|
+
<% if translation.title.present? %>
|
15
|
+
<%= link_to refinery_icon_tag("flags/#{translation.locale}.png", :size => '16x11'),
|
16
|
+
refinery.edit_admin_page_path(page, :switch_locale => translation.locale),
|
17
|
+
:class => 'locale' %>
|
18
|
+
<% end %>
|
19
|
+
<% end %>
|
20
|
+
</span>
|
21
|
+
<% end %>
|
22
|
+
</span>
|
23
|
+
|
24
|
+
<span class='actions'>
|
25
|
+
<%= link_to refinery_icon_tag('application_go.png'),
|
26
|
+
refinery.page_path(page),
|
27
|
+
:target => "_blank",
|
28
|
+
:title => t('.view_live_html') %>
|
29
|
+
<%= link_to refinery_icon_tag('page_add.png'),
|
30
|
+
refinery.new_admin_page_path(:parent_id => page.id),
|
31
|
+
:title => t('new', :scope => 'refinery.admin.pages') %>
|
32
|
+
|
33
|
+
<%= link_to refinery_icon_tag('application_edit.png'),
|
34
|
+
refinery.edit_admin_page_path(page.uncached_nested_url),
|
35
|
+
:title => t('edit', :scope => 'refinery.admin.pages') %>
|
36
|
+
|
37
|
+
<%= link_to refinery_icon_tag('delete.png'),
|
38
|
+
refinery.admin_page_path(page.uncached_nested_url),
|
39
|
+
:class => "cancel confirm-delete",
|
40
|
+
:title => t('delete', :scope => 'refinery.admin.pages'),
|
41
|
+
:confirm => t('message', :scope => 'refinery.admin.delete', :title => page.title_with_meta.gsub(/\ ?<em>.*<\/em>/, "")),
|
42
|
+
:method => :delete if page.deletable? %>
|
43
|
+
</span>
|
44
|
+
</div>
|
45
|
+
<ul class='nested' data-ajax-content="<%= refinery.admin_children_pages_path(page.uncached_nested_url) %>">
|
46
|
+
<%= render(:partial => 'page', :collection => page.children) if Refinery::Pages.auto_expand_admin_tree %>
|
47
|
+
</ul>
|
48
|
+
</li>
|
@@ -1,5 +1,5 @@
|
|
1
1
|
<div class='page_part' id='<%= new_part ? "page_part_new_#{part_index}" : part.to_param %>'>
|
2
2
|
<%= hidden_field_tag "page[parts_attributes][#{part_index}][title]", part.title if new_part %>
|
3
3
|
<%= text_area_tag "page[parts_attributes][#{part_index}][body]", part.body, :rows => 20, :class => 'wymeditor widest' %>
|
4
|
-
<%= hidden_field_tag "page[parts_attributes][#{part_index}][position]", part_index
|
4
|
+
<%= hidden_field_tag "page[parts_attributes][#{part_index}][position]", part_index %>
|
5
5
|
</div>
|
@@ -0,0 +1,14 @@
|
|
1
|
+
<% if searching? %>
|
2
|
+
<h2><%= t('results_for', :scope => 'refinery.admin.search', :query => params[:search]) %></h2>
|
3
|
+
<% end %>
|
4
|
+
<% if @pages.any? %>
|
5
|
+
<%= render 'sortable_list' %>
|
6
|
+
<% else %>
|
7
|
+
<p>
|
8
|
+
<% unless searching? %>
|
9
|
+
<strong><%=t('.no_pages_yet')%></strong>
|
10
|
+
<% else %>
|
11
|
+
<%= t('no_results', :scope => 'refinery.admin.search') %>
|
12
|
+
<% end %>
|
13
|
+
</p>
|
14
|
+
<% end %>
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= render :partial => 'page', :collection => @page.children %>
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= render 'form' %>
|
@@ -0,0 +1,9 @@
|
|
1
|
+
<section id='records' class='tree'>
|
2
|
+
<% cache_if(Refinery::Pages.cache_pages_backend, [Refinery::Core.base_cache_key, "pages_backend", Globalize.locale].join('_')) do %>
|
3
|
+
<%= render 'records' %>
|
4
|
+
<% end %>
|
5
|
+
</section>
|
6
|
+
<section id='actions'>
|
7
|
+
<%= render 'actions' %>
|
8
|
+
</section>
|
9
|
+
<%= render '/refinery/admin/make_sortable', :tree => true if @pages.many? -%>
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= render 'form' %>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<%
|
2
|
+
link_args = defined?(link_to_arguments) ? link_to_arguments : {}
|
3
|
+
page_link_url = refinery.url_for(page_link.url)
|
4
|
+
# current_link is relative so check against the relative url portion before conditionally making it absolute
|
5
|
+
linked = params[:current_link].present? && page_link_url == params[:current_link]
|
6
|
+
page_link_url = "#{[request.protocol, request.host_with_port].join}#{page_link_url}" if Refinery::Pages.absolute_page_links
|
7
|
+
-%>
|
8
|
+
<li class='clearfix<%= " child#{child}" if child %><%= " linked" if linked%>' id="<%= dom_id(page_link) -%>">
|
9
|
+
<%= link_to page_link.title_with_meta.html_safe, page_link_url, {
|
10
|
+
:title => t('.link_to_this_page'),
|
11
|
+
:rel => page_link.title,
|
12
|
+
:class => 'page_link'
|
13
|
+
}.merge(link_args) %>
|
14
|
+
</li>
|
15
|
+
<%= render :partial => 'page_link',
|
16
|
+
:collection => page_link.children,
|
17
|
+
:locals => {
|
18
|
+
:child => (child ||= 0) + 1,
|
19
|
+
:link_to_arguments => link_args
|
20
|
+
} -%>
|
@@ -6,17 +6,17 @@
|
|
6
6
|
</span>
|
7
7
|
<span id='web_address_radio' class='radio<%= " selected_radio" if @web_address_area_selected %>'>
|
8
8
|
<input type='radio' name='link_to' value='web_address' id='link_to_web_address' <%= "checked='true'" if @web_address_area_selected %> />
|
9
|
-
<label for='link_to_web_address' class='stripped'><%= t('tab_name', :scope => 'admin.pages_dialogs.link_to.web_address') %></label>
|
9
|
+
<label for='link_to_web_address' class='stripped'><%= t('tab_name', :scope => 'refinery.admin.pages_dialogs.link_to.web_address') %></label>
|
10
10
|
</span>
|
11
11
|
|
12
12
|
<span id='email_address_radio' class='radio<%= " selected_radio" if @email_address_area_selected %>'>
|
13
13
|
<input type='radio' name='link_to' value='email_address' id='link_to_email_address' <%= "checked='true'" if @email_address_area_selected %> />
|
14
|
-
<label for='link_to_email_address' class='stripped'><%= t('tab_name', :scope => 'admin.pages_dialogs.link_to.email_address') %></label>
|
14
|
+
<label for='link_to_email_address' class='stripped'><%= t('tab_name', :scope => 'refinery.admin.pages_dialogs.link_to.email_address') %></label>
|
15
15
|
</span>
|
16
16
|
<% if ::Refinery::Plugins.registered.names.include?("refinery_files") and @resources.any? %>
|
17
17
|
<span id="resource_file_radio" class="radio<%= " selected_radio" if @resource_area_selected %>">
|
18
18
|
<input type="radio" name="link_to" value="resource_file" id="link_to_resource_file" <%= "checked='true'" if @resource_area_selected %> />
|
19
|
-
<label for="link_to_resource_file" class="stripped"><%= t('tab_name', :scope => 'admin.pages_dialogs.link_to.your_resource') %></label>
|
19
|
+
<label for="link_to_resource_file" class="stripped"><%= t('tab_name', :scope => 'refinery.admin.pages_dialogs.link_to.your_resource') %></label>
|
20
20
|
</span>
|
21
21
|
<% end %>
|
22
22
|
</div>
|
@@ -27,63 +27,61 @@
|
|
27
27
|
<div id='your_page_content' class='clearfix'>
|
28
28
|
<div id='pages_list' class='pages_list'>
|
29
29
|
<ul class="link_list">
|
30
|
-
<%= render :partial =>
|
30
|
+
<%= render :partial => 'page_link', :collection => @pages,
|
31
31
|
:locals => {
|
32
32
|
:child => 0,
|
33
33
|
:link_to_arguments => {}
|
34
34
|
} %>
|
35
35
|
</ul>
|
36
|
-
<%= will_paginate @pages,
|
37
|
-
:param_name => :page,
|
38
|
-
:id => 'pages_paginate' %>
|
36
|
+
<%= will_paginate @pages, :id => 'pages_paginate' %>
|
39
37
|
</div>
|
40
38
|
</div>
|
41
39
|
</div>
|
42
40
|
<div id='web_address_area' <%= "style='display: none'" unless @web_address_area_selected %> class='dialog_area'>
|
43
41
|
<div id='web_address_content'>
|
44
|
-
<label for='web_address_text'><%= t('location', :scope => 'admin.pages_dialogs.link_to.web_address') %></label>
|
42
|
+
<label for='web_address_text'><%= t('location', :scope => 'refinery.admin.pages_dialogs.link_to.web_address') %></label>
|
45
43
|
<%= text_field :web_address, :text, :value => @web_address_text, :style => "width: 70%" %>
|
46
|
-
<label><%= t('new_window', :scope => 'admin.pages_dialogs.link_to.web_address') %></label>
|
44
|
+
<label><%= t('new_window', :scope => 'refinery.admin.pages_dialogs.link_to.web_address') %></label>
|
47
45
|
<input type='checkbox' name='web_address_target_blank' id='web_address_target_blank' <%= "checked='checked'" if @web_address_target_blank %> />
|
48
|
-
<label for='web_address_target_blank' class='stripped'><%= t('new_window_label', :scope => 'admin.pages_dialogs.link_to.web_address') %></label>
|
46
|
+
<label for='web_address_target_blank' class='stripped'><%= t('new_window_label', :scope => 'refinery.admin.pages_dialogs.link_to.web_address') %></label>
|
49
47
|
<p>
|
50
|
-
<strong><%= t('not_sure', :scope => 'admin.pages_dialogs.link_to.web_address') %></strong>
|
48
|
+
<strong><%= t('not_sure', :scope => 'refinery.admin.pages_dialogs.link_to.web_address') %></strong>
|
51
49
|
</p>
|
52
50
|
<ol>
|
53
|
-
<li><%= t('step1', :scope => 'admin.pages_dialogs.link_to.web_address') %></li>
|
54
|
-
<li><%= t('step2', :scope => 'admin.pages_dialogs.link_to.web_address') %></li>
|
51
|
+
<li><%= t('step1', :scope => 'refinery.admin.pages_dialogs.link_to.web_address') %></li>
|
52
|
+
<li><%= t('step2', :scope => 'refinery.admin.pages_dialogs.link_to.web_address') %></li>
|
55
53
|
</ol>
|
56
54
|
</div>
|
57
55
|
</div>
|
58
56
|
<div id='email_address_area' <%= "style='display: none'" unless @email_address_area_selected %> class='dialog_area'>
|
59
57
|
<div id='email_address_content'>
|
60
58
|
<div class='field'>
|
61
|
-
<label for='email_address_text'><%= t('tab_name', :scope => 'admin.pages_dialogs.link_to.email_address') %></label>
|
59
|
+
<label for='email_address_text'><%= t('tab_name', :scope => 'refinery.admin.pages_dialogs.link_to.email_address') %></label>
|
62
60
|
<%= text_field :email_address, :text, :value => @email_address_text, :style => "width: 70%" %>
|
63
61
|
</div>
|
64
62
|
|
65
63
|
<div class='field'>
|
66
|
-
<label for='email_default_subject_text'><%= t('subject_line_optional', :scope => 'admin.pages_dialogs.link_to.email_address') %></label>
|
64
|
+
<label for='email_default_subject_text'><%= t('subject_line_optional', :scope => 'refinery.admin.pages_dialogs.link_to.email_address') %></label>
|
67
65
|
<%= text_field :email_default_subject, :text, :value => @email_default_subject_text, :style => "width: 70%" %>
|
68
66
|
</div>
|
69
67
|
|
70
68
|
<div class='field'>
|
71
|
-
<label for='email_default_body_text'><%= t('body_optional', :scope => 'admin.pages_dialogs.link_to.email_address') %></label>
|
69
|
+
<label for='email_default_body_text'><%= t('body_optional', :scope => 'refinery.admin.pages_dialogs.link_to.email_address') %></label>
|
72
70
|
<%= text_area :email_default_body, :text, :value => @email_default_body_text, :style => "width: 70%", :rows => '' %>
|
73
71
|
</div>
|
74
72
|
|
75
73
|
<p>
|
76
|
-
<strong><%= t('not_sure', :scope => 'admin.pages_dialogs.link_to.email_address') %></strong>
|
74
|
+
<strong><%= t('not_sure', :scope => 'refinery.admin.pages_dialogs.link_to.email_address') %></strong>
|
77
75
|
</p>
|
78
76
|
<ol style='margin-top: 3px'>
|
79
77
|
<li>
|
80
|
-
<%= t('step1_html', :scope => 'admin.pages_dialogs.link_to.email_address') %>
|
78
|
+
<%= t('step1_html', :scope => 'refinery.admin.pages_dialogs.link_to.email_address') %>
|
81
79
|
</li>
|
82
80
|
<li>
|
83
|
-
<%= t('step2_html', :scope => 'admin.pages_dialogs.link_to.email_address') %>
|
81
|
+
<%= t('step2_html', :scope => 'refinery.admin.pages_dialogs.link_to.email_address') %>
|
84
82
|
</li>
|
85
83
|
<li>
|
86
|
-
<%= t('step3_html', :scope => 'admin.pages_dialogs.link_to.email_address') %>
|
84
|
+
<%= t('step3_html', :scope => 'refinery.admin.pages_dialogs.link_to.email_address') %>
|
87
85
|
</li>
|
88
86
|
</ol>
|
89
87
|
</div>
|
@@ -95,37 +93,34 @@
|
|
95
93
|
<% @resources.each do |resource| -%>
|
96
94
|
<% resource_linked = (resource.url == params[:current_link]) unless params[:current_link].blank? %>
|
97
95
|
<li<%= " class='linked'" if resource_linked %>>
|
98
|
-
<%= link_to "#{resource.title}.#{resource.ext}", compute_public_path(resource.url, ''),
|
99
|
-
:title => t('link_to_this_resource', :scope => 'admin.pages_dialogs.link_to.your_resource'),
|
96
|
+
<%= link_to "#{resource.title}.#{resource.ext}", asset_paths.compute_public_path(resource.url, ''),
|
97
|
+
:title => t('link_to_this_resource', :scope => 'refinery.admin.pages_dialogs.link_to.your_resource'),
|
100
98
|
:rel => resource.title,
|
101
99
|
:class => "page_link #{resource.ext}" %>
|
102
100
|
</li>
|
103
101
|
<% end %>
|
104
102
|
</ul>
|
105
103
|
<%= will_paginate @resources,
|
106
|
-
|
107
|
-
|
108
|
-
|
104
|
+
:param_name => :resource_page,
|
105
|
+
:params => {:paginating => "resource_file"},
|
106
|
+
:id => 'resouces_paginate' %>
|
109
107
|
</div>
|
110
108
|
</div>
|
111
109
|
<% end %>
|
112
110
|
</div>
|
113
|
-
<%= render
|
114
|
-
:
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
:cancel_title => nil,
|
120
|
-
:hide_delete => true
|
121
|
-
} %>
|
111
|
+
<%= render '/refinery/admin/form_actions', :f => nil,
|
112
|
+
:cancel_url => '',
|
113
|
+
:submit_button_text => t('.insert'),
|
114
|
+
:hide_cancel => false,
|
115
|
+
:cancel_title => nil,
|
116
|
+
:hide_delete => true %>
|
122
117
|
</div>
|
123
118
|
|
124
119
|
<% content_for :javascripts do %>
|
125
120
|
<script>
|
126
121
|
$(document).ready(function(){
|
127
|
-
link_tester.init('<%=
|
128
|
-
'<%=
|
122
|
+
link_tester.init('<%= refinery.test_url_admin_pages_dialogs_path %>',
|
123
|
+
'<%= refinery.test_email_admin_pages_dialogs_path %>');
|
129
124
|
link_dialog.init();
|
130
125
|
|
131
126
|
$('.link_list a').click(function(e){
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= render '/refinery/content_page' %>
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= render '/refinery/content_page' %>
|
data/config/locales/bg.yml
CHANGED
@@ -1,78 +1,86 @@
|
|
1
1
|
bg:
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
2
|
+
refinery:
|
3
|
+
plugins:
|
4
|
+
refinery_pages:
|
5
|
+
title: Страници
|
6
|
+
description: Управление на страници
|
7
|
+
admin:
|
8
|
+
pages_dialogs:
|
9
|
+
page_link:
|
10
|
+
link_to_this_page: Връзка към тази страница
|
11
|
+
link_to:
|
12
|
+
insert: Вмъкване
|
13
|
+
your_page:
|
14
|
+
tab_name: Ваша страница
|
15
|
+
web_address:
|
16
|
+
tab_name: Уебсайт
|
17
|
+
location: Уеб адрес
|
18
|
+
new_window: Нов прозорец
|
19
|
+
new_window_label: Ако искате връзката да се отвори в нов прозорец, моля сложете отметка в това поле.
|
20
|
+
not_sure: Не сте сигурни какво да поставите в текстово поле по-горе?
|
21
|
+
step1: Намерете страницата в Интернет, към която искате да добавите връзка.
|
22
|
+
step2: Копирайте уеб адреса от Вашия браузър и го вмъкнете в текстовото поле по-горе.
|
23
|
+
email_address:
|
24
|
+
tab_name: Е-поща
|
25
|
+
subject_line_optional: Тема (незадължително поле)
|
26
|
+
body_optional: Съдържание (незадължително поле)
|
27
|
+
not_sure: Не сте сигурни какво да поставите в текстовите полета по-горе?
|
28
|
+
step1_html: В горното поле "<strong>Е-поща</strong>" напишете или копирайте и вмъкнете (например от Вашата адресна книга) адреса на е-пощата, към която искате да добавите връзка.
|
29
|
+
step2_html: Използвайте горното поле "<strong>Тема</strong>", ако искате писмото да бъде изготвено с <strong>предварително зададена тема</strong>.
|
30
|
+
step3_html: Използвайте горното поле "<strong>Съдържание</strong>", ако искате писмото да бъде изготвено с <strong>предварително зададено съдържание</strong>.
|
31
|
+
your_resource:
|
32
|
+
tab_name: Ваш файл
|
33
|
+
link_to_this_resource: Връзка към този файл
|
34
|
+
pages:
|
35
|
+
delete: Изтриване на тази страница завинаги
|
36
|
+
edit: Редактиране на тази страница
|
37
|
+
new: Добавяне на нова подстраница
|
38
|
+
page:
|
39
|
+
view_live_html: Преглед на тази страница <br/><em>(ще се отвори се в нов прозорец)</em>
|
40
|
+
hidden: скрита
|
41
|
+
draft: чернова
|
42
|
+
form_new_page_parts:
|
43
|
+
title: Заглавие
|
44
|
+
form_page_parts:
|
45
|
+
create_content_section: Добавяне на секция за съдържание
|
46
|
+
delete_content_section: Изтриване на секция за съдържание
|
47
|
+
form_advanced_options:
|
48
|
+
toggle_advanced_options: Достъп до настройките за етикета "meta" и менюто
|
49
|
+
page_options: Настройки на страница
|
50
|
+
parent_page: Родителска страница
|
51
|
+
advanced_options: Разширени настройки
|
52
|
+
menu_title: Заглавие в менюто
|
53
|
+
custom_slug: Кратко заглавие по избор
|
54
|
+
show_in_menu_title: Показване в менюто
|
55
|
+
show_in_menu_description: Показване на тази страница в менюто на сайта
|
56
|
+
show_in_menu_help: Махнете отметката от това поле, ако искате страницата да не се показва в менюто на сайта. Това е удобно, ако искате дадена страница да бъде достъпвана директно без да бъде показвана в менюто.
|
57
|
+
save_as_draft: Запис като чернова
|
58
|
+
skip_to_first_child: Пропускане на страницата като родителска
|
59
|
+
skip_to_first_child_label: Пренасочване на посетителите към първата страница от по-ниско ниво.
|
60
|
+
skip_to_first_child_help: Тази настройка предоставя възможност страницата да бъде свързана с друга, намираща се под нея. Това е полезно при групиране на страници.
|
61
|
+
link_url: Препращане към друг уебсайт или страница
|
62
|
+
link_url_help: Ако искате тази страница да сочи към друг уебсайт или страница, въведете уеб адрес. Например "http://google.com". В противен случай оставете полето празно.
|
63
|
+
parent_page_help: Можете да поставите страница под друга като я изберете от списъка. Ако искате тази страница да бъде на най-горно ниво, оставете полето празно.
|
64
|
+
menu_title_help: Ако искате в менюто да се показва различно заглавие на страницата, въведете го тук.
|
65
|
+
custom_slug_help: Краткото заглавие (slug) представлява лесно четим идентификатор, който се използва при създаването на уеб адреса на страницата. Например 'за-нас'. За да замените краткото заглавие, което автоматично се генерира от Refinery, въведете Вашето тук.
|
66
|
+
form_advanced_options_seo:
|
67
|
+
seo: Оптимизация за търсачки
|
68
|
+
seo_override_title: Заглавие в браузъра
|
69
|
+
seo_override_title_help: Въведете заглавие от 5 до 10 символа, което да синтезира съдържанието на тази страница.
|
70
|
+
meta_keywords_title: Ключови думи за етиката "meta"
|
71
|
+
meta_keywords_help: Въведете от 5 до 10 ключови думи, които описват тази страница, разделени със запетая.
|
72
|
+
meta_description_title: Описание за етикета "meta"
|
73
|
+
meta_description_help: Въведете няколко кратки изречения, които да описват тази страница.
|
74
|
+
actions:
|
75
|
+
create_new_page: Добавяне на нова страница
|
76
|
+
reorder_pages: Пренареждане на страниците
|
77
|
+
reorder_pages_done: Запис на текущото подреждане на страниците
|
78
|
+
records:
|
79
|
+
no_pages_yet: Все още няма страници. Натиснете "Добавяне на нова страница", за да въведете нова.
|
80
|
+
translator_access: Нямате нужните права да променяте страници на този език.
|
73
81
|
activerecord:
|
74
82
|
models:
|
75
|
-
page: страница
|
83
|
+
refinery/page: страница
|
76
84
|
attributes:
|
77
|
-
page:
|
85
|
+
refinery/page:
|
78
86
|
title: Заглавие
|