refinerycms-pages 0.9.9.7 → 0.9.9.8

Sign up to get free protection for your applications and to get access to all the features.
@@ -48,27 +48,27 @@ module Admin
48
48
  end
49
49
 
50
50
  def test_url
51
- unless params[:url].blank?
52
- url = URI.parse(params[:url])
53
- if url.host.nil? && params[:url].start_with?('/')
54
- url.host = URI.parse(request.url).host
51
+ begin
52
+ timeout(5) do
53
+ unless params[:url].blank?
54
+ url = URI.parse(params[:url])
55
+ if url.host.nil? && params[:url].start_with?('/')
56
+ url.host = URI.parse(request.url).host
57
+ end
58
+
59
+ result = case Net::HTTP.get_response(url)
60
+ when Net::HTTPSuccess, Net::HTTPRedirection
61
+ 'success'
62
+ else
63
+ 'failure'
64
+ end
65
+
66
+ render :json => {:result => result}
67
+ end
55
68
  end
56
-
57
- http = Net::HTTP.new(url.host)
58
- request = Net::HTTP::Get.new(url.path.blank? ? "/" : url.path)
59
-
60
- response = http.request request
61
-
62
- render :json => {:result => case response
63
- when Net::HTTPSuccess, Net::HTTPRedirection
64
- 'success'
65
- else
66
- 'failure'
67
- end }
68
- end
69
-
70
69
  rescue
71
70
  render :json => {:result => 'failure'}
71
+ end
72
72
  end
73
73
 
74
74
  def test_email
@@ -119,30 +119,38 @@ class Page < ActiveRecord::Base
119
119
  if link_url.present?
120
120
  link_url_localised?
121
121
  elsif self.class.use_marketable_urls?
122
- url_marketable
122
+ with_locale_param url_marketable
123
123
  elsif to_param.present?
124
- url_normal
124
+ with_locale_param url_normal
125
125
  end
126
126
  end
127
127
 
128
128
  def link_url_localised?
129
- if link_url =~ %r{^/} and defined?(::Refinery::I18n) and ::Refinery::I18n.enabled? and
130
- ::I18n.locale != ::Refinery::I18n.default_frontend_locale
131
- "/#{::I18n.locale}#{link_url}"
132
- else
133
- link_url
129
+ current_url = link_url
130
+
131
+ if current_url =~ %r{^/} && ::Refinery::I18n.current_frontend_locale != ::Refinery::I18n.default_frontend_locale
132
+ current_url = "/#{::Refinery::I18n.current_frontend_locale}#{current_url}"
134
133
  end
134
+
135
+ current_url
135
136
  end
136
137
 
137
138
  def url_marketable
138
139
  # :id => nil is important to prevent any other params[:id] from interfering with this route.
139
- {:controller => '/pages', :action => 'show', :path => nested_url, :id => nil}
140
+ url_normal.merge(:path => nested_url, :id => nil)
140
141
  end
141
142
 
142
143
  def url_normal
143
144
  {:controller => '/pages', :action => 'show', :path => nil, :id => to_param}
144
145
  end
145
146
 
147
+ def with_locale_param(url_hash)
148
+ if self.class.different_frontend_locale?
149
+ url_hash.update(:locale => ::Refinery::I18n.current_frontend_locale)
150
+ end
151
+ url_hash
152
+ end
153
+
146
154
  # Returns an array with all ancestors to_param, allow with its own
147
155
  # Ex: with an About page and a Mission underneath,
148
156
  # Page.find('mission').nested_url would return:
@@ -172,12 +180,7 @@ class Page < ActiveRecord::Base
172
180
  end
173
181
 
174
182
  def cache_key
175
- if defined?(::Refinery::I18n) and ::Refinery::I18n.enabled?
176
- [Refinery.base_cache_key, ::I18n.locale ,super].join('/')
177
- else
178
- [Refinery.base_cache_key, super].join('/')
179
- end
180
-
183
+ [Refinery.base_cache_key, ::I18n.locale, super].compact.join('/')
181
184
  end
182
185
 
183
186
  # Returns true if this page is "published"
@@ -191,6 +194,10 @@ class Page < ActiveRecord::Base
191
194
  live? && show_in_menu?
192
195
  end
193
196
 
197
+ def not_in_menu?
198
+ not in_menu?
199
+ end
200
+
194
201
  # Returns true if this page is the home page or links to it.
195
202
  def home?
196
203
  link_url == "/"
@@ -198,7 +205,7 @@ class Page < ActiveRecord::Base
198
205
 
199
206
  # Returns all visible sibling pages that can be rendered for the menu
200
207
  def shown_siblings
201
- siblings.reject { |sibling| not sibling.in_menu? }
208
+ siblings.reject(&:not_in_menu?)
202
209
  end
203
210
 
204
211
  class << self
@@ -207,6 +214,15 @@ class Page < ActiveRecord::Base
207
214
  RefinerySetting.find_or_set(:default_page_parts, ["Body", "Side Body"])
208
215
  end
209
216
 
217
+ # Wraps up all the checks that we need to do to figure out whether
218
+ # the current frontend locale is different to the current one set by ::I18n.locale.
219
+ # This terminates in a false if i18n engine is not defined or enabled.
220
+ def different_frontend_locale?
221
+ defined?(::Refinery::I18n) &&
222
+ ::Refinery::I18n.enabled? &&
223
+ ::Refinery::I18n.current_frontend_locale != ::I18n.locale
224
+ end
225
+
210
226
  # Returns how many pages per page should there be when paginating pages
211
227
  def per_page(dialog = false)
212
228
  dialog ? PAGES_PER_DIALOG : PAGES_PER_ADMIN_INDEX
@@ -270,6 +286,7 @@ class Page < ActiveRecord::Base
270
286
 
271
287
  def invalidate_child_cached_url
272
288
  return true unless self.class.use_marketable_urls?
289
+
273
290
  children.each do |child|
274
291
  Rails.cache.delete(child.url_cache_key)
275
292
  Rails.cache.delete(child.path_cache_key)
@@ -0,0 +1,20 @@
1
+ <ul>
2
+ <li>
3
+ <%= render :partial => "/shared/admin/search", :locals => {:url => admin_pages_url} %>
4
+ </li>
5
+ <li>
6
+ <%= link_to t('.create_new_page'), new_admin_page_url, :class => "add_icon" %>
7
+ </li>
8
+ <% if @pages.many? and !searching? %>
9
+ <li>
10
+ <%= link_to t('.reorder_pages'), admin_pages_url,
11
+ :id => "reorder_action",
12
+ :class => "reorder_icon" %>
13
+
14
+ <%= link_to t('.reorder_pages_done'), admin_pages_url,
15
+ :id => "reorder_action_done",
16
+ :style => "display: none;",
17
+ :class => "reorder_icon" %>
18
+ </li>
19
+ <% end %>
20
+ </ul>
@@ -0,0 +1,14 @@
1
+ <% if searching? %>
2
+ <h2><%= t('results_for', :scope => 'shared.admin.search', :query => params[:search]) %></h2>
3
+ <% end %>
4
+ <% if @pages.any? %>
5
+ <%= render :partial => 'sortable_list' %>
6
+ <% else %>
7
+ <p>
8
+ <% unless searching? %>
9
+ <strong><%=t('.no_pages_yet')%></strong>
10
+ <% else %>
11
+ <%= t('no_results', :scope => 'shared.admin.search') %>
12
+ <% end %>
13
+ </p>
14
+ <% end %>
@@ -1,40 +1,8 @@
1
- <div id='records' class='tree'>
2
- <% if searching? %>
3
- <h2><%= t('results_for', :scope => 'shared.admin.search', :query => params[:search]) %></h2>
4
- <% end %>
5
- <% if @pages.any? %>
6
- <%= render :partial => 'sortable_list' %>
7
- <% else %>
8
- <p>
9
- <% unless searching? %>
10
- <strong><%=t('.no_pages_yet')%></strong>
11
- <% else %>
12
- <%= t('no_results', :scope => 'shared.admin.search') %>
13
- <% end %>
14
- </p>
15
- <% end %>
16
- </div>
17
- <div id='actions'>
18
- <ul>
19
- <li>
20
- <%= render :partial => "/shared/admin/search", :locals => {:url => admin_pages_url} %>
21
- </li>
22
- <li>
23
- <%= link_to t('.create_new_page'), new_admin_page_url, :class => "add_icon" %>
24
- </li>
25
- <% if @pages.many? and !searching? %>
26
- <li>
27
- <%= link_to t('.reorder_pages'), admin_pages_url,
28
- :id => "reorder_action",
29
- :class => "reorder_icon" %>
30
-
31
- <%= link_to t('.reorder_pages_done'), admin_pages_url,
32
- :id => "reorder_action_done",
33
- :style => "display: none;",
34
- :class => "reorder_icon" %>
35
- </li>
36
- <% end %>
37
- </ul>
38
- </div>
1
+ <section id='records' class='tree'>
2
+ <%= render :partial => 'records' %>
3
+ </section>
4
+ <section id='actions'>
5
+ <%= render :partial => 'actions' %>
6
+ </section>
39
7
  <%= render :partial => "/shared/admin/make_sortable",
40
8
  :locals => {:tree => true} if @pages.many? -%>
@@ -13,7 +13,7 @@
13
13
  <input type='radio' name='link_to' value='email_address' id='link_to_email_address' <%= "checked='true'" if @email_address_area_selected %> />
14
14
  <label for='link_to_email_address' class='stripped'><%= t('tab_name', :scope => 'admin.pages_dialogs.link_to.email_address') %></label>
15
15
  </span>
16
- <% if ::Refinery::Plugins.registered.names.include?("refinery_files") %>
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
19
  <label for="link_to_resource_file" class="stripped"><%= t('tab_name', :scope => 'admin.pages_dialogs.link_to.your_resource') %></label>
@@ -25,7 +25,7 @@
25
25
  <div id='your_page_area' class='dialog_area' <%= "style='display: none'" unless @page_area_selected %>>
26
26
  <input type='hidden' name='selected_image' id='selected_image' />
27
27
  <div id='your_page_content' class='clearfix'>
28
- <div id='pages_list'>
28
+ <div id='pages_list' class='pages_list'>
29
29
  <ul class="link_list">
30
30
  <%= render :partial => "page_link", :collection => @pages,
31
31
  :locals => {
@@ -92,9 +92,9 @@
92
92
  </ol>
93
93
  </div>
94
94
  </div>
95
- <% if ::Refinery::Plugins.registered.names.include?("refinery_files") %>
95
+ <% if ::Refinery::Plugins.registered.names.include?("refinery_files") and @resources.any? %>
96
96
  <div id="resource_file_area"<%= " style='display:none'" unless @resource_area_selected %> class="dialog_area">
97
- <div id='pages_list'>
97
+ <div id='resources_list' class='pages_list'>
98
98
  <ul class="link_list">
99
99
  <% @resources.each do |resource| -%>
100
100
  <% resource_linked = (resource.url == params[:current_link]) unless params[:current_link].blank? %>
@@ -71,10 +71,11 @@ cs:
71
71
  meta_keywords_help: Vložte 5-10 klíčových slov oddělených čárkou, které se vztahují k obsahu stránky.
72
72
  meta_description_title: Popisek
73
73
  meta_description_help: Vložte 2-3 krátké věty shrnující obsah stránky.
74
- index:
74
+ actions:
75
75
  create_new_page: Přidat novou stránku
76
76
  reorder_pages: Přeuspořádat stránky
77
77
  reorder_pages_done: Uložit uspořádání
78
+ records:
78
79
  no_pages_yet: Zatím nebyly vytvořeny žádné stránky.
79
80
  activerecord:
80
81
  models:
@@ -71,10 +71,11 @@ da:
71
71
  meta_keywords_help: Indtast 5-10 nøgleord der er relaterede til siden. Adskil nøgleordene med kommaer.
72
72
  meta_description_title: Meta description
73
73
  meta_description_help: Indtast to eller tre sætninger, der beskriver siden.
74
- index:
74
+ actions:
75
75
  create_new_page: Tilføj en ny side
76
76
  reorder_pages: Redigér rækkefølgen af siderne
77
77
  reorder_pages_done: Gem rækkefølgen
78
+ records:
78
79
  no_pages_yet: Der er ingen sider endnu. Klik på "Tilføj en ny side" for at oprette den første."
79
80
  activerecord:
80
81
  models:
@@ -71,10 +71,11 @@ de:
71
71
  meta_keywords_help: Geben Sie 5-10 Schlüsselwörter für diese Seite an. Trennen Sie Schlüsselwörter mit einem Komma.
72
72
  meta_description_title: Meta-Beschreibung
73
73
  meta_description_help: Beschreiben Sie in knappen zwei oder drei Sätzen, um was es sich bei dieser Seite handelt.
74
- index:
74
+ actions:
75
75
  create_new_page: Neue Seite anlegen
76
76
  reorder_pages: Seiten umsortieren
77
77
  reorder_pages_done: Umsortieren erledigt
78
+ records:
78
79
  no_pages_yet: Es sind noch keine Seiten vorhanden. Klicken Sie auf "Neue Seite anlegen", um Ihre erste Seite zu erstellen.
79
80
  activerecord:
80
81
  models:
@@ -71,10 +71,11 @@ el:
71
71
  meta_keywords_help: Enter 5-10 keywords that relate to this page. Separate keywords by a comma.
72
72
  meta_description_title: Meta description
73
73
  meta_description_help: Enter a concise two or three sentences describing what this page is about.
74
- index:
74
+ actions:
75
75
  create_new_page: Προσθήκη νέας σελίδας
76
76
  reorder_pages: Αναδιάταξη σελιδών
77
77
  reorder_pages_done: Έγινε αναδιάταξη σελιδών
78
+ records:
78
79
  no_pages_yet: There are no pages yet. Click "Add new page" to add your first page.
79
80
  activerecord:
80
81
  models:
@@ -71,10 +71,11 @@ en:
71
71
  meta_keywords_help: Enter 5-10 keywords that relate to this page. Separate keywords by a comma.
72
72
  meta_description_title: Meta description
73
73
  meta_description_help: Enter a concise two or three sentences describing what this page is about.
74
- index:
74
+ actions:
75
75
  create_new_page: Add new page
76
76
  reorder_pages: Reorder pages
77
77
  reorder_pages_done: Done reordering pages
78
+ records:
78
79
  no_pages_yet: There are no pages yet. Click "Add new page" to add your first page.
79
80
  activerecord:
80
81
  models:
@@ -72,10 +72,11 @@ es:
72
72
  meta_keywords_help: Introduce 5-10 palabras clave relacionadas con esta página, separadas por comas.
73
73
  meta_description_title: Meta-descripción
74
74
  meta_description_help: Describe en dos o tres frases de qué tema trata esta página.
75
- index:
75
+ actions:
76
76
  create_new_page: Crear nueva página
77
77
  reorder_pages: Reordenar páginas
78
78
  reorder_pages_done: Reordenación de páginas completada
79
+ records:
79
80
  no_pages_yet: "Aún no hay páginas. Pulsa \"Crear nueva página\" para añadir tu primera página."
80
81
  activerecord:
81
82
  models:
@@ -71,10 +71,11 @@ fr:
71
71
  meta_keywords_help: Entrez entre 5 et 10 mots clefs en relation avec votre page (Séparer les mots clefs par des virgules).
72
72
  meta_description_title: Description
73
73
  meta_description_help: Entrez deux ou trois phrases concises décrivants le sujet de votre page.
74
- index:
74
+ actions:
75
75
  create_new_page: Créer une nouvelle page
76
76
  reorder_pages: Réordonner les pages
77
77
  reorder_pages_done: Fin de réordonnancement des pages
78
+ records:
78
79
  no_pages_yet: "Il n'y a actuellement aucune page. Cliquer sur 'Créer une nouvelle page' pour en ajouter une."
79
80
  activerecord:
80
81
  models:
@@ -86,11 +86,12 @@ it:
86
86
  already_exists: Una sezione di contenuti con quel titolo e già esistente, si prega di modificarlo.
87
87
  title_empty: Non è stato inserito un titolo per la sezione dei contenuti, inseriscine uno.
88
88
  confirm_delete: Ciò eliminerà la sezione dei contenuti %{section_name} e cancellerà tutti i contenuti che sono stati inseriti al suo interno. Sei sicuro?
89
- index:
89
+ actions:
90
90
  create_new_page: Crea una nuova pagina
91
91
  reorder_pages: Riordina le pagine
92
92
  reorder_pages_done: Riordino Pagine terminato
93
93
  sorry_no_results: La ricerca non ha prodotto risultati.
94
+ records:
94
95
  no_pages_yet: Non è stata ancora creata nessuna pagina. Clicca su "Crea nuova pagina" per aggiungere la tua prima pagina.
95
96
  activerecord:
96
97
  attributes:
@@ -70,10 +70,11 @@ lolcat:
70
70
  meta_keywords_help: ENTR 5-10 KEYWORDZ DAT RELATE 2 DIS PAEG. SEPARATE KEYWORDZ BY COMMA.
71
71
  meta_description_title: META DESCRIPSHUN
72
72
  meta_description_help: ENTR CONCIZE 2 OR 3 SENTENCEZ DESCRIBIN WUT DIS PAEG IZ BOUT.
73
- index:
73
+ actions:
74
74
  create_new_page: ADD NEW PAEG
75
75
  reorder_pages: REORDR PAGEZ
76
76
  reorder_pages_done: DUN REORDERIN PAGEZ
77
+ records:
77
78
  no_pages_yet: THAR R NO PAGEZ YET. CLICK "ADD NEW PAEG" 2 ADD UR FURST PAEG.
78
79
  activerecord:
79
80
  models:
@@ -72,10 +72,11 @@ lt:
72
72
  meta_keywords_help: "Įveskite 5-10 raktinių žodžių, kurie susiję su šiuo puslapiu. Atskirkite raktinius žodžius kableliais."
73
73
  meta_description_title: Meta aprašymas
74
74
  meta_description_help: Įveskite rišlius du ar tris sakinius nusakančius apie ką šis puslapis.
75
- index:
75
+ actions:
76
76
  create_new_page: Pridėti naują puslapį
77
77
  reorder_pages: Keisti puslapių tvarką
78
78
  reorder_pages_done: Baigti keisti puslapių tvarką
79
+ records:
79
80
  no_pages_yet: Dar nėra puslapių. Paspauskite "Pridėti naują puslapį" norėdami sukurti pirmą puslapį.
80
81
  activerecord:
81
82
  models:
@@ -73,10 +73,11 @@ lv:
73
73
  meta_keywords_help: Ievadiet 5-10 atslēgvārdus, kuriem ir saistība ar šo lapu. Atslēgvārdus atdaliet ar komatu
74
74
  meta_description_title: Meta apraksts
75
75
  meta_description_help: Īsi, divos vai trijos teikumos, aprakstiet šīs lapas saturu.
76
- index:
76
+ actions:
77
77
  create_new_page: Izveidot jaunu lapu
78
78
  reorder_pages: Pārkārtot lapas
79
79
  reorder_pages_done: Pabeigt lapu pārkārtošanu
80
+ records:
80
81
  no_pages_yet: Vēl nav nevienas lapas. Spied "Izveidot jaunu lapu", lai izveidotu pirmo lapu.
81
82
  activerecord:
82
83
  models:
@@ -71,10 +71,11 @@ nb:
71
71
  meta_keywords_help: Skriv inn 5-10 stikkord som relaterer til denne siden. Separer stikkordene med komma.
72
72
  meta_description_title: Meta beskrivelse
73
73
  meta_description_help: Skriv en kort beskrivelse på to eller tre setninger som forteller hva denne siden inneholder.
74
- index:
74
+ actions:
75
75
  create_new_page: Legg til ny side
76
76
  reorder_pages: Endre rekkefølgen
77
77
  reorder_pages_done: Ferdig med endring av rekkefølgen
78
+ records:
78
79
  no_pages_yet: Det er ingen sider her enda. Klikk på "Legg til ny side" for å legge til din første side.
79
80
  activerecord:
80
81
  models:
@@ -71,10 +71,11 @@ nl:
71
71
  meta_keywords_help: Voeg 5 tot 10 meta zoekwoorden toe. Gebruik een komma om de zoekwoorden te scheiden.
72
72
  meta_description_title: Meta omschrijving
73
73
  meta_description_help: Voer een compacte (twee a drie zinnen) pagina beschrijving in.
74
- index:
74
+ actions:
75
75
  create_new_page: Maak een nieuwe pagina
76
76
  reorder_pages: "Wijzig de volgorde van de pagina's"
77
77
  reorder_pages_done: "Klaar met het wijzingen van de volgorde van de pagina's"
78
+ records:
78
79
  no_pages_yet: "Er zijn nog geen pagina's. Druk op 'Maak een nieuwe pagina' om de eerste aan te maken."
79
80
  activerecord:
80
81
  models:
@@ -72,10 +72,11 @@ pl:
72
72
  meta_keywords_help: Wpisz 5-10 słów kluczowych związanych z zawartością tej strony. Rozdziel słowa kluczowe przecinkiem.
73
73
  meta_description_title: Opis meta
74
74
  meta_description_help: Podaj dwu-trzyzdaniowy opis tego, o czym jest ta strona.
75
- index:
75
+ actions:
76
76
  create_new_page: Dodaj nową stronę
77
77
  reorder_pages: Zmień kolejność stron
78
78
  reorder_pages_done: Zakończono zmianę kolejności stron
79
+ records:
79
80
  no_pages_yet: Nie ma jeszcze żadnej strony. Kliknij "Dodaj nową stronę" aby stworzyć pierwszą.
80
81
  activerecord:
81
82
  models:
@@ -72,10 +72,11 @@ pt-BR:
72
72
  meta_keywords_help: Digite de 5 a 10 palavras-chave presentes nesta página. Separe elas com vírgula.
73
73
  meta_description_title: Meta descrição
74
74
  meta_description_help: Digite duas ou três sentenças concisas descrevendo sobre o que é essa página.
75
- index:
75
+ actions:
76
76
  create_new_page: Criar uma nova página
77
77
  reorder_pages: Reordenar as Páginas
78
78
  reorder_pages_done: Terminei de reordenar as Páginas
79
+ records:
79
80
  no_pages_yet: Ainda não existem páginas. Clique em "Criar Nova Página" para adicionar sua primeira página.
80
81
  activerecord:
81
82
  models:
@@ -71,10 +71,11 @@ rs:
71
71
  meta_keywords_help: Unesi 5 do 10 reči, odvojene zarezom, koje ukazuju na sadržaj ove strane.
72
72
  meta_description_title: Opis
73
73
  meta_description_help: Unesi opis sadržaja ove strane u dve do tri rečenice.
74
- index:
74
+ actions:
75
75
  create_new_page: Dodaj novu stranu
76
76
  reorder_pages: Promeni redosled strana
77
77
  reorder_pages_done: Završi sa promenom
78
+ records:
78
79
  no_pages_yet: Ne postoji nijedna strana. Klinki na "Dodaj novu stranu" da dodaš prvu stranu.
79
80
  activerecord:
80
81
  models:
@@ -80,10 +80,11 @@ ru:
80
80
  meta_keywords_help: "Введите 5&ndash;10 ключевых слов, которые относятся к этой странице, разделяя запятой."
81
81
  meta_description_title: Описание
82
82
  meta_description_help: "Введите два-три коротких предложения, описывающих страницу."
83
- index:
83
+ actions:
84
84
  create_new_page: Создать новую страницу
85
85
  reorder_pages: Изменить порядок страниц
86
86
  reorder_pages_done: Сохранить такой порядок страниц
87
+ records:
87
88
  no_pages_yet: Страниц ещё нет.
88
89
  reserved_system_word: Защищены системой слова
89
90
  refinery_settings:
@@ -71,10 +71,11 @@ sk:
71
71
  meta_keywords_help: Vložte 5-10 kľúčových slov oddelených čiarkou, ktoré sa vzťahujú k obsahu stránky.
72
72
  meta_description_title: Popis (Meta description)
73
73
  meta_description_help: Vložte 2-3 krátke vety sumarizujúce obsah stránky.
74
- index:
74
+ actions:
75
75
  create_new_page: Pridať novú stránku
76
76
  reorder_pages: Zmeniť usporiadanie stránok
77
77
  reorder_pages_done: Uložiť usporiadanie
78
+ records:
78
79
  no_pages_yet: Zatiaľ neboli vytvorené žiadne stránky. Kliknite na "Pridať novú stránku" pre pridanie prvej.
79
80
  activerecord:
80
81
  models:
@@ -70,10 +70,11 @@ sl:
70
70
  meta_keywords_help: Vnesite 5-10 ključnih besed, ki se navezujejo na to spletno stran. Ključne besede ločite z vejicami.
71
71
  meta_description_title: Meta opis
72
72
  meta_description_help: V dveh do treh stavkih jedernato opišite kaj ta stran predstavlja.
73
- index:
73
+ actions:
74
74
  create_new_page: Dodaj novo stran
75
75
  reorder_pages: Spremeni vrstni red Strani
76
76
  reorder_pages_done: Končaj s prerazporeditvijo Strani
77
+ records:
77
78
  no_pages_yet: Trenutno še ni nobene strani. Za dodajanje prve strani kliknite "Dodaj novo stran".
78
79
  activerecord:
79
80
  models:
@@ -71,10 +71,11 @@ sv:
71
71
  meta_keywords_help: Fyll i 5 till 10 nyckelord som relaterar till den här sidan. Separera dina nyckelord med komma-tecken.
72
72
  meta_description_title: Meta beskrivning
73
73
  meta_description_help: Fyll i konkret vad sidan handlar om. Använd en, två eller tre meningar.
74
- index:
74
+ actions:
75
75
  create_new_page: Lägg till en ny sida
76
76
  reorder_pages: Ändra ordning på sidor
77
77
  reorder_pages_done: Spara ny ordning på sidor
78
+ records:
78
79
  no_pages_yet: Det finns inga sidor ännu. Klicka på "Lägg till en ny sida" för att skapa din första sida.
79
80
  activerecord:
80
81
  models:
@@ -71,10 +71,11 @@ vi:
71
71
  meta_keywords_help: Nhập 5-10 từ khóa liên quan tới trang này, phân cách bằng dấu phẩy.
72
72
  meta_description_title: Meta description
73
73
  meta_description_help: Nhập vào 2-3 câu thật súc tích mô tả trang này nói về gì.
74
- index:
74
+ actions:
75
75
  create_new_page: Tạo trang mới
76
76
  reorder_pages: Sắp xếp lại các trang
77
77
  reorder_pages_done: Tôi xếp xong rồi
78
+ records:
78
79
  no_pages_yet: Hiện chưa có trang nào. Ấn vào "Tạo trang mới" để tạo trang.
79
80
  activerecord:
80
81
  models:
@@ -71,10 +71,11 @@ zh-CN:
71
71
  meta_keywords_help: 输入 5 到 10 个与这个页面有关的关键字. 用逗号分开每个关键字.
72
72
  meta_description_title: Meta 说明
73
73
  meta_description_help: 简洁地输入两三句话来介绍这个页面.
74
- index:
74
+ actions:
75
75
  create_new_page: 添加新页面
76
76
  reorder_pages: 重新编排页面顺序
77
77
  reorder_pages_done: 完成编排
78
+ records:
78
79
  no_pages_yet: 这里还没有页面. 点击 "添加新页面" 去添加您的第一个页面.
79
80
  activerecord:
80
81
  models:
@@ -71,10 +71,11 @@ zh-TW:
71
71
  meta_keywords_help: 輸入 5 到 10 個跟這個頁面有關的關鍵字. 用逗號分開每個關鍵字.
72
72
  meta_description_title: Meta 說明
73
73
  meta_description_help: 簡潔地輸入兩三句話來介紹這個頁面.
74
- index:
74
+ actions:
75
75
  create_new_page: 新增頁面
76
76
  reorder_pages: 重新編排頁面順序
77
77
  reorder_pages_done: 完成頁面順序編排
78
+ records:
78
79
  no_pages_yet: 目前沒有任何頁面. 點選 "新增頁面" 來加入您的第一個頁面.
79
80
  activerecord:
80
81
  models:
@@ -14,6 +14,10 @@ module Refinery
14
14
 
15
15
  class Engine < ::Rails::Engine
16
16
 
17
+ initializer "serve static assets" do |app|
18
+ app.middleware.insert_after ::ActionDispatch::Static, ::ActionDispatch::Static, "#{root}/public"
19
+ end
20
+
17
21
  config.to_prepare do
18
22
  require File.expand_path('../pages/tabs', __FILE__)
19
23
  end
@@ -2,10 +2,10 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{refinerycms-pages}
5
- s.version = %q{0.9.9.7}
5
+ s.version = %q{0.9.9.8}
6
6
  s.summary = %q{Pages engine for Refinery CMS}
7
7
  s.description = %q{The default content engine of Refinery CMS. This engine handles the administration and display of user-editable pages.}
8
- s.date = %q{2011-03-10}
8
+ s.date = %q{2011-03-11}
9
9
  s.email = %q{info@refinerycms.com}
10
10
  s.homepage = %q{http://refinerycms.com}
11
11
  s.rubyforge_project = %q{refinerycms}
@@ -32,6 +32,7 @@ Gem::Specification.new do |s|
32
32
  'app/views',
33
33
  'app/views/admin',
34
34
  'app/views/admin/pages',
35
+ 'app/views/admin/pages/_actions.html.erb',
35
36
  'app/views/admin/pages/_form.html.erb',
36
37
  'app/views/admin/pages/_form_advanced_options.html.erb',
37
38
  'app/views/admin/pages/_form_advanced_options_seo.html.erb',
@@ -41,6 +42,7 @@ Gem::Specification.new do |s|
41
42
  'app/views/admin/pages/_locale_picker.html.erb',
42
43
  'app/views/admin/pages/_page.html.erb',
43
44
  'app/views/admin/pages/_page_part_field.html.erb',
45
+ 'app/views/admin/pages/_records.html.erb',
44
46
  'app/views/admin/pages/_sortable_list.html.erb',
45
47
  'app/views/admin/pages/edit.html.erb',
46
48
  'app/views/admin/pages/index.html.erb',
@@ -107,5 +109,5 @@ Gem::Specification.new do |s|
107
109
  'spec/models/page_spec.rb'
108
110
  ]
109
111
 
110
- s.add_dependency 'refinerycms-core', '~> 0.9.9.7'
112
+ s.add_dependency 'refinerycms-core', '~> 0.9.9.8'
111
113
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: refinerycms-pages
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.9.9.7
5
+ version: 0.9.9.8
6
6
  platform: ruby
7
7
  authors:
8
8
  - Resolve Digital
@@ -13,7 +13,7 @@ autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
15
 
16
- date: 2011-03-10 00:00:00 +13:00
16
+ date: 2011-03-11 00:00:00 +13:00
17
17
  default_executable:
18
18
  dependencies:
19
19
  - !ruby/object:Gem::Dependency
@@ -24,7 +24,7 @@ dependencies:
24
24
  requirements:
25
25
  - - ~>
26
26
  - !ruby/object:Gem::Version
27
- version: 0.9.9.7
27
+ version: 0.9.9.8
28
28
  type: :runtime
29
29
  version_requirements: *id001
30
30
  description: The default content engine of Refinery CMS. This engine handles the administration and display of user-editable pages.
@@ -44,6 +44,7 @@ files:
44
44
  - app/models/page.rb
45
45
  - app/models/page_part.rb
46
46
  - app/presenters/page_presenter.rb
47
+ - app/views/admin/pages/_actions.html.erb
47
48
  - app/views/admin/pages/_form.html.erb
48
49
  - app/views/admin/pages/_form_advanced_options.html.erb
49
50
  - app/views/admin/pages/_form_advanced_options_seo.html.erb
@@ -53,6 +54,7 @@ files:
53
54
  - app/views/admin/pages/_locale_picker.html.erb
54
55
  - app/views/admin/pages/_page.html.erb
55
56
  - app/views/admin/pages/_page_part_field.html.erb
57
+ - app/views/admin/pages/_records.html.erb
56
58
  - app/views/admin/pages/_sortable_list.html.erb
57
59
  - app/views/admin/pages/edit.html.erb
58
60
  - app/views/admin/pages/index.html.erb