Move common views to partial

This commit is contained in:
Stella Rouzi 2015-04-18 21:44:40 +03:00
parent b15c1abd2e
commit 969c24c091
16 changed files with 101 additions and 120 deletions

View file

@ -1,4 +1,12 @@
module ApplicationHelper
def resource_name
:user
end
def devise_mapping
@devise_mapping ||= Devise.mappings[:user]
end
def pluralize_without_count(count, noun, text = nil)
if count != 0
count == 1 ? "#{noun}#{text}" : "#{noun.pluralize}#{text}"