lib/lurker/presenters/service_presenter.rb in lurker-0.6.8 vs lib/lurker/presenters/service_presenter.rb in lurker-0.6.9
- old
+ new
@@ -16,20 +16,29 @@
@service_presenter = self
render('index')
end
def title
- "Lurker | #{name}"
+ "#{name}"
end
def domains
return service_domains if service_domains.present?
{ '/' => 'Local' }
end
def default_domain
return service_domains.to_a[0][1] if service_domains.present?
'/'
+ end
+
+ def request_media_types
+ return service.request_media_types if service.request_media_types.present?
+ ['application/x-www-form-urlencoded']
+ end
+
+ def default_request_media_type
+ request_media_types[0]
end
def name_as_link(options = {})
path = index_path
'<a href="%s">%s %s</a>' % [path, options[:prefix], service.name]