mirror of
https://github.com/internetee/registry.git
synced 2025-07-28 13:36:15 +02:00
Move contact ident description to helper method
This commit is contained in:
parent
dd513b6313
commit
fd41d77390
8 changed files with 15 additions and 7 deletions
|
@ -9,6 +9,14 @@ module ApplicationHelper
|
|||
"background-image: url(#{image_path("#{unstable_env}.png")});"
|
||||
end
|
||||
|
||||
def ident_for(contact)
|
||||
ident = contact.ident
|
||||
description = "[#{contact.ident_country_code} #{contact.ident_type}]"
|
||||
description.prepend("#{ident} ") if ident.present?
|
||||
|
||||
description
|
||||
end
|
||||
|
||||
def current_commit_link
|
||||
hash = `git rev-parse --short HEAD`
|
||||
current_repo = `git remote get-url origin`.gsub('com:', 'com/')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue