mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-16 07:31:41 +00:00
Merge branch 'locale' into rails
This commit is contained in:
commit
55e0466102
3 changed files with 3 additions and 3 deletions
|
@ -89,7 +89,7 @@
|
|||
|
||||
%div
|
||||
%tbody
|
||||
- dir = t("locales.#{@locale}.dir")
|
||||
- dir = @site.data.dig(params[:locale], 'dir')
|
||||
- size = @posts.size
|
||||
- @posts.each_with_index do |post, i|
|
||||
-#
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
- dir = t("locales.#{@locale}.dir")
|
||||
- dir = @site.data.dig(params[:locale], 'dir')
|
||||
.row.justify-content-center
|
||||
.col-md-8
|
||||
%article.content.table-responsive-md
|
||||
|
|
|
@ -55,7 +55,7 @@ Rails.application.routes.draw do
|
|||
|
||||
# Gestionar artículos según idioma
|
||||
nested do
|
||||
scope '/(:locale)', constraint: /[a-z]{2}/ do
|
||||
scope '/(:locale)', constraint: /[a-z]{2}(-[A-Z]{2})?/ do
|
||||
post :'posts/reorder', to: 'posts#reorder'
|
||||
resources :posts do
|
||||
get 'p/:page', action: :index, on: :collection
|
||||
|
|
Loading…
Reference in a new issue