mirror of
https://github.com/Retrospring/retrospring.git
synced 2024-11-20 12:39:53 +01:00
Add translations for smile ajax controller
This commit is contained in:
parent
34de119bb1
commit
7381a685ac
3 changed files with 21 additions and 21 deletions
|
@ -13,12 +13,12 @@ class Ajax::SmileController < AjaxController
|
|||
rescue => e
|
||||
Sentry.capture_exception(e)
|
||||
@response[:status] = :fail
|
||||
@response[:message] = I18n.t('messages.smile.create.fail')
|
||||
@response[:message] = t(".error")
|
||||
return
|
||||
end
|
||||
|
||||
@response[:status] = :okay
|
||||
@response[:message] = I18n.t('messages.smile.create.okay')
|
||||
@response[:message] = t(".success")
|
||||
@response[:success] = true
|
||||
end
|
||||
|
||||
|
@ -32,12 +32,12 @@ class Ajax::SmileController < AjaxController
|
|||
rescue => e
|
||||
Sentry.capture_exception(e)
|
||||
@response[:status] = :fail
|
||||
@response[:message] = I18n.t('messages.smile.destroy.fail')
|
||||
@response[:message] = t(".error")
|
||||
return
|
||||
end
|
||||
|
||||
@response[:status] = :okay
|
||||
@response[:message] = I18n.t('messages.smile.destroy.okay')
|
||||
@response[:message] = t(".success")
|
||||
@response[:success] = true
|
||||
end
|
||||
|
||||
|
@ -55,12 +55,12 @@ class Ajax::SmileController < AjaxController
|
|||
rescue => e
|
||||
Sentry.capture_exception(e)
|
||||
@response[:status] = :fail
|
||||
@response[:message] = I18n.t('messages.smile.create_comment.fail')
|
||||
@response[:message] = t(".error")
|
||||
return
|
||||
end
|
||||
|
||||
@response[:status] = :okay
|
||||
@response[:message] = I18n.t('messages.smile.create_comment.okay')
|
||||
@response[:message] = t(".success")
|
||||
@response[:success] = true
|
||||
end
|
||||
|
||||
|
@ -74,12 +74,12 @@ class Ajax::SmileController < AjaxController
|
|||
rescue => e
|
||||
Sentry.capture_exception(e)
|
||||
@response[:status] = :fail
|
||||
@response[:message] = I18n.t('messages.smile.destroy_comment.fail')
|
||||
@response[:message] = t(".error")
|
||||
return
|
||||
end
|
||||
|
||||
@response[:status] = :okay
|
||||
@response[:message] = I18n.t('messages.smile.destroy_comment.okay')
|
||||
@response[:message] = t(".success")
|
||||
@response[:success] = true
|
||||
end
|
||||
end
|
||||
|
|
|
@ -34,6 +34,19 @@ en:
|
|||
follow:
|
||||
success: "Successfully unfollowed user."
|
||||
error: "You are not following that user."
|
||||
smile:
|
||||
create:
|
||||
success: "Successfully smiled answer."
|
||||
error: "You have already smiled that answer."
|
||||
create_comment:
|
||||
success: "Successfully smiled comment."
|
||||
error: "You have already smiled that comment."
|
||||
destroy:
|
||||
success: "Successfully unsmiled answer."
|
||||
error: "You have not smiled that answer."
|
||||
destroy_comment:
|
||||
success: "Successfully unsmiled comment."
|
||||
error: "You have not smiled that comment."
|
||||
announcement:
|
||||
create:
|
||||
success: "Announcement created successfully."
|
||||
|
|
|
@ -135,19 +135,6 @@ en:
|
|||
unknown: "unknown type"
|
||||
not_found: "Could not find %{parameter}"
|
||||
okay: "%{parameter} reported. A moderator will decide what happens with the %{parameter}."
|
||||
smile:
|
||||
create:
|
||||
fail: "You have already smiled that answer."
|
||||
okay: "Successfully smiled answer."
|
||||
destroy:
|
||||
fail: "You have not smiled that answer."
|
||||
okay: "Successfully unsmiled answer."
|
||||
create_comment:
|
||||
fail: "You have already smiled that comment."
|
||||
okay: "Successfully smiled comment."
|
||||
destroy_comment:
|
||||
fail: "You have not smiled that comment."
|
||||
okay: "Successfully unsmiled comment."
|
||||
subscription:
|
||||
torpedo: "418 I'm a torpedo"
|
||||
views:
|
||||
|
|
Loading…
Reference in a new issue