app/models/data_object.rb
# 'owner' chooses someone responsible for this data object in order of
# preference this method returns [OwnerName, OwnerUser || nil]
'owner' chooses someone responsible for this data object in order of
preference this method returns [OwnerName, OwnerUser || nil]
' owner ' chooses someone responsible for this data object in order of preference this method returns [ OwnerName OwnerUser || nil ]
def owner
    return translated_from.owner if data_object_translation
    if rights_holder_for_display.blank?
      unless agents_data_objects.empty?
        AgentsDataObject.sort_by_role_for_owner(agents_data_objects)
        if first_agent = agents_data_objects.first.agent
          return first_agent.full_name
        end
      end
      return ''
    else 
      owner = "#{rights_holder_for_display}"
      unless license && license.is_public_domain?
        return "&copy; #{owner}"
      end
      return owner
    end
  end
def owner return translated_from . owner if data_object_translation if rights_holder_for_display . blank? unless agents_data_objects . empty? AgentsDataObject . sort_by_role_for_owner ( agents_data_objects ) if first_agent = agents_data_objects . first . agent return first_agent . full_name end end return '' else owner = "#{rights_holder_for_display}" unless license && license . is_public_domain? return "&copy; #{owner}" end return owner end end
'owner' chooses someone responsible for this data object in order of
preference this method returns [OwnerName, OwnerUser || nil]
' owner ' chooses someone responsible for this data object in order of preference this method returns [ OwnerName OwnerUser || nil ]
# Use the original owner when translated. TODO - image only? # rights holder is preferred