Sha256: 2944c36bf37dbbaba8165b19b7ec13e06ce42a4aa75c11a36b7630d2169262a7
Contents?: true
Size: 748 Bytes
Versions: 69
Compression:
Stored size: 748 Bytes
Contents
# require "eitil_integrate/application_exporter/store_file" require "eitil_integrate/application_exporter/initialize" require "eitil_core/setters/set_ivars" module EitilIntegrate::RubyXL class ApplicationExporter attr_accessor :storage_path private def save_file set_ivars :storage_path save_book run_after_save_effects @storage_path end def set_storage_path "#{Rails.root}/data/#{self.class.name.snakecase}_#{DateTime.now.prettify}.xlsx" end def save_book book.write @storage_path end def run_after_save_effects # nil fallback for if the application class (which inherits from ApplicationExporter) has no method #run_after_save_effects end end end
Version data entries
69 entries across 69 versions & 1 rubygems