fix for chinese company name
This commit is contained in:
parent
614103f6d2
commit
ec6fae79e4
|
@ -29,6 +29,20 @@ class EmployerProfile
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def get_company_name
|
||||||
|
if self.company_name.empty?
|
||||||
|
case I18n.locale
|
||||||
|
when :en
|
||||||
|
cname = self.company_name_translations["zh_tw"]
|
||||||
|
when :zh_tw
|
||||||
|
cname = self.company_name_translations["en"]
|
||||||
|
end
|
||||||
|
else
|
||||||
|
cname = self.company_name
|
||||||
|
end
|
||||||
|
return cname
|
||||||
|
end
|
||||||
|
|
||||||
def get_industry
|
def get_industry
|
||||||
RecruitmentIndustry.find(self.industry).industry_title rescue ""
|
RecruitmentIndustry.find(self.industry).industry_title rescue ""
|
||||||
end
|
end
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
<% if user.is_employee? %>
|
<% if user.is_employee? %>
|
||||||
<a href="/<%= I18n.locale.to_s + "/candidates/" + user.to_param %>" target="_blank" ><%= user.name %></a>
|
<a href="/<%= I18n.locale.to_s + "/candidates/" + user.to_param %>" target="_blank" ><%= user.name %></a>
|
||||||
<% elsif user.is_employer? %>
|
<% elsif user.is_employer? %>
|
||||||
<a href="<%= show_member_admin_recruitment_path(user.id) %>" ><%= user.profile.company_name %></a>
|
<a href="<%= show_member_admin_recruitment_path(user.id) %>" ><%= user.profile.get_company_name %></a>
|
||||||
<% end %>
|
<% end %>
|
||||||
</td>
|
</td>
|
||||||
<td><%= t("recruitment.user_type.type#{user.user_type.to_s}") %></td>
|
<td><%= t("recruitment.user_type.type#{user.user_type.to_s}") %></td>
|
||||||
|
|
Loading…
Reference in New Issue