Sha256: e942cdf27c0377070ad574790bc2d63f9c045afbf2b583c1940279402bf69856
Contents?: true
Size: 544 Bytes
Versions: 1
Compression:
Stored size: 544 Bytes
Contents
module EmlToPdf class Configuration attr_accessor :from_label, :to_label, :cc_label, :date_label, :metadata_visible def initialize @from_label, @to_label, @cc_label, @date_label= 'From', 'To', 'Cc', 'Date' @date_format = lambda { |date| date.strftime('%Y-%m-%d %H:%M:%S %z') } @metadata_visible = true end def date_format(&block) if block_given? @date_format = block else @date_format end end def format_date(date) @date_format.call(date) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
eml_to_pdf_ext-0.5.2 | lib/eml_to_pdf/configuration.rb |