Sha256: a792d79333113338310e30c45f8fd99a4f464c7a86ed9765a39225d255fb66a6
Contents?: true
Size: 498 Bytes
Versions: 4
Compression:
Stored size: 498 Bytes
Contents
# Presenter class for object views class <%= options[:name].camelize %>Presenter < BasePresenter # Reference initialized object_presenter as object presents :<%= options[:name]%> # delegate :attribute, to: :<%= options[:name]%>, allow_nil: true # Return concatenated full name def name <%= options[:name]%>.attribute + " " + <%= options[:name]%>.attribute end # Return edit path def edit_link link_to :Edit, edit_<%= options[:name]%>_path(<%= options[:name]%>) end end
Version data entries
4 entries across 4 versions & 1 rubygems