# frozen_string_literal: true
module RelationshipsHelper
def relationship_from_date_or_none(relationship)
if relationship&.from_date.blank?
none
else
localize relationship.from_date, format: :long
end
def relationship_status_or_none(relationship)
translate_enum :relationship_status, relationship&.status || false
def relationship_position_or_none(relationship)
if relationship&.position.nil?
translate_enum :relationship_position, relationship.position
def relationship_short_position_or_none(relationship)
translate_enum :relationship_short_position, relationship.position