mirror of
https://0xacab.org/sutty/sutty
synced 2025-01-19 19:43:38 +00:00
fixes
This commit is contained in:
parent
44fb1c1ffc
commit
6b03f71e53
2 changed files with 3 additions and 5 deletions
|
@ -82,9 +82,7 @@ module ApplicationHelper
|
||||||
def post_label_t(*attribute, post:)
|
def post_label_t(*attribute, post:)
|
||||||
label = post_t(*attribute, post: post, type: :label)
|
label = post_t(*attribute, post: post, type: :label)
|
||||||
|
|
||||||
if post.send(attribute.first).required
|
label += I18n.t('posts.attributes.required.label') if post.send(attribute.first).required
|
||||||
label += I18n.t('posts.attributes.required.label')
|
|
||||||
end
|
|
||||||
|
|
||||||
label
|
label
|
||||||
end
|
end
|
||||||
|
|
|
@ -6,10 +6,10 @@
|
||||||
-# TODO: habilitar form_for
|
-# TODO: habilitar form_for
|
||||||
:ruby
|
:ruby
|
||||||
if post.new?
|
if post.new?
|
||||||
url = site_posts_path(site)
|
url = site_posts_path(site, locale: @locale)
|
||||||
method = :post
|
method = :post
|
||||||
else
|
else
|
||||||
url = site_post_path(site, post.id)
|
url = site_post_path(site, post.id, locale: @locale)
|
||||||
method = :patch
|
method = :patch
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue